From: Dan Carpenter Date: Thu, 30 May 2013 07:50:46 +0000 (+0300) Subject: [SCSI] fnic: potential dead lock in fnic_is_abts_pending() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5d65f91896197bd047f97ed8e7792b06de491eac;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [SCSI] fnic: potential dead lock in fnic_is_abts_pending() There is an unlock missing if the == FNIC_IOREQ_ABTS_PENDING is false. Signed-off-by: Dan Carpenter Acked-by: Hiral Patel Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/fnic/fnic_scsi.c b/drivers/scsi/fnic/fnic_scsi.c index be99e7549d89..a97e6e584f8c 100644 --- a/drivers/scsi/fnic/fnic_scsi.c +++ b/drivers/scsi/fnic/fnic_scsi.c @@ -2432,11 +2432,9 @@ int fnic_is_abts_pending(struct fnic *fnic, struct scsi_cmnd *lr_sc) "Found IO in %s on lun\n", fnic_ioreq_state_to_str(CMD_STATE(sc))); - if (CMD_STATE(sc) == FNIC_IOREQ_ABTS_PENDING) { - spin_unlock_irqrestore(io_lock, flags); + if (CMD_STATE(sc) == FNIC_IOREQ_ABTS_PENDING) ret = 1; - continue; - } + spin_unlock_irqrestore(io_lock, flags); } return ret;