summaryrefslogtreecommitdiffstats
path: root/drivers/net/mdio/fwnode_mdio.c
diff options
context:
space:
mode:
authorIoana Ciornei <ioana.ciornei@nxp.com>2021-06-17 14:29:03 +0200
committerDavid S. Miller <davem@davemloft.net>2021-06-17 21:06:52 +0200
commit70ef608c224af39c7eee850d763b986954594de6 (patch)
treec32dc1217e2cd9e092d4f4f72463f31c7e7cbf1a /drivers/net/mdio/fwnode_mdio.c
parentr8152: store the information of the pipes (diff)
downloadlinux-70ef608c224af39c7eee850d763b986954594de6.tar.xz
linux-70ef608c224af39c7eee850d763b986954594de6.zip
net: mdio: setup of_node for the MDIO device
By mistake, the of_node of the MDIO device was not setup in the patch linked below. As a consequence, any PHY driver that depends on the of_node in its probe callback was not be able to successfully finish its probe on a PHY, thus the Generic PHY driver was used instead. Fix this by actually setting up the of_node. Fixes: bc1bee3b87ee ("net: mdiobus: Introduce fwnode_mdiobus_register_phy()") Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/mdio/fwnode_mdio.c')
-rw-r--r--drivers/net/mdio/fwnode_mdio.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/mdio/fwnode_mdio.c b/drivers/net/mdio/fwnode_mdio.c
index e96766da8de4..283ddb1185bd 100644
--- a/drivers/net/mdio/fwnode_mdio.c
+++ b/drivers/net/mdio/fwnode_mdio.c
@@ -65,6 +65,7 @@ int fwnode_mdiobus_phy_device_register(struct mii_bus *mdio,
* can be looked up later
*/
fwnode_handle_get(child);
+ phy->mdio.dev.of_node = to_of_node(child);
phy->mdio.dev.fwnode = child;
/* All data is now stored in the phy struct;