wireless-drivers fixes for v5.12
As there was -rc8 release, one more important fix for v5.12. iwlwifi * fix spinlock warning in gen2 devices -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAABAgAGBQJgf+iBAAoJEG4XJFUm622bdssH/jut7tCetCFToxBzX/kIp/Gy OpgYD5ffSXbElnH0qzuxQ9huvqQ8joY2GJYZ3oi/id91vvluJhsYzbRQSo6ip79m P3YYqCsXHC2bxC+xCLEKe75NxTuNf5JC4B6pxITSAKywhXoGPIBalIEjU1+U4c9T +Nd65WVGlD4RmG057fNNPO9v+gPtbOup/GPXr0FENYz39Y/UCctvSUBp+Mh4Vnf6 fwERFjFg9Q7LJud/m12QalcnH9Y9cQncvjCmZhoNqixQY17Q6b9uK+IDC+Xi+b6E KXDa1C5seezWIbvU99118tIkd4osPOo9PJ7WV53LjT28sU4isnBslYekp6VjqR8= =Xs2a -----END PGP SIGNATURE----- Merge tag 'wireless-drivers-2021-04-21' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers Kalle Valo says: ==================== wireless-drivers fixes for v5.12 As there was -rc8 release, one more important fix for v5.12. iwlwifi * fix spinlock warning in gen2 devices ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
commit
542c40957c
@ -40,6 +40,7 @@ int iwl_pcie_gen2_enqueue_hcmd(struct iwl_trans *trans,
|
||||
const u8 *cmddata[IWL_MAX_CMD_TBS_PER_TFD];
|
||||
u16 cmdlen[IWL_MAX_CMD_TBS_PER_TFD];
|
||||
struct iwl_tfh_tfd *tfd;
|
||||
unsigned long flags;
|
||||
|
||||
copy_size = sizeof(struct iwl_cmd_header_wide);
|
||||
cmd_size = sizeof(struct iwl_cmd_header_wide);
|
||||
@ -108,14 +109,14 @@ int iwl_pcie_gen2_enqueue_hcmd(struct iwl_trans *trans,
|
||||
goto free_dup_buf;
|
||||
}
|
||||
|
||||
spin_lock_bh(&txq->lock);
|
||||
spin_lock_irqsave(&txq->lock, flags);
|
||||
|
||||
idx = iwl_txq_get_cmd_index(txq, txq->write_ptr);
|
||||
tfd = iwl_txq_get_tfd(trans, txq, txq->write_ptr);
|
||||
memset(tfd, 0, sizeof(*tfd));
|
||||
|
||||
if (iwl_txq_space(trans, txq) < ((cmd->flags & CMD_ASYNC) ? 2 : 1)) {
|
||||
spin_unlock_bh(&txq->lock);
|
||||
spin_unlock_irqrestore(&txq->lock, flags);
|
||||
|
||||
IWL_ERR(trans, "No space in command queue\n");
|
||||
iwl_op_mode_cmd_queue_full(trans->op_mode);
|
||||
@ -250,7 +251,7 @@ int iwl_pcie_gen2_enqueue_hcmd(struct iwl_trans *trans,
|
||||
spin_unlock(&trans_pcie->reg_lock);
|
||||
|
||||
out:
|
||||
spin_unlock_bh(&txq->lock);
|
||||
spin_unlock_irqrestore(&txq->lock, flags);
|
||||
free_dup_buf:
|
||||
if (idx < 0)
|
||||
kfree(dup_buf);
|
||||
|
Loading…
x
Reference in New Issue
Block a user