diff options
-rw-r--r-- | drivers/net/ethernet/ti/cpsw.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c index 36aa109416c4..18d83d8d7f74 100644 --- a/drivers/net/ethernet/ti/cpsw.c +++ b/drivers/net/ethernet/ti/cpsw.c | |||
@@ -1871,18 +1871,8 @@ static int cpsw_probe_dt(struct cpsw_platform_data *data, | |||
1871 | mdio_node = of_find_node_by_phandle(be32_to_cpup(parp)); | 1871 | mdio_node = of_find_node_by_phandle(be32_to_cpup(parp)); |
1872 | phyid = be32_to_cpup(parp+1); | 1872 | phyid = be32_to_cpup(parp+1); |
1873 | mdio = of_find_device_by_node(mdio_node); | 1873 | mdio = of_find_device_by_node(mdio_node); |
1874 | 1874 | snprintf(slave_data->phy_id, sizeof(slave_data->phy_id), | |
1875 | if (strncmp(mdio->name, "gpio", 4) == 0) { | 1875 | PHY_ID_FMT, mdio->name, phyid); |
1876 | /* GPIO bitbang MDIO driver attached */ | ||
1877 | struct mii_bus *bus = dev_get_drvdata(&mdio->dev); | ||
1878 | |||
1879 | snprintf(slave_data->phy_id, sizeof(slave_data->phy_id), | ||
1880 | PHY_ID_FMT, bus->id, phyid); | ||
1881 | } else { | ||
1882 | /* davinci MDIO driver attached */ | ||
1883 | snprintf(slave_data->phy_id, sizeof(slave_data->phy_id), | ||
1884 | PHY_ID_FMT, mdio->name, phyid); | ||
1885 | } | ||
1886 | 1876 | ||
1887 | mac_addr = of_get_mac_address(slave_node); | 1877 | mac_addr = of_get_mac_address(slave_node); |
1888 | if (mac_addr) | 1878 | if (mac_addr) |