aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ar71xx/files
diff options
context:
space:
mode:
authorKoen Vandeputte <koen.vandeputte@ncentric.com>2019-08-07 14:23:00 +0200
committerKoen Vandeputte <koen.vandeputte@ncentric.com>2019-08-27 10:31:06 +0200
commitc9b28b5703324bff3ef72e27862f1a1ce0e83e7d (patch)
tree8d003143392bb21740b8a67703918abddbd4473e /target/linux/ar71xx/files
parentd143a0a4f60e91861fe67dbff572b7b373c5abc4 (diff)
downloadupstream-c9b28b5703324bff3ef72e27862f1a1ce0e83e7d.tar.gz
upstream-c9b28b5703324bff3ef72e27862f1a1ce0e83e7d.tar.bz2
upstream-c9b28b5703324bff3ef72e27862f1a1ce0e83e7d.zip
ar71xx: ag71xx: replace ag71xx_get_phy_if_mode_name with phy_modes()
Backport of f73b2d64ed56 ("ath79: ag71xx: replace ag71xx_get_phy_if_mode_name() with phy_modes()") Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
Diffstat (limited to 'target/linux/ar71xx/files')
-rw-r--r--target/linux/ar71xx/files/drivers/net/ethernet/atheros/ag71xx/ag71xx_main.c23
1 files changed, 1 insertions, 22 deletions
diff --git a/target/linux/ar71xx/files/drivers/net/ethernet/atheros/ag71xx/ag71xx_main.c b/target/linux/ar71xx/files/drivers/net/ethernet/atheros/ag71xx/ag71xx_main.c
index 98c6b92c7d..21337a79c9 100644
--- a/target/linux/ar71xx/files/drivers/net/ethernet/atheros/ag71xx/ag71xx_main.c
+++ b/target/linux/ar71xx/files/drivers/net/ethernet/atheros/ag71xx/ag71xx_main.c
@@ -1294,27 +1294,6 @@ static const struct net_device_ops ag71xx_netdev_ops = {
#endif
};
-static const char *ag71xx_get_phy_if_mode_name(phy_interface_t mode)
-{
- switch (mode) {
- case PHY_INTERFACE_MODE_MII:
- return "MII";
- case PHY_INTERFACE_MODE_GMII:
- return "GMII";
- case PHY_INTERFACE_MODE_RMII:
- return "RMII";
- case PHY_INTERFACE_MODE_RGMII:
- return "RGMII";
- case PHY_INTERFACE_MODE_SGMII:
- return "SGMII";
- default:
- break;
- }
-
- return "unknown";
-}
-
-
static int ag71xx_probe(struct platform_device *pdev)
{
struct net_device *dev;
@@ -1440,7 +1419,7 @@ static int ag71xx_probe(struct platform_device *pdev)
pr_info("%s: Atheros AG71xx at 0x%08lx, irq %d, mode:%s\n",
dev->name, dev->base_addr, dev->irq,
- ag71xx_get_phy_if_mode_name(pdata->phy_if_mode));
+ phy_modes(pdata->phy_if_mode));
return 0;