drivers: net: cpsw: fix parsing of phy-handle DT property in dual_emac config
Commit 9e42f715 ("drivers: net: cpsw: add phy-handle parsing") saved the "phy-handle" phandle into a new cpsw_priv field. However, phy connections are per-slave, so the phy_node field should be in cpsw_slave_data rather than cpsw_priv. This would go unnoticed in a single emac configuration. But in dual_emac mode, the last "phy-handle" property parsed for either slave would be used by both of them, causing them both to refer to the same phy_device. Fixes: 9e42f715 ("drivers: net: cpsw: add phy-handle parsing") Signed-off-by: NDavid Rivshin <drivshin@allworx.com> Tested-by: NNicolas Chauvet <kwizart@gmail.com> Tested-by: NAndrew Goodbody <andrew.goodbody@cambrionix.com> Reviewed-by: NMugunthan V N <mugunthanvnm@ti.com> Reviewed-by: NGrygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
Showing
想要评论请 注册 或 登录