diff options
author | Johannes Berg <johannes.berg@intel.com> | 2011-01-18 07:51:05 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-01-19 11:36:11 -0500 |
commit | 0b01f030d38e00650e2db42da083d8647aad40a5 (patch) | |
tree | 14519750d9b6cdb046624dd87d5323a4826821e2 /include/net/mac80211.h | |
parent | ac1bd8464f161ed1475ef73c431b926256c6b5bb (diff) |
mac80211: track receiver's aggregation reorder buffer size
The aggregation code currently doesn't implement the
buffer size negotiation. It will always request a max
buffer size (which is fine, if a little pointless, as
the mac80211 code doesn't know and might just use 0
instead), but if the peer requests a smaller size it
isn't possible to honour this request.
In order to fix this, look at the buffer size in the
addBA response frame, keep track of it and pass it to
the driver in the ampdu_action callback when called
with the IEEE80211_AMPDU_TX_OPERATIONAL action. That
way the driver can limit the number of subframes in
aggregates appropriately.
Note that this doesn't fix any drivers apart from the
addition of the new argument -- they all need to be
updated separately to use this variable!
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include/net/mac80211.h')
-rw-r--r-- | include/net/mac80211.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/net/mac80211.h b/include/net/mac80211.h index d024fc563e7b..5afe341b4010 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h | |||
@@ -1731,6 +1731,10 @@ enum ieee80211_ampdu_mlme_action { | |||
1731 | * ieee80211_ampdu_mlme_action. Starting sequence number (@ssn) | 1731 | * ieee80211_ampdu_mlme_action. Starting sequence number (@ssn) |
1732 | * is the first frame we expect to perform the action on. Notice | 1732 | * is the first frame we expect to perform the action on. Notice |
1733 | * that TX/RX_STOP can pass NULL for this parameter. | 1733 | * that TX/RX_STOP can pass NULL for this parameter. |
1734 | * The @buf_size parameter is only valid when the action is set to | ||
1735 | * %IEEE80211_AMPDU_TX_OPERATIONAL and indicates the peer's reorder | ||
1736 | * buffer size (number of subframes) for this session -- aggregates | ||
1737 | * containing more subframes than this may not be transmitted to the peer. | ||
1734 | * Returns a negative error code on failure. | 1738 | * Returns a negative error code on failure. |
1735 | * The callback can sleep. | 1739 | * The callback can sleep. |
1736 | * | 1740 | * |
@@ -1833,7 +1837,8 @@ struct ieee80211_ops { | |||
1833 | int (*ampdu_action)(struct ieee80211_hw *hw, | 1837 | int (*ampdu_action)(struct ieee80211_hw *hw, |
1834 | struct ieee80211_vif *vif, | 1838 | struct ieee80211_vif *vif, |
1835 | enum ieee80211_ampdu_mlme_action action, | 1839 | enum ieee80211_ampdu_mlme_action action, |
1836 | struct ieee80211_sta *sta, u16 tid, u16 *ssn); | 1840 | struct ieee80211_sta *sta, u16 tid, u16 *ssn, |
1841 | u8 buf_size); | ||
1837 | int (*get_survey)(struct ieee80211_hw *hw, int idx, | 1842 | int (*get_survey)(struct ieee80211_hw *hw, int idx, |
1838 | struct survey_info *survey); | 1843 | struct survey_info *survey); |
1839 | void (*rfkill_poll)(struct ieee80211_hw *hw); | 1844 | void (*rfkill_poll)(struct ieee80211_hw *hw); |