aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/mac80211.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/mac80211.h')
-rw-r--r--include/net/mac80211.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index b0787a1dea9..3f1e03b521e 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -1102,6 +1102,10 @@ enum ieee80211_hw_flags {
1102 * 1102 *
1103 * @max_rates: maximum number of alternate rate retry stages 1103 * @max_rates: maximum number of alternate rate retry stages
1104 * @max_rate_tries: maximum number of tries for each stage 1104 * @max_rate_tries: maximum number of tries for each stage
1105 *
1106 * @napi_weight: weight used for NAPI polling. You must specify an
1107 * appropriate value here if a napi_poll operation is provided
1108 * by your driver.
1105 */ 1109 */
1106struct ieee80211_hw { 1110struct ieee80211_hw {
1107 struct ieee80211_conf conf; 1111 struct ieee80211_conf conf;
@@ -1113,6 +1117,7 @@ struct ieee80211_hw {
1113 int channel_change_time; 1117 int channel_change_time;
1114 int vif_data_size; 1118 int vif_data_size;
1115 int sta_data_size; 1119 int sta_data_size;
1120 int napi_weight;
1116 u16 queues; 1121 u16 queues;
1117 u16 max_listen_interval; 1122 u16 max_listen_interval;
1118 s8 max_signal; 1123 s8 max_signal;
@@ -1687,6 +1692,8 @@ enum ieee80211_ampdu_mlme_action {
1687 * switch operation for CSAs received from the AP may implement this 1692 * switch operation for CSAs received from the AP may implement this
1688 * callback. They must then call ieee80211_chswitch_done() to indicate 1693 * callback. They must then call ieee80211_chswitch_done() to indicate
1689 * completion of the channel switch. 1694 * completion of the channel switch.
1695 *
1696 * @napi_poll: Poll Rx queue for incoming data frames.
1690 */ 1697 */
1691struct ieee80211_ops { 1698struct ieee80211_ops {
1692 int (*tx)(struct ieee80211_hw *hw, struct sk_buff *skb); 1699 int (*tx)(struct ieee80211_hw *hw, struct sk_buff *skb);
@@ -1752,6 +1759,7 @@ struct ieee80211_ops {
1752 void (*flush)(struct ieee80211_hw *hw, bool drop); 1759 void (*flush)(struct ieee80211_hw *hw, bool drop);
1753 void (*channel_switch)(struct ieee80211_hw *hw, 1760 void (*channel_switch)(struct ieee80211_hw *hw,
1754 struct ieee80211_channel_switch *ch_switch); 1761 struct ieee80211_channel_switch *ch_switch);
1762 int (*napi_poll)(struct ieee80211_hw *hw, int budget);
1755}; 1763};
1756 1764
1757/** 1765/**
@@ -1897,6 +1905,22 @@ void ieee80211_free_hw(struct ieee80211_hw *hw);
1897 */ 1905 */
1898void ieee80211_restart_hw(struct ieee80211_hw *hw); 1906void ieee80211_restart_hw(struct ieee80211_hw *hw);
1899 1907
1908/** ieee80211_napi_schedule - schedule NAPI poll
1909 *
1910 * Use this function to schedule NAPI polling on a device.
1911 *
1912 * @hw: the hardware to start polling
1913 */
1914void ieee80211_napi_schedule(struct ieee80211_hw *hw);
1915
1916/** ieee80211_napi_complete - complete NAPI polling
1917 *
1918 * Use this function to finish NAPI polling on a device.
1919 *
1920 * @hw: the hardware to stop polling
1921 */
1922void ieee80211_napi_complete(struct ieee80211_hw *hw);
1923
1900/** 1924/**
1901 * ieee80211_rx - receive frame 1925 * ieee80211_rx - receive frame
1902 * 1926 *