net: bridge: use __ethtool_get_ksettings
authorDavid Decotigny <decot@googlers.com>
Wed, 24 Feb 2016 18:58:09 +0000 (10:58 -0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 26 Feb 2016 03:06:46 +0000 (22:06 -0500)
Signed-off-by: David Decotigny <decot@googlers.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/bridge/br_if.c

index c367b3e1b5ac21f0d482c330569ac6280aa4467d..b37a1cc97d98136d8fe48aa6d28c0c4110887129 100644 (file)
  */
 static int port_cost(struct net_device *dev)
 {
-       struct ethtool_cmd ecmd;
+       struct ethtool_link_ksettings ecmd;
 
-       if (!__ethtool_get_settings(dev, &ecmd)) {
-               switch (ethtool_cmd_speed(&ecmd)) {
+       if (!__ethtool_get_link_ksettings(dev, &ecmd)) {
+               switch (ecmd.base.speed) {
                case SPEED_10000:
                        return 2;
                case SPEED_1000: