* [PATCH] scsi: elx: libefc: fix IRQ restore in efc_domain_dispatch_frame()
@ 2021-06-18 13:43 Dan Carpenter
2021-06-19 2:44 ` Martin K. Petersen
2021-06-19 15:44 ` James Smart
0 siblings, 2 replies; 3+ messages in thread
From: Dan Carpenter @ 2021-06-18 13:43 UTC (permalink / raw)
To: James Smart
Cc: Ram Vegesna, James E.J. Bottomley, Martin K. Petersen,
Daniel Wagner, Hannes Reinecke, linux-scsi, target-devel,
kernel-janitors
Calling a nested spin_lock_irqsave() will overwrite the original "flags"
so that they can not be enabled again at the end.
Fixes: 3146240f19bf ("scsi: elx: libefc: FC Domain state machine interfaces")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
drivers/scsi/elx/libefc/efc_domain.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/elx/libefc/efc_domain.c b/drivers/scsi/elx/libefc/efc_domain.c
index 0c08fa2066b9..ca9d7ff2c0d2 100644
--- a/drivers/scsi/elx/libefc/efc_domain.c
+++ b/drivers/scsi/elx/libefc/efc_domain.c
@@ -1001,10 +1001,10 @@ efc_domain_dispatch_frame(void *arg, struct efc_hw_sequence *seq)
if (node->hold_frames || !list_empty(&node->pend_frames)) {
/* add frame to node's pending list */
- spin_lock_irqsave(&node->pend_frames_lock, flags);
+ spin_lock(&node->pend_frames_lock);
INIT_LIST_HEAD(&seq->list_entry);
list_add_tail(&seq->list_entry, &node->pend_frames);
- spin_unlock_irqrestore(&node->pend_frames_lock, flags);
+ spin_unlock(&node->pend_frames_lock);
rc = EFC_HW_SEQ_HOLD;
goto out_release;
}
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] scsi: elx: libefc: fix IRQ restore in efc_domain_dispatch_frame()
2021-06-18 13:43 [PATCH] scsi: elx: libefc: fix IRQ restore in efc_domain_dispatch_frame() Dan Carpenter
@ 2021-06-19 2:44 ` Martin K. Petersen
2021-06-19 15:44 ` James Smart
1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2021-06-19 2:44 UTC (permalink / raw)
To: Dan Carpenter
Cc: James Smart, Ram Vegesna, James E.J. Bottomley,
Martin K. Petersen, Daniel Wagner, Hannes Reinecke, linux-scsi,
target-devel, kernel-janitors
Dan,
> Calling a nested spin_lock_irqsave() will overwrite the original
> "flags" so that they can not be enabled again at the end.
Applied to 5.14/scsi-staging, thanks!
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] scsi: elx: libefc: fix IRQ restore in efc_domain_dispatch_frame()
2021-06-18 13:43 [PATCH] scsi: elx: libefc: fix IRQ restore in efc_domain_dispatch_frame() Dan Carpenter
2021-06-19 2:44 ` Martin K. Petersen
@ 2021-06-19 15:44 ` James Smart
1 sibling, 0 replies; 3+ messages in thread
From: James Smart @ 2021-06-19 15:44 UTC (permalink / raw)
To: Dan Carpenter, James Smart
Cc: Ram Vegesna, James E.J. Bottomley, Martin K. Petersen,
Daniel Wagner, Hannes Reinecke, linux-scsi, target-devel,
kernel-janitors
On 6/18/2021 6:43 AM, Dan Carpenter wrote:
> Calling a nested spin_lock_irqsave() will overwrite the original "flags"
> so that they can not be enabled again at the end.
>
> Fixes: 3146240f19bf ("scsi: elx: libefc: FC Domain state machine interfaces")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> ---
> drivers/scsi/elx/libefc/efc_domain.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Thanks!
Reviewed-by: James Smart <jsmart2021@gmail.com>
-- james
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-06-19 15:45 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-18 13:43 [PATCH] scsi: elx: libefc: fix IRQ restore in efc_domain_dispatch_frame() Dan Carpenter
2021-06-19 2:44 ` Martin K. Petersen
2021-06-19 15:44 ` James Smart
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).