summaryrefslogtreecommitdiffstats
path: root/net/mac80211/driver-ops.h
diff options
context:
space:
mode:
authorJohn W. Linville <linville@tuxdriver.com>2011-03-07 22:19:18 +0100
committerJohn W. Linville <linville@tuxdriver.com>2011-03-11 21:34:10 +0100
commit38c091590f6ed78fcaf114c14ce133e5b3f717e6 (patch)
tree4293471c1babf894eb5e0bf69e919a4256b428c5 /net/mac80211/driver-ops.h
parentwireless: add support for ethtool_ops->{get,set}_ringparam (diff)
downloadlinux-38c091590f6ed78fcaf114c14ce133e5b3f717e6.tar.xz
linux-38c091590f6ed78fcaf114c14ce133e5b3f717e6.zip
mac80211: implement support for cfg80211_ops->{get,set}_ringparam
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/driver-ops.h')
-rw-r--r--net/mac80211/driver-ops.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/net/mac80211/driver-ops.h b/net/mac80211/driver-ops.h
index 3729296f6f95..9c0d62bb0ea3 100644
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -526,4 +526,30 @@ static inline int drv_offchannel_tx_cancel_wait(struct ieee80211_local *local)
return ret;
}
+static inline int drv_set_ringparam(struct ieee80211_local *local,
+ u32 tx, u32 rx)
+{
+ int ret = -ENOTSUPP;
+
+ might_sleep();
+
+ trace_drv_set_ringparam(local, tx, rx);
+ if (local->ops->set_ringparam)
+ ret = local->ops->set_ringparam(&local->hw, tx, rx);
+ trace_drv_return_int(local, ret);
+
+ return ret;
+}
+
+static inline void drv_get_ringparam(struct ieee80211_local *local,
+ u32 *tx, u32 *tx_max, u32 *rx, u32 *rx_max)
+{
+ might_sleep();
+
+ trace_drv_get_ringparam(local, tx, tx_max, rx, rx_max);
+ if (local->ops->get_ringparam)
+ local->ops->get_ringparam(&local->hw, tx, tx_max, rx, rx_max);
+ trace_drv_return_void(local);
+}
+
#endif /* __MAC80211_DRIVER_OPS */