# \[PATCH\] dt-bindings: usb: amlogic,meson-g12a-usb-ctrl: add S4 support

- From: \<hidden\>
- Date: 2026-11-06 10:46:51 
- List: linux-arm-kernel
- Page: https://ratatoskr.run/linux-arm-kernel/2026/11/17877397
- Thread: https://ratatoskr.run/linux-usb/2026/11/17877397/t.md

```text
From: Christian Stefan Kövér-Draxl <redacted>

The S4 USB glue is the G12A one, but it fronts an xHCI host controller
instead of a DWC3 core, with two USB2 PHYs and no USB3 PHY. Add an S4
compatible with the G12A one as fallback, and allow a generic xHCI
child node.

Signed-off-by: Christian Stefan Kövér-Draxl <redacted>
---
Tool use (Documentation/process/generated-content.rst):
This work was done with the help of an AI coding assistant, Claude
(Anthropic), used through Claude Code over many sessions. It did a large
part of the hands-on work: it read the vendor kernel and the firmware
interfaces, probed registers on the board, drafted the code and the
changelogs, and ran the builds, checkpatch, dt_binding_check and the
tests on the hardware. I directed the work, reviewed every change and
the final patches, and take responsibility for them. There is no single
prompt to quote; the sessions were of the form "find out why X fails on
this board, fix it, test it on the box".

Tested on an Amediatech X98Q TV box (Amlogic S905W2, S4 family, 2 GiB),
vendor U-Boot and BL31/OP-TEE, Linux 7.3 plus this work.

 .../usb/amlogic,meson-g12a-usb-ctrl.yaml      | 24 ++++++++++++-------
 1 file changed, 16 insertions(+), 8 deletions(-)

diff --git a/Documentation/devicetree/bindings/usb/amlogic,meson-g12a-usb-ctrl.yaml b/Documentation/devicetree/bindings/usb/amlogic,meson-g12a-usb-ctrl.yaml
index da757c1155d4..186390f930f8 100644
--- a/Documentation/devicetree/bindings/usb/amlogic,meson-g12a-usb-ctrl.yaml
+++ b/Documentation/devicetree/bindings/usb/amlogic,meson-g12a-usb-ctrl.yaml
@@ -27,14 +27,21 @@ description: |
 
   The Amlogic GXL, GXM & AXG SoCs doesn't embed an USB3 PHY.
 
+  The Amlogic S4 uses the G12A glue in front of an xHCI host controller
+  instead of a DWC3 core, with two USB2 PHYs and no USB3 PHY.
+
 properties:
   compatible:
-    enum:
-      - amlogic,meson-gxl-usb-ctrl
-      - amlogic,meson-gxm-usb-ctrl
-      - amlogic,meson-axg-usb-ctrl
-      - amlogic,meson-g12a-usb-ctrl
-      - amlogic,meson-a1-usb-ctrl
+    oneOf:
+      - enum:
+          - amlogic,meson-gxl-usb-ctrl
+          - amlogic,meson-gxm-usb-ctrl
+          - amlogic,meson-axg-usb-ctrl
+          - amlogic,meson-g12a-usb-ctrl
+          - amlogic,meson-a1-usb-ctrl
+      - items:
+          - const: amlogic,meson-s4-usb-ctrl
+          - const: amlogic,meson-g12a-usb-ctrl
 
   ranges: true
 
@@ -82,6 +89,7 @@ patternProperties:
     oneOf:
       - $ref: dwc2.yaml#
       - $ref: snps,dwc3.yaml#
+      - $ref: generic-xhci.yaml#
 
 additionalProperties: false
 
@@ -102,8 +110,8 @@ allOf:
   - if:
       properties:
         compatible:
-          enum:
-            - amlogic,meson-g12a-usb-ctrl
+          contains:
+            const: amlogic,meson-g12a-usb-ctrl
 
     then:
       properties:

base-commit: 7be4bc52fd9e0e55dc9a2e0232b89427d2c4b614
-- 
2.56.0


```
