]> git.baikalelectronics.ru Git - kernel.git/commit
of: mdio: honor flags passed to of_phy_connect
authorFlorian Fainelli <f.fainelli@gmail.com>
Fri, 19 Sep 2014 20:07:49 +0000 (13:07 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 19 Sep 2014 20:27:07 +0000 (16:27 -0400)
commit069ba5623601c85d6fc62abdae82da4b10bd1227
tree18bd5a579a434c6cf627364c54ffa7b53338cc55
parent139c57e3ec2855a950549ebf4c4998ea90981b23
of: mdio: honor flags passed to of_phy_connect

Commit df4db92e0a6b ("net: phy: remove flags argument from phy_{attach,
connect, connect_direct}") removed the flags argument to the PHY library
calls to: phy_{attach,connect,connect_direct}.

Most Device Tree aware drivers call of_phy_connect() with the flag
argument set to 0, but some of them might want to set a different value
there in order for the PHY driver to key a specific behavior based on
the phy_device::phy_flags value.

Allow such drivers to set custom phy_flags as part of the
of_phy_connect() call since of_phy_connect() does start the PHY state
machine, it will call into the PHY driver config_init() callback which
is usually where a specific phy_flags value is important.

Fixes: df4db92e0a6b ("net: phy: remove flags argument from phy_{attach, connect, connect_direct}")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/of/of_mdio.c