aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/of_mdio.h
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2014-05-16 16:14:04 +0200
committerDavid S. Miller <davem@davemloft.net>2014-05-16 17:18:49 -0400
commita75951217472c522c324adb0a4de3ba69d656ef5 (patch)
tree5202fc459802039f73709b959fecedca4d539353 /include/linux/of_mdio.h
parentnet: phy: decouple PHY id and PHY address in fixed PHY driver (diff)
downloadwireguard-linux-a75951217472c522c324adb0a4de3ba69d656ef5.tar.xz
wireguard-linux-a75951217472c522c324adb0a4de3ba69d656ef5.zip
net: phy: extend fixed driver with fixed_phy_register()
The existing fixed_phy_add() function has several drawbacks that prevents it from being used as is for OF-based declaration of fixed PHYs: * The address of the PHY on the fake bus needs to be passed, while a dynamic allocation is desired. * Since the phy_device instantiation is post-poned until the next mdiobus scan, there is no way to associate the fixed PHY with its OF node, which later prevents of_phy_connect() from finding this fixed PHY from a given OF node. To solve this, this commit introduces fixed_phy_register(), which will allocate an available PHY address, add the PHY using fixed_phy_add() and instantiate the phy_device structure associated with the provided OF node. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Grant Likely <grant.likely@linaro.org> Tested-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/of_mdio.h')
0 files changed, 0 insertions, 0 deletions