Hi James,
After further review of this patch please do not include it for 3.12-rc.

Thanks,
~Saurav

>From: Chad Dupuis <[email protected]>
>
>If the call to abort a request fails we need to clear it's entry in the
>in-flight
>commands array as it won't be cleared in interrupt context.  Not doing so
>could
>potentially lead to a double completion.
>
>Signed-off-by: Chad Dupuis <[email protected]>
>Signed-off-by: Saurav Kashyap <[email protected]>
>---
> drivers/scsi/qla2xxx/qla_os.c |    8 ++++++++
> 1 files changed, 8 insertions(+), 0 deletions(-)
>
>diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
>index 9f01bbb..66ed1c9 100644
>--- a/drivers/scsi/qla2xxx/qla_os.c
>+++ b/drivers/scsi/qla2xxx/qla_os.c
>@@ -951,6 +951,7 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
>       unsigned long flags;
>       int wait = 0;
>       struct qla_hw_data *ha = vha->hw;
>+      uint32_t handle = 0;
> 
>       if (!CMD_SP(cmd))
>               return SUCCESS;
>@@ -989,7 +990,14 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
>       }
> 
>       spin_lock_irqsave(&ha->hardware_lock, flags);
>+      handle = sp->handle;
>       sp->done(ha, sp, 0);
>+      /*
>+       * If the mailbox command failed, clear the entry in the in-flight
>+       * commands array as the entry won't be cleared in interrupt context.
>+       */
>+      if (ret == FAILED)
>+              vha->req->outstanding_cmds[handle] = NULL;
>       spin_unlock_irqrestore(&ha->hardware_lock, flags);
> 
>       /* Did the command return during mailbox execution? */
>-- 
>1.7.7
>

<<attachment: winmail.dat>>

Reply via email to