net: dsa: sja1105: Avoid error message for unknown PHY mode on disabled ports
Vladimir Oltean
maintainerPATCH v2 1/1 net: dsa: sja1105: Avoid error message for unknown PHY mode on disabled ports
From: Vladimir Oltean <[email protected]>
When sja1105_init_mii_settings iterates over the port list, it prints this message for disabled ports, because they don't have a valid phy-mode:
[ 4.778702] sja1105 spi2.0: Unsupported PHY mode unknown!
--- drivers/net/dsa/sja1105/sja1105_main.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/dsa/sja1105/sja1105_main.c +3 -0
@@ -162,6 +162,9 @@ static int sja1105_init_mii_settings(struct sja1105_private *priv, mii = table->entries;for (i =0 ; i <SJA1105_NUM_PORTS ; i++) { +if (dsa_is_unused_port (priv->ds, i)) +continue ; +switch (ports[i].phy_mode) {case PHY_INTERFACE_MODE_MII : mii->xmii_mode[i] =XMII_MODE_MII ;
Signature · 1 line
2.17.1
Quoted 11 lines · Vladimir Oltean
From: Vladimir Oltean <[email protected]>
When
sja1105_init_mii_settingsiterates over the port list, it prints this message for disabled ports, because they don't have a valid phy-mode:[ 4.778702] sja1105 spi2.0: Unsupported PHY mode unknown!Suggested-by Andrew Lunn <[email protected]>Suggested-by Vivien Didelot <[email protected]>Signed-off-by Vladimir Oltean <[email protected]>
Signature · 1 line
Florian
Quoted 11 lines · Vladimir Oltean
From: Vladimir Oltean <[email protected]>
When
sja1105_init_mii_settingsiterates over the port list, it prints this message for disabled ports, because they don't have a valid phy-mode:[ 4.778702] sja1105 spi2.0: Unsupported PHY mode unknown!Suggested-by Andrew Lunn <[email protected]>Suggested-by Vivien Didelot <[email protected]>Signed-off-by Vladimir Oltean <[email protected]>
From: Vladimir Oltean <[email protected]>
Date: Thu, 19 Mar 2020 22:12:10 +0200
Quoted 11 lines
From: Vladimir Oltean <[email protected]>
When
sja1105_init_mii_settingsiterates over the port list, it prints this message for disabled ports, because they don't have a valid phy-mode:[ 4.778702] sja1105 spi2.0: Unsupported PHY mode unknown!Suggested-by Andrew Lunn <[email protected]>Suggested-by Vivien Didelot <[email protected]>Signed-off-by Vladimir Oltean <[email protected]>
Applied, thanks.