diff options
author | Heiner Kallweit <hkallweit1@gmail.com> | 2020-01-19 16:32:49 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-01-20 12:43:24 +0300 |
commit | df007186488e33716ccf0c01f93cc5fe1ef91847 (patch) | |
tree | 8ed37adbc7ebc589264b473a90e3051d599f6fee /drivers/net/ethernet/realtek | |
parent | 2ab1d925aa4c0c179dd1eb492e8c03536972707b (diff) | |
download | linux-df007186488e33716ccf0c01f93cc5fe1ef91847.tar.xz |
r8169: use generic ndo_do_ioctl handler phy_do_ioctl
Replace rtl8169_ioctl with new generic function phy_do_ioctl.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/realtek')
-rw-r--r-- | drivers/net/ethernet/realtek/r8169_main.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c index 6d699df7d27f..175f951b6547 100644 --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c @@ -2298,16 +2298,6 @@ static int rtl_set_mac_address(struct net_device *dev, void *p) return 0; } -static int rtl8169_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) -{ - struct rtl8169_private *tp = netdev_priv(dev); - - if (!netif_running(dev)) - return -ENODEV; - - return phy_mii_ioctl(tp->phydev, ifr, cmd); -} - static void rtl_wol_suspend_quirk(struct rtl8169_private *tp) { switch (tp->mac_version) { @@ -5168,7 +5158,7 @@ static const struct net_device_ops rtl_netdev_ops = { .ndo_fix_features = rtl8169_fix_features, .ndo_set_features = rtl8169_set_features, .ndo_set_mac_address = rtl_set_mac_address, - .ndo_do_ioctl = rtl8169_ioctl, + .ndo_do_ioctl = phy_do_ioctl, .ndo_set_rx_mode = rtl_set_rx_mode, #ifdef CONFIG_NET_POLL_CONTROLLER .ndo_poll_controller = rtl8169_netpoll, |