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>
This commit is contained in:
Russell King (Oracle) 2021-11-16 10:09:31 +00:00 committed by David S. Miller
parent c11239f355
commit 8ea8c5b492

View file

@ -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);