Home
last modified time | relevance | path

Searched hist:"19334920 eaf7df3f69950b040ede6c7598425a5b" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/net/dsa/
H A Dslave.cdiff 19334920eaf7df3f69950b040ede6c7598425a5b Mon Feb 16 23:23:51 CST 2015 Guenter Roeck <linux@roeck-us.net> net: dsa: Set valid phy interface type

If the phy interface mode is not found in devicetree, or if devicetree
is not configured, of_get_phy_mode returns -ENODEV. The current code
sets the phy interface mode to the return value from of_get_phy_mode
without checking if it is valid.

This invalid phy interface mode is passed as parameter to of_phy_connect
or to phy_connect_direct. This sets the phy interface mode to the invalid
value, which in turn causes problems for any code using phydev->interface.

Fixes: b31f65fb4383 ("net: dsa: slave: Fix autoneg for phys on switch MDIO bus")
Fixes: 0d8bcdd383b8 ("net: dsa: allow for more complex PHY setups")
Cc: Florian Fainelli <f.fainelli@gmail.com>
Cc: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>