[PATCH v2 4/6] dt-bindings: gpu: v3d: Add SMS to the registers' list

Maíra Canal mcanal at igalia.com
Sat Mar 8 14:33:43 UTC 2025


V3D 7.1 exposes a new register block, called V3D_SMS. As BCM2712 has a
V3D 7.1 core, add a new register item to the list. Similar to the GCA
and bridge register, SMS is optional and should only be added for V3D
7.1 variants.

In order to enforce per-SoC register rules, add per-compatible
restrictions. The restrictions will assure that GCA will only be added
in BCM7268 (V3D 3.3) and SMS will only be added in BCM2712 (V3D 7.1).

Cc: Krzysztof Kozlowski <krzk+dt at kernel.org>
Cc: Conor Dooley <conor+dt at kernel.org>
Cc: Nicolas Saenz Julienne <nsaenz at kernel.org>
Cc: devicetree at vger.kernel.org
Signed-off-by: Maíra Canal <mcanal at igalia.com>
---
 .../devicetree/bindings/gpu/brcm,bcm-v3d.yaml      | 60 ++++++++++++++++++++--
 1 file changed, 55 insertions(+), 5 deletions(-)

diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml
index dc078ceeca9ac3447ba54a7c8830821f0b2a7f9f..c0caee055e8c18dbcac0e51aa192951996545695 100644
--- a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml
+++ b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml
@@ -27,15 +27,12 @@ properties:
       - description: core0 register (required)
       - description: GCA cache controller register (if GCA controller present)
       - description: bridge register (if no external reset controller)
+      - description: SMS register (if SMS controller present)
     minItems: 2
 
   reg-names:
-    items:
-      - const: hub
-      - const: core0
-      - enum: [ bridge, gca ]
-      - enum: [ bridge, gca ]
     minItems: 2
+    maxItems: 4
 
   interrupts:
     items:
@@ -60,6 +57,59 @@ required:
 
 additionalProperties: false
 
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - brcm,2711-v3d
+              - brcm,7278-v3d
+    then:
+      properties:
+        reg:
+          minItems: 2
+          maxItems: 3
+        reg-names:
+          items:
+            - const: hub
+            - const: core0
+            - const: bridge
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: brcm,2712-v3d
+    then:
+      properties:
+        reg:
+          minItems: 3
+          maxItems: 4
+        reg-names:
+          items:
+            - const: hub
+            - const: core0
+            - enum: [ bridge, sms ]
+            - enum: [ bridge, sms ]
+          minItems: 3
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: brcm,7268-v3d
+    then:
+      properties:
+        reg:
+          minItems: 3
+          maxItems: 4
+        reg-names:
+          items:
+            - const: hub
+            - const: core0
+            - enum: [ bridge, gca ]
+            - enum: [ bridge, gca ]
+          minItems: 3
+
 examples:
   - |
     gpu at f1200000 {

-- 
Git-154)



More information about the dri-devel mailing list