summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>2021-11-16 11:09:31 +0100
committerDavid S. Miller <davem@davemloft.net>2021-11-17 12:25:45 +0100
commit8ea8c5b492d4e593c64d71c986c320faade69e17 (patch)
tree8fb410e24df17931f20db71d26d70c3dc0da767a
parentMerge branch 'mtk_eth_soc-phylink' (diff)
downloadlinux-8ea8c5b492d4e593c64d71c986c320faade69e17.tar.xz
linux-8ea8c5b492d4e593c64d71c986c320faade69e17.zip
net: ocelot_net: populate supported_interfaces member
Populate the phy interface mode bitmap for the MSCC Ocelot driver with the interface modes supported by the MAC. Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/mscc/ocelot_net.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mscc/ocelot_net.c b/drivers/net/ethernet/mscc/ocelot_net.c
index eaeba60b1bba..37c158df60ce 100644
--- a/drivers/net/ethernet/mscc/ocelot_net.c
+++ b/drivers/net/ethernet/mscc/ocelot_net.c
@@ -1655,6 +1655,9 @@ static int ocelot_port_phylink_create(struct ocelot *ocelot, int port,
priv->phylink_config.dev = &priv->dev->dev;
priv->phylink_config.type = PHYLINK_NETDEV;
+ __set_bit(ocelot_port->phy_mode,
+ priv->phylink_config.supported_interfaces);
+
phylink = phylink_create(&priv->phylink_config,
of_fwnode_handle(portnp),
phy_mode, &ocelot_phylink_ops);