diff options
author | Cathy Luo <cluo@marvell.com> | 2015-03-12 04:29:31 -0400 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2015-03-16 12:04:20 -0400 |
commit | 2c11ab90067a8bb9d7dca3e65ace950fcd9c2f1b (patch) | |
tree | 408f2a872b548f720a684766c5e3082dc8cfc604 /drivers/net/wireless/mwifiex | |
parent | 52f119ddea412af870fb84412c0f7832e85c7663 (diff) |
mwifiex: fix a bug in Rx multiport aggregation logic
It's been observed Rx aggregated packets are always followed
by a single Rx packet. This patch improves our logic to add
that extra packet in next aggregation.
Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/mwifiex')
-rw-r--r-- | drivers/net/wireless/mwifiex/sdio.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/net/wireless/mwifiex/sdio.c b/drivers/net/wireless/mwifiex/sdio.c index 57d85ab442bf..9ef010bfa7d9 100644 --- a/drivers/net/wireless/mwifiex/sdio.c +++ b/drivers/net/wireless/mwifiex/sdio.c | |||
@@ -1133,6 +1133,7 @@ static int mwifiex_sdio_card_to_host_mp_aggr(struct mwifiex_adapter *adapter, | |||
1133 | s32 f_do_rx_aggr = 0; | 1133 | s32 f_do_rx_aggr = 0; |
1134 | s32 f_do_rx_cur = 0; | 1134 | s32 f_do_rx_cur = 0; |
1135 | s32 f_aggr_cur = 0; | 1135 | s32 f_aggr_cur = 0; |
1136 | s32 f_post_aggr_cur = 0; | ||
1136 | struct sk_buff *skb_deaggr; | 1137 | struct sk_buff *skb_deaggr; |
1137 | u32 pind; | 1138 | u32 pind; |
1138 | u32 pkt_len, pkt_type, mport; | 1139 | u32 pkt_len, pkt_type, mport; |
@@ -1169,7 +1170,7 @@ static int mwifiex_sdio_card_to_host_mp_aggr(struct mwifiex_adapter *adapter, | |||
1169 | } else { | 1170 | } else { |
1170 | /* No room in Aggr buf, do rx aggr now */ | 1171 | /* No room in Aggr buf, do rx aggr now */ |
1171 | f_do_rx_aggr = 1; | 1172 | f_do_rx_aggr = 1; |
1172 | f_do_rx_cur = 1; | 1173 | f_post_aggr_cur = 1; |
1173 | } | 1174 | } |
1174 | } else { | 1175 | } else { |
1175 | /* Rx aggr not in progress */ | 1176 | /* Rx aggr not in progress */ |
@@ -1280,9 +1281,13 @@ rx_curr_single: | |||
1280 | 1281 | ||
1281 | mwifiex_decode_rx_packet(adapter, skb, pkt_type); | 1282 | mwifiex_decode_rx_packet(adapter, skb, pkt_type); |
1282 | } | 1283 | } |
1284 | if (f_post_aggr_cur) { | ||
1285 | dev_dbg(adapter->dev, "info: current packet aggregation\n"); | ||
1286 | /* Curr pkt can be aggregated */ | ||
1287 | mp_rx_aggr_setup(card, skb, port); | ||
1288 | } | ||
1283 | 1289 | ||
1284 | return 0; | 1290 | return 0; |
1285 | |||
1286 | error: | 1291 | error: |
1287 | if (MP_RX_AGGR_IN_PROGRESS(card)) { | 1292 | if (MP_RX_AGGR_IN_PROGRESS(card)) { |
1288 | /* Multiport-aggregation transfer failed - cleanup */ | 1293 | /* Multiport-aggregation transfer failed - cleanup */ |