Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=63e4563b9cf77875286312758f61a20f912afbbb
Commit:     63e4563b9cf77875286312758f61a20f912afbbb
Parent:     91b550604480eadcdadc7db8a7d19f496ccad6bd
Author:     James Bottomley <[EMAIL PROTECTED]>
AuthorDate: Fri Feb 22 17:07:52 2008 -0600
Committer:  James Bottomley <[EMAIL PROTECTED]>
CommitDate: Fri Feb 22 17:23:47 2008 -0600

    [SCSI] libsas: correctly flush the LU queue on error recovery
    
    The current sas_scsi_clear_queue_lu() is wrongly checking for commands
    which match the pointer to the one passed in.  It should be checking for
    commands which are on the same logical unit as the one passed in.  Fix
    this by checking target pointer and LUN for equality.
    
    Signed-off-by: James Bottomley <[EMAIL PROTECTED]>
---
 drivers/scsi/libsas/sas_scsi_host.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/libsas/sas_scsi_host.c 
b/drivers/scsi/libsas/sas_scsi_host.c
index 9c96d1b..704ea06 100644
--- a/drivers/scsi/libsas/sas_scsi_host.c
+++ b/drivers/scsi/libsas/sas_scsi_host.c
@@ -280,7 +280,8 @@ static void sas_scsi_clear_queue_lu(struct list_head 
*error_q, struct scsi_cmnd
        struct scsi_cmnd *cmd, *n;
 
        list_for_each_entry_safe(cmd, n, error_q, eh_entry) {
-               if (cmd == my_cmd)
+               if (cmd->device->sdev_target == my_cmd->device->sdev_target &&
+                   cmd->device->lun == my_cmd->device->lun)
                        sas_eh_finish_cmd(cmd);
        }
 }
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to