]> git.itanic.dy.fi Git - linux-stable/commitdiff
dt-bindings: net: dsa: Require ports or ethernet-ports
authorLinus Walleij <linus.walleij@linaro.org>
Tue, 24 Oct 2023 13:20:27 +0000 (15:20 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 25 Oct 2023 09:27:59 +0000 (10:27 +0100)
Bindings using dsa.yaml#/$defs/ethernet-ports specify that
a DSA switch node need to have a ports or ethernet-ports
subnode, and that is actually required, so add requirements
using oneOf.

Suggested-by: Rob Herring <robh@kernel.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/devicetree/bindings/net/dsa/dsa.yaml

index 6107189d276a2bdc58de6786389bd21dca821bd2..2abd036578d1501e48e0d488339bf75f2ae3dac7 100644 (file)
@@ -46,4 +46,10 @@ $defs:
             $ref: dsa-port.yaml#
             unevaluatedProperties: false
 
+oneOf:
+  - required:
+      - ports
+  - required:
+      - ethernet-ports
+
 ...