]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
dt-bindings: usb: gpio-sbu-mux: Make 'enable-gpios' optional
authorFrancesco Dolcini <francesco.dolcini@toradex.com>
Mon, 3 Jun 2024 08:35:57 +0000 (10:35 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 4 Jun 2024 13:44:57 +0000 (15:44 +0200)
The enable gpio is not required when the SBU mux is used only for
orientation, make enable-gpios required only for alternate mode
switch use case.

Acked-by: Conor Dooley <conor.dooley@microchip.com>
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Link: https://lore.kernel.org/r/20240603083558.9629-2-francesco@dolcini.it
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Documentation/devicetree/bindings/usb/gpio-sbu-mux.yaml

index 88e1607cf053ac11ae7bf76ea13f09ad4b15c7da..30edcce82f970ec87c48ff281e7d69f3234ca41c 100644 (file)
@@ -44,13 +44,18 @@ properties:
 
 required:
   - compatible
-  - enable-gpios
   - select-gpios
   - orientation-switch
   - port
 
 allOf:
   - $ref: usb-switch.yaml#
+  - if:
+      required:
+        - mode-switch
+    then:
+      required:
+        - enable-gpios
 
 additionalProperties: false