diff options
Diffstat (limited to 'net/wireless/ethtool.c')
-rw-r--r-- | net/wireless/ethtool.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/net/wireless/ethtool.c b/net/wireless/ethtool.c index 7eecdf40cf80..48c48ffafa1d 100644 --- a/net/wireless/ethtool.c +++ b/net/wireless/ethtool.c | |||
@@ -2,6 +2,7 @@ | |||
2 | #include <net/cfg80211.h> | 2 | #include <net/cfg80211.h> |
3 | #include "core.h" | 3 | #include "core.h" |
4 | #include "ethtool.h" | 4 | #include "ethtool.h" |
5 | #include "rdev-ops.h" | ||
5 | 6 | ||
6 | static void cfg80211_get_drvinfo(struct net_device *dev, | 7 | static void cfg80211_get_drvinfo(struct net_device *dev, |
7 | struct ethtool_drvinfo *info) | 8 | struct ethtool_drvinfo *info) |
@@ -47,9 +48,8 @@ static void cfg80211_get_ringparam(struct net_device *dev, | |||
47 | memset(rp, 0, sizeof(*rp)); | 48 | memset(rp, 0, sizeof(*rp)); |
48 | 49 | ||
49 | if (rdev->ops->get_ringparam) | 50 | if (rdev->ops->get_ringparam) |
50 | rdev->ops->get_ringparam(wdev->wiphy, | 51 | rdev_get_ringparam(rdev, &rp->tx_pending, &rp->tx_max_pending, |
51 | &rp->tx_pending, &rp->tx_max_pending, | 52 | &rp->rx_pending, &rp->rx_max_pending); |
52 | &rp->rx_pending, &rp->rx_max_pending); | ||
53 | } | 53 | } |
54 | 54 | ||
55 | static int cfg80211_set_ringparam(struct net_device *dev, | 55 | static int cfg80211_set_ringparam(struct net_device *dev, |
@@ -62,8 +62,7 @@ static int cfg80211_set_ringparam(struct net_device *dev, | |||
62 | return -EINVAL; | 62 | return -EINVAL; |
63 | 63 | ||
64 | if (rdev->ops->set_ringparam) | 64 | if (rdev->ops->set_ringparam) |
65 | return rdev->ops->set_ringparam(wdev->wiphy, | 65 | return rdev_set_ringparam(rdev, rp->tx_pending, rp->rx_pending); |
66 | rp->tx_pending, rp->rx_pending); | ||
67 | 66 | ||
68 | return -ENOTSUPP; | 67 | return -ENOTSUPP; |
69 | } | 68 | } |
@@ -73,7 +72,7 @@ static int cfg80211_get_sset_count(struct net_device *dev, int sset) | |||
73 | struct wireless_dev *wdev = dev->ieee80211_ptr; | 72 | struct wireless_dev *wdev = dev->ieee80211_ptr; |
74 | struct cfg80211_registered_device *rdev = wiphy_to_dev(wdev->wiphy); | 73 | struct cfg80211_registered_device *rdev = wiphy_to_dev(wdev->wiphy); |
75 | if (rdev->ops->get_et_sset_count) | 74 | if (rdev->ops->get_et_sset_count) |
76 | return rdev->ops->get_et_sset_count(wdev->wiphy, dev, sset); | 75 | return rdev_get_et_sset_count(rdev, dev, sset); |
77 | return -EOPNOTSUPP; | 76 | return -EOPNOTSUPP; |
78 | } | 77 | } |
79 | 78 | ||
@@ -83,7 +82,7 @@ static void cfg80211_get_stats(struct net_device *dev, | |||
83 | struct wireless_dev *wdev = dev->ieee80211_ptr; | 82 | struct wireless_dev *wdev = dev->ieee80211_ptr; |
84 | struct cfg80211_registered_device *rdev = wiphy_to_dev(wdev->wiphy); | 83 | struct cfg80211_registered_device *rdev = wiphy_to_dev(wdev->wiphy); |
85 | if (rdev->ops->get_et_stats) | 84 | if (rdev->ops->get_et_stats) |
86 | rdev->ops->get_et_stats(wdev->wiphy, dev, stats, data); | 85 | rdev_get_et_stats(rdev, dev, stats, data); |
87 | } | 86 | } |
88 | 87 | ||
89 | static void cfg80211_get_strings(struct net_device *dev, u32 sset, u8 *data) | 88 | static void cfg80211_get_strings(struct net_device *dev, u32 sset, u8 *data) |
@@ -91,7 +90,7 @@ static void cfg80211_get_strings(struct net_device *dev, u32 sset, u8 *data) | |||
91 | struct wireless_dev *wdev = dev->ieee80211_ptr; | 90 | struct wireless_dev *wdev = dev->ieee80211_ptr; |
92 | struct cfg80211_registered_device *rdev = wiphy_to_dev(wdev->wiphy); | 91 | struct cfg80211_registered_device *rdev = wiphy_to_dev(wdev->wiphy); |
93 | if (rdev->ops->get_et_strings) | 92 | if (rdev->ops->get_et_strings) |
94 | rdev->ops->get_et_strings(wdev->wiphy, dev, sset, data); | 93 | rdev_get_et_strings(rdev, dev, sset, data); |
95 | } | 94 | } |
96 | 95 | ||
97 | const struct ethtool_ops cfg80211_ethtool_ops = { | 96 | const struct ethtool_ops cfg80211_ethtool_ops = { |