| .. | .. |
|---|
| 1 | 1 | /* |
|---|
| 2 | | - * Marvell Wireless LAN device driver: 802.11n Aggregation |
|---|
| 2 | + * NXP Wireless LAN device driver: 802.11n Aggregation |
|---|
| 3 | 3 | * |
|---|
| 4 | | - * Copyright (C) 2011-2014, Marvell International Ltd. |
|---|
| 4 | + * Copyright 2011-2020 NXP |
|---|
| 5 | 5 | * |
|---|
| 6 | | - * This software file (the "File") is distributed by Marvell International |
|---|
| 7 | | - * Ltd. under the terms of the GNU General Public License Version 2, June 1991 |
|---|
| 6 | + * This software file (the "File") is distributed by NXP |
|---|
| 7 | + * under the terms of the GNU General Public License Version 2, June 1991 |
|---|
| 8 | 8 | * (the "License"). You may use, redistribute and/or modify this File in |
|---|
| 9 | 9 | * accordance with the terms and conditions of the License, a copy of which |
|---|
| 10 | 10 | * is available by writing to the Free Software Foundation, Inc., |
|---|
| .. | .. |
|---|
| 155 | 155 | int |
|---|
| 156 | 156 | mwifiex_11n_aggregate_pkt(struct mwifiex_private *priv, |
|---|
| 157 | 157 | struct mwifiex_ra_list_tbl *pra_list, |
|---|
| 158 | | - int ptrindex, unsigned long ra_list_flags) |
|---|
| 158 | + int ptrindex) |
|---|
| 159 | 159 | __releases(&priv->wmm.ra_list_spinlock) |
|---|
| 160 | 160 | { |
|---|
| 161 | 161 | struct mwifiex_adapter *adapter = priv->adapter; |
|---|
| .. | .. |
|---|
| 168 | 168 | |
|---|
| 169 | 169 | skb_src = skb_peek(&pra_list->skb_head); |
|---|
| 170 | 170 | if (!skb_src) { |
|---|
| 171 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, |
|---|
| 172 | | - ra_list_flags); |
|---|
| 171 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 173 | 172 | return 0; |
|---|
| 174 | 173 | } |
|---|
| 175 | 174 | |
|---|
| .. | .. |
|---|
| 177 | 176 | skb_aggr = mwifiex_alloc_dma_align_buf(adapter->tx_buf_size, |
|---|
| 178 | 177 | GFP_ATOMIC); |
|---|
| 179 | 178 | if (!skb_aggr) { |
|---|
| 180 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, |
|---|
| 181 | | - ra_list_flags); |
|---|
| 179 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 182 | 180 | return -1; |
|---|
| 183 | 181 | } |
|---|
| 184 | 182 | |
|---|
| .. | .. |
|---|
| 208 | 206 | pra_list->total_pkt_count--; |
|---|
| 209 | 207 | atomic_dec(&priv->wmm.tx_pkts_queued); |
|---|
| 210 | 208 | aggr_num++; |
|---|
| 211 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, |
|---|
| 212 | | - ra_list_flags); |
|---|
| 209 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 213 | 210 | mwifiex_11n_form_amsdu_pkt(skb_aggr, skb_src, &pad); |
|---|
| 214 | 211 | |
|---|
| 215 | 212 | mwifiex_write_data_complete(adapter, skb_src, 0, 0); |
|---|
| 216 | 213 | |
|---|
| 217 | | - spin_lock_irqsave(&priv->wmm.ra_list_spinlock, ra_list_flags); |
|---|
| 214 | + spin_lock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 218 | 215 | |
|---|
| 219 | 216 | if (!mwifiex_is_ralist_valid(priv, pra_list, ptrindex)) { |
|---|
| 220 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, |
|---|
| 221 | | - ra_list_flags); |
|---|
| 217 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 222 | 218 | return -1; |
|---|
| 223 | 219 | } |
|---|
| 224 | 220 | |
|---|
| .. | .. |
|---|
| 232 | 228 | |
|---|
| 233 | 229 | } while (skb_src); |
|---|
| 234 | 230 | |
|---|
| 235 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, ra_list_flags); |
|---|
| 231 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 236 | 232 | |
|---|
| 237 | 233 | /* Last AMSDU packet does not need padding */ |
|---|
| 238 | 234 | skb_trim(skb_aggr, skb_aggr->len - pad); |
|---|
| .. | .. |
|---|
| 265 | 261 | } |
|---|
| 266 | 262 | switch (ret) { |
|---|
| 267 | 263 | case -EBUSY: |
|---|
| 268 | | - spin_lock_irqsave(&priv->wmm.ra_list_spinlock, ra_list_flags); |
|---|
| 264 | + spin_lock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 269 | 265 | if (!mwifiex_is_ralist_valid(priv, pra_list, ptrindex)) { |
|---|
| 270 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, |
|---|
| 271 | | - ra_list_flags); |
|---|
| 266 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 272 | 267 | mwifiex_write_data_complete(adapter, skb_aggr, 1, -1); |
|---|
| 273 | 268 | return -1; |
|---|
| 274 | 269 | } |
|---|
| .. | .. |
|---|
| 286 | 281 | atomic_inc(&priv->wmm.tx_pkts_queued); |
|---|
| 287 | 282 | |
|---|
| 288 | 283 | tx_info_aggr->flags |= MWIFIEX_BUF_FLAG_REQUEUED_PKT; |
|---|
| 289 | | - spin_unlock_irqrestore(&priv->wmm.ra_list_spinlock, |
|---|
| 290 | | - ra_list_flags); |
|---|
| 284 | + spin_unlock_bh(&priv->wmm.ra_list_spinlock); |
|---|
| 291 | 285 | mwifiex_dbg(adapter, ERROR, "data: -EBUSY is returned\n"); |
|---|
| 292 | 286 | break; |
|---|
| 293 | 287 | case -1: |
|---|