EN7581 and AN7583 SoCs support connecting multiple external SerDes to GDM3 or GDM4 ports via a hw multiplexer that manages the traffic in a TDM manner. As a result multiple net_devices can connect to the same GDM{3,4} port and there is a theoretical "1:n" relation between GDM ports and net_devices. Introduce the ethernet-port property in order to model a given net_device that is connected via the external multiplexer to the GDM{3,4} port (that is represented by the ethernet property. Please note GDM1 or GDM2 does not support the connection with the external multiplexer and are represented by ethernet property. Signed-off-by: Lorenzo Bianconi --- .../devicetree/bindings/net/airoha,en7581-eth.yaml | 44 +++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml b/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml index fbe2ddcdd909cb3d853a4ab9e9fec4af1d096c52..ebbd433e9c9fbfaefd8d07c3678cabc91574d125 100644 --- a/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml +++ b/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml @@ -130,6 +130,30 @@ patternProperties: maximum: 4 description: GMAC port identifier + '#address-cells': + const: 1 + '#size-cells': + const: 0 + + patternProperties: + "^ethernet-port@[0-5]$": + type: object + unevaluatedProperties: false + $ref: ethernet-controller.yaml# + description: External ethernet port ID available on the GDM port + + properties: + compatible: + const: airoha,eth-port + + reg: + maxItems: 1 + description: External ethernet port identifier + + required: + - compatible + - reg + required: - reg - compatible @@ -191,9 +215,27 @@ examples: #address-cells = <1>; #size-cells = <0>; - mac: ethernet@1 { + mac1: ethernet@1 { compatible = "airoha,eth-mac"; reg = <1>; }; + + mac4: ethernet@4 { + compatible = "airoha,eth-mac"; + reg = <4>; + + #address-cells = <1>; + #size-cells = <0>; + + ethernet-port@0 { + compatible = "airoha,eth-port"; + reg = <0>; + }; + + ethernet-port@1 { + compatible = "airoha,eth-port"; + reg = <1>; + }; + }; }; }; -- 2.53.0