diff mbox series

[1/6] dt-bindings: qcom: geni-se: document I2C Master Hub wrapper variant

Message ID 20221114-narmstrong-sm8550-upstream-i2c-master-hub-v1-1-64449106a148@linaro.org
State New
Headers show
Series soc: qcom: add support for the I2C Master Hub | expand

Commit Message

Neil Armstrong Nov. 16, 2022, 10:21 a.m. UTC
The I2C Master Hub is a stripped down version of the GENI Serial Engine
QUP Wrapper Controller but only supporting I2C serial engines without
DMA support.

This documents the variant compatible and forbids UART and SPI sub-nodes,
and removes requirement for the Master AHB clock and iommu property.

Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
---
 .../devicetree/bindings/soc/qcom/qcom,geni-se.yaml | 43 ++++++++++++++++++----
 1 file changed, 35 insertions(+), 8 deletions(-)
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/soc/qcom/qcom,geni-se.yaml b/Documentation/devicetree/bindings/soc/qcom/qcom,geni-se.yaml
index 2bf5293fc995..6657e74df629 100644
--- a/Documentation/devicetree/bindings/soc/qcom/qcom,geni-se.yaml
+++ b/Documentation/devicetree/bindings/soc/qcom/qcom,geni-se.yaml
@@ -21,20 +21,15 @@  properties:
   compatible:
     enum:
       - qcom,geni-se-qup
+      - qcom,geni-se-i2c-master-hub
 
   reg:
     description: QUP wrapper common register address and length.
     maxItems: 1
 
-  clock-names:
-    items:
-      - const: m-ahb
-      - const: s-ahb
+  clock-names: true
 
-  clocks:
-    items:
-      - description: Master AHB Clock
-      - description: Slave AHB Clock
+  clocks: true
 
   "#address-cells":
     const: 2
@@ -81,6 +76,38 @@  patternProperties:
     description: GENI Serial Engine based UART Controller.
     $ref: /schemas/serial/qcom,serial-geni-qcom.yaml#
 
+if:
+  properties:
+    compatible:
+      contains:
+        const: qcom,geni-se-i2c-master-hub
+then:
+  properties:
+    clock-names:
+      items:
+        - const: s-ahb
+
+    clocks:
+      items:
+        - description: Slave AHB Clock
+
+    iommus: false
+
+  patternProperties:
+    "spi@[0-9a-f]+$": false
+    "serial@[0-9a-f]+$": false
+else:
+  properties:
+    clock-names:
+      items:
+        - const: m-ahb
+        - const: s-ahb
+
+    clocks:
+      items:
+        - description: Master AHB Clock
+        - description: Slave AHB Clock
+
 additionalProperties: false
 
 examples: