diff options
author | Ujjal Roy <royujjal@gmail.com> | 2013-12-03 02:17:53 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2013-12-09 15:35:29 -0500 |
commit | ca8d6dfc929ad6e59eb523e7c057804b55e5673e (patch) | |
tree | 6aff0899c03f73a85ddc00caf7006544c5cde4f5 /drivers/net/wireless/mwifiex/sta_rx.c | |
parent | f8eb5ee5f56f09278b80100e65df08975867f03c (diff) |
mwifiex: fix rx_pending count imbalance
RX packets are handled in different paths. Not all paths have
decrement of rx_pending counter. This patch fixes the counter
imbalance.
Signed-off-by: Ujjal Roy <royujjal@gmail.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/mwifiex/sta_rx.c')
-rw-r--r-- | drivers/net/wireless/mwifiex/sta_rx.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/drivers/net/wireless/mwifiex/sta_rx.c b/drivers/net/wireless/mwifiex/sta_rx.c index d74192d62653..0bb510de8071 100644 --- a/drivers/net/wireless/mwifiex/sta_rx.c +++ b/drivers/net/wireless/mwifiex/sta_rx.c | |||
@@ -188,12 +188,7 @@ int mwifiex_process_sta_rx_packet(struct mwifiex_private *priv, | |||
188 | "wrong rx packet: len=%d, rx_pkt_offset=%d, rx_pkt_length=%d\n", | 188 | "wrong rx packet: len=%d, rx_pkt_offset=%d, rx_pkt_length=%d\n", |
189 | skb->len, rx_pkt_offset, rx_pkt_length); | 189 | skb->len, rx_pkt_offset, rx_pkt_length); |
190 | priv->stats.rx_dropped++; | 190 | priv->stats.rx_dropped++; |
191 | 191 | dev_kfree_skb_any(skb); | |
192 | if (adapter->if_ops.data_complete) | ||
193 | adapter->if_ops.data_complete(adapter, skb); | ||
194 | else | ||
195 | dev_kfree_skb_any(skb); | ||
196 | |||
197 | return ret; | 192 | return ret; |
198 | } | 193 | } |
199 | 194 | ||
@@ -247,12 +242,8 @@ int mwifiex_process_sta_rx_packet(struct mwifiex_private *priv, | |||
247 | ret = mwifiex_11n_rx_reorder_pkt(priv, seq_num, local_rx_pd->priority, | 242 | ret = mwifiex_11n_rx_reorder_pkt(priv, seq_num, local_rx_pd->priority, |
248 | ta, (u8) rx_pkt_type, skb); | 243 | ta, (u8) rx_pkt_type, skb); |
249 | 244 | ||
250 | if (ret || (rx_pkt_type == PKT_TYPE_BAR)) { | 245 | if (ret || (rx_pkt_type == PKT_TYPE_BAR)) |
251 | if (adapter->if_ops.data_complete) | 246 | dev_kfree_skb_any(skb); |
252 | adapter->if_ops.data_complete(adapter, skb); | ||
253 | else | ||
254 | dev_kfree_skb_any(skb); | ||
255 | } | ||
256 | 247 | ||
257 | if (ret) | 248 | if (ret) |
258 | priv->stats.rx_dropped++; | 249 | priv->stats.rx_dropped++; |