diff options
author | Ron Rindjunsky <ron.rindjunsky@intel.com> | 2008-03-26 20:36:03 +0200 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-03-27 16:03:20 -0400 |
commit | cee24a3e580f1062c8bb8b1692b95014d882bc7d (patch) | |
tree | e7df5e0f987a817ff0c9b14142a4efc583d39fa2 /net/mac80211/rx.c | |
parent | 6c507cd0400cb51dd2ee251c1b8756b9375a1128 (diff) | |
download | linux-3.10-cee24a3e580f1062c8bb8b1692b95014d882bc7d.tar.gz linux-3.10-cee24a3e580f1062c8bb8b1692b95014d882bc7d.tar.bz2 linux-3.10-cee24a3e580f1062c8bb8b1692b95014d882bc7d.zip |
mac80211: A-MPDU MLME use dynamic allocation
This patch alters the A-MPDU MLME in sta_info to use dynamic allocation,
thus drastically improving memory usage - from a constant ~2 Kbyte in
the previous (static) allocation to a lower limit of ~200 Byte and an upper
limit of ~2 Kbyte.
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/rx.c')
-rw-r--r-- | net/mac80211/rx.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 644d2774469..d9c6ed5be4f 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -1514,9 +1514,10 @@ ieee80211_rx_h_ctrl(struct ieee80211_rx_data *rx) if (!rx->sta) return RX_CONTINUE; tid = le16_to_cpu(bar->control) >> 12; - tid_agg_rx = &(rx->sta->ampdu_mlme.tid_rx[tid]); - if (tid_agg_rx->state != HT_AGG_STATE_OPERATIONAL) + if (rx->sta->ampdu_mlme.tid_state_rx[tid] + != HT_AGG_STATE_OPERATIONAL) return RX_CONTINUE; + tid_agg_rx = rx->sta->ampdu_mlme.tid_rx[tid]; start_seq_num = le16_to_cpu(bar->start_seq_num) >> 4; @@ -2123,11 +2124,12 @@ static u8 ieee80211_rx_reorder_ampdu(struct ieee80211_local *local, qc = skb->data + ieee80211_get_hdrlen(fc) - QOS_CONTROL_LEN; tid = qc[0] & QOS_CONTROL_TID_MASK; - tid_agg_rx = &(sta->ampdu_mlme.tid_rx[tid]); - if (tid_agg_rx->state != HT_AGG_STATE_OPERATIONAL) + if (sta->ampdu_mlme.tid_state_rx[tid] != HT_AGG_STATE_OPERATIONAL) goto end_reorder; + tid_agg_rx = sta->ampdu_mlme.tid_rx[tid]; + /* null data frames are excluded */ if (unlikely(fc & IEEE80211_STYPE_NULLFUNC)) goto end_reorder; |