]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drivers/scsi/ipr.c: missing unlock before a return
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 7 Sep 2012 00:17:46 +0000 (10:17 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Fri, 7 Sep 2012 05:36:02 +0000 (15:36 +1000)
We recently changed the locking in this function, but this return was
missed.  It needs an unlock and the IRQs need to be restored.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Brian King <brking@linux.vnet.ibm.com>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
drivers/scsi/ipr.c

index ac861afa1277b49832c39eab48d3d6b831f91c20..ae1296749365242ee3326bd7d5b4336315f39666 100644 (file)
@@ -5874,8 +5874,11 @@ static int ipr_queuecommand(struct Scsi_Host *shost,
                goto err_nodev;
        }
 
-       if (ipr_is_gata(res) && res->sata_port)
-               return ata_sas_queuecmd(scsi_cmd, res->sata_port->ap);
+       if (ipr_is_gata(res) && res->sata_port) {
+               rc = ata_sas_queuecmd(scsi_cmd, res->sata_port->ap);
+               spin_unlock_irqrestore(shost->host_lock, lock_flags);
+               return rc;
+       }
 
        ipr_cmd = __ipr_get_free_ipr_cmnd(ioa_cfg);
        spin_unlock_irqrestore(shost->host_lock, lock_flags);