提交 3c9b803b 编写于 作者: P Philippe Reynes 提交者: David S. Miller

net: usb: asix88179_178a: use new api ethtool_{get|set}_link_ksettings

The ethtool api {get|set}_settings is deprecated.
We move this driver to new api {get|set}_link_ksettings.

As I don't have the hardware, I'd be very pleased if
someone may test this patch.
Signed-off-by: NPhilippe Reynes <tremyfr@gmail.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 29ccc49d
...@@ -620,16 +620,18 @@ ax88179_get_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom, ...@@ -620,16 +620,18 @@ ax88179_get_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
return 0; return 0;
} }
static int ax88179_get_settings(struct net_device *net, struct ethtool_cmd *cmd) static int ax88179_get_link_ksettings(struct net_device *net,
struct ethtool_link_ksettings *cmd)
{ {
struct usbnet *dev = netdev_priv(net); struct usbnet *dev = netdev_priv(net);
return mii_ethtool_gset(&dev->mii, cmd); return mii_ethtool_get_link_ksettings(&dev->mii, cmd);
} }
static int ax88179_set_settings(struct net_device *net, struct ethtool_cmd *cmd) static int ax88179_set_link_ksettings(struct net_device *net,
const struct ethtool_link_ksettings *cmd)
{ {
struct usbnet *dev = netdev_priv(net); struct usbnet *dev = netdev_priv(net);
return mii_ethtool_sset(&dev->mii, cmd); return mii_ethtool_set_link_ksettings(&dev->mii, cmd);
} }
static int static int
...@@ -826,11 +828,11 @@ static const struct ethtool_ops ax88179_ethtool_ops = { ...@@ -826,11 +828,11 @@ static const struct ethtool_ops ax88179_ethtool_ops = {
.set_wol = ax88179_set_wol, .set_wol = ax88179_set_wol,
.get_eeprom_len = ax88179_get_eeprom_len, .get_eeprom_len = ax88179_get_eeprom_len,
.get_eeprom = ax88179_get_eeprom, .get_eeprom = ax88179_get_eeprom,
.get_settings = ax88179_get_settings,
.set_settings = ax88179_set_settings,
.get_eee = ax88179_get_eee, .get_eee = ax88179_get_eee,
.set_eee = ax88179_set_eee, .set_eee = ax88179_set_eee,
.nway_reset = usbnet_nway_reset, .nway_reset = usbnet_nway_reset,
.get_link_ksettings = ax88179_get_link_ksettings,
.set_link_ksettings = ax88179_set_link_ksettings,
}; };
static void ax88179_set_multicast(struct net_device *net) static void ax88179_set_multicast(struct net_device *net)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册