]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: xrs700x: convert to phylink_generic_validate()
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Wed, 2 Feb 2022 10:24:28 +0000 (10:24 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 3 Feb 2022 11:47:06 +0000 (11:47 +0000)
commitc611faea7e59681d4d2c298c83f88c2f186a2c0d
tree346d60871ca6a396b14f72723e4d0ab4cbfa0b38
parentc0776fd6e42415c0f76c8cafd7f914b75fa916f1
net: dsa: xrs700x: convert to phylink_generic_validate()

Populate the supported interfaces and MAC capabilities for the xrs700x
family of DSA switches and remove the old validate implementation to
allow DSA to use phylink_generic_validate() for this switch driver.

According to commit 78de80e7c4bd ("net: dsa: add Arrow SpeedChips
XRS700x driver") the switch supports one RMII port and up to three
RGMII ports. This commit assumes that port 0 is the RMII port and the
remainder are RGMII.

This commit also results in the Autoneg bit being set in the ethtool
link modes, which wasn't in the original; if this switch supports
RGMII to a 10/100/1G PHY, then surely we want to allow Autoneg on the
PHY.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/xrs700x/xrs700x.c