Commit f45c1974 authored by Linus Walleij's avatar Linus Walleij Committed by Jakub Kicinski

dt-bindings: net: ethernet-switch: Accept special variants

Accept special node naming variants for Marvell switches with
special node names as ABI.

This is maybe not the prettiest but it avoids special-casing
the Marvell MV88E6xxx bindings by copying a lot of generic
binding code down into that one binding just to special-case
these unfixable nodes.
Reviewed-by: default avatarRob Herring <robh@kernel.org>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Reviewed-by: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
Link: https://lore.kernel.org/r/20231127-marvell-88e6152-wan-led-v9-3-272934e04681@linaro.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent a6e44f30
...@@ -20,9 +20,26 @@ description: ...@@ -20,9 +20,26 @@ description:
select: false select: false
properties: allOf:
$nodename: # This condition is here to satisfy the case where certain device
pattern: "^(ethernet-)?switch(@.*)?$" # nodes have to preserve non-standard names because of
# backward-compatibility with boot loaders inspecting certain
# node names.
- if:
properties:
compatible:
contains:
enum:
- marvell,turris-mox-mv88e6085
- marvell,turris-mox-mv88e6190
then:
properties:
$nodename:
pattern: "switch[0-3]@[0-3]+$"
else:
properties:
$nodename:
pattern: "^(ethernet-)?switch(@.*)?$"
patternProperties: patternProperties:
"^(ethernet-)?ports$": "^(ethernet-)?ports$":
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment