Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: net: dwmac: fix 'mac-mode' type

The 'mac-mode' property is similar to 'phy-mode' and 'phy-connection-type',
which are enums of mode strings.

The 'dwmac' driver supports almost all modes declared in the 'phy-mode'
enum (except for 1 or 2). But in general, there may be a case where
'mac-mode' becomes more generic and is moved as part of phylib or netdev.

In any case, the 'mac-mode' field should be made an enum, and it also makes
sense to just reference the 'phy-connection-type' from
'ethernet-controller.yaml'. That will also make it more future-proof for new
modes.

Fixes: 9c15d3597c62 ("dt-bindings: net: dwmac: document 'mac-mode' property")
Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>

authored by

Alexandru Ardelean and committed by
Jakub Kicinski
9e5c8d39 92974a1d

+1 -1
+1 -1
Documentation/devicetree/bindings/net/snps,dwmac.yaml
··· 113 113 const: stmmaceth 114 114 115 115 mac-mode: 116 - maxItems: 1 116 + $ref: ethernet-controller.yaml#/properties/phy-connection-type 117 117 description: 118 118 The property is identical to 'phy-mode', and assumes that there is mode 119 119 converter in-between the MAC & PHY (e.g. GMII-to-RGMII). This converter