diff options
author | Andrew Lunn <andrew@lunn.ch> | 2016-01-06 14:11:13 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-01-07 14:31:25 -0500 |
commit | 2220943a21e26d97d7fd8f83c004b947326b469d (patch) | |
tree | 946d1428fce5312b0537137411784c8b0c41c222 /drivers/net/ethernet/synopsys | |
parent | 053e7e169229adebbc27fc176c5369398e9f5eba (diff) |
phy: Centralise print about attached phy
Many Ethernet drivers contain the same netdev_info() print statement
about the attached phy. Move it into the phy device code. Additionally
add a varargs function which can be used to append additional
information.
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/synopsys')
-rw-r--r-- | drivers/net/ethernet/synopsys/dwc_eth_qos.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/net/ethernet/synopsys/dwc_eth_qos.c b/drivers/net/ethernet/synopsys/dwc_eth_qos.c index 9066d7a8483c..b25ee370254a 100644 --- a/drivers/net/ethernet/synopsys/dwc_eth_qos.c +++ b/drivers/net/ethernet/synopsys/dwc_eth_qos.c | |||
@@ -972,9 +972,7 @@ static int dwceqos_mii_probe(struct net_device *ndev) | |||
972 | } | 972 | } |
973 | 973 | ||
974 | if (netif_msg_probe(lp)) | 974 | if (netif_msg_probe(lp)) |
975 | netdev_dbg(lp->ndev, | 975 | phy_attached_info(phydev); |
976 | "phydev %p, phydev->phy_id 0xa%x, phydev->addr 0x%x\n", | ||
977 | phydev, phydev->phy_id, phydev->addr); | ||
978 | 976 | ||
979 | phydev->supported &= PHY_GBIT_FEATURES; | 977 | phydev->supported &= PHY_GBIT_FEATURES; |
980 | 978 | ||
@@ -983,14 +981,6 @@ static int dwceqos_mii_probe(struct net_device *ndev) | |||
983 | lp->duplex = DUPLEX_UNKNOWN; | 981 | lp->duplex = DUPLEX_UNKNOWN; |
984 | lp->phy_dev = phydev; | 982 | lp->phy_dev = phydev; |
985 | 983 | ||
986 | if (netif_msg_probe(lp)) { | ||
987 | netdev_dbg(lp->ndev, "phy_addr 0x%x, phy_id 0x%08x\n", | ||
988 | lp->phy_dev->addr, lp->phy_dev->phy_id); | ||
989 | |||
990 | netdev_dbg(lp->ndev, "attach [%s] phy driver\n", | ||
991 | lp->phy_dev->drv->name); | ||
992 | } | ||
993 | |||
994 | return 0; | 984 | return 0; |
995 | } | 985 | } |
996 | 986 | ||