From: Grygorii Strashko Date: Thu, 5 Jul 2018 17:02:51 +0000 (-0500) Subject: drivers: net: cpsw: fix phy dt node setting X-Git-Tag: v2018.09-rc1~26^2~2 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=d4bb98170006ed98d651fabefab1c0c2b6aac234;p=oweals%2Fu-boot.git drivers: net: cpsw: fix phy dt node setting Now CPSW driver will overwrite UCLASS_ETH node when PHY is connected and configured which is not correct. Use struct phydev->node instead. Signed-off-by: Grygorii Strashko Acked-by: Joe Hershberger --- diff --git a/drivers/net/cpsw.c b/drivers/net/cpsw.c index 9919d3919f..c31695eba9 100644 --- a/drivers/net/cpsw.c +++ b/drivers/net/cpsw.c @@ -999,7 +999,7 @@ static int cpsw_phy_init(struct cpsw_priv *priv, struct cpsw_slave *slave) #ifdef CONFIG_DM_ETH if (slave->data->phy_of_handle) - dev_set_of_offset(phydev->dev, slave->data->phy_of_handle); + phydev->node = offset_to_ofnode(slave->data->phy_of_handle); #endif priv->phydev = phydev;