diff options
Diffstat (limited to 'drivers/net/wireless/mwifiex/sdio.c')
-rw-r--r-- | drivers/net/wireless/mwifiex/sdio.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/net/wireless/mwifiex/sdio.c b/drivers/net/wireless/mwifiex/sdio.c index bdab122db5cf..ea8fc587e90f 100644 --- a/drivers/net/wireless/mwifiex/sdio.c +++ b/drivers/net/wireless/mwifiex/sdio.c | |||
@@ -1039,6 +1039,7 @@ static int mwifiex_decode_rx_packet(struct mwifiex_adapter *adapter, | |||
1039 | struct sk_buff *skb, u32 upld_typ) | 1039 | struct sk_buff *skb, u32 upld_typ) |
1040 | { | 1040 | { |
1041 | u8 *cmd_buf; | 1041 | u8 *cmd_buf; |
1042 | unsigned long flags; | ||
1042 | __le16 *curr_ptr = (__le16 *)skb->data; | 1043 | __le16 *curr_ptr = (__le16 *)skb->data; |
1043 | u16 pkt_len = le16_to_cpu(*curr_ptr); | 1044 | u16 pkt_len = le16_to_cpu(*curr_ptr); |
1044 | 1045 | ||
@@ -1048,7 +1049,15 @@ static int mwifiex_decode_rx_packet(struct mwifiex_adapter *adapter, | |||
1048 | switch (upld_typ) { | 1049 | switch (upld_typ) { |
1049 | case MWIFIEX_TYPE_DATA: | 1050 | case MWIFIEX_TYPE_DATA: |
1050 | dev_dbg(adapter->dev, "info: --- Rx: Data packet ---\n"); | 1051 | dev_dbg(adapter->dev, "info: --- Rx: Data packet ---\n"); |
1051 | mwifiex_handle_rx_packet(adapter, skb); | 1052 | if (adapter->rx_work_enabled) { |
1053 | spin_lock_irqsave(&adapter->rx_q_lock, flags); | ||
1054 | skb_queue_tail(&adapter->rx_data_q, skb); | ||
1055 | spin_unlock_irqrestore(&adapter->rx_q_lock, flags); | ||
1056 | adapter->data_received = true; | ||
1057 | atomic_inc(&adapter->rx_pending); | ||
1058 | } else { | ||
1059 | mwifiex_handle_rx_packet(adapter, skb); | ||
1060 | } | ||
1052 | break; | 1061 | break; |
1053 | 1062 | ||
1054 | case MWIFIEX_TYPE_CMD: | 1063 | case MWIFIEX_TYPE_CMD: |