]> git.baikalelectronics.ru Git - kernel.git/commit
net: stmmac: platform: Fix MDIO init for platforms without PHY
authorPadmanabhan Rajanbabu <p.rajanbabu@samsung.com>
Thu, 19 Dec 2019 10:17:01 +0000 (15:47 +0530)
committerDavid S. Miller <davem@davemloft.net>
Sat, 21 Dec 2019 05:27:51 +0000 (21:27 -0800)
commit4534b843f7c8530006c0284242527e03d52c0a4b
treed60920d138628ca065ac32faa63d9b4e25878bb3
parente94d6a8e14635d258870ff9b0d2d0983a9c4cf65
net: stmmac: platform: Fix MDIO init for platforms without PHY

The current implementation of "stmmac_dt_phy" function initializes
the MDIO platform bus data, even in the absence of PHY. This fix
will skip MDIO initialization if there is no PHY present.

Fixes: dcaf3bd ("net: stmmac: Convert to phylink and remove phylib logic")
Acked-by: Jayati Sahu <jayati.sahu@samsung.com>
Signed-off-by: Sriram Dash <sriram.dash@samsung.com>
Signed-off-by: Padmanabhan Rajanbabu <p.rajanbabu@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c