diff options
author | Lalit Chandivade <lalit.chandivade@qlogic.com> | 2009-08-25 11:36:18 -0700 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2009-09-12 09:35:21 -0500 |
commit | d970432c48ab8dd28216e80942723aeb505b623e (patch) | |
tree | 67bfe6caa2b18fc6e7c740f0d0b0e1b634da5c02 /drivers/scsi/qla2xxx | |
parent | ab67114935d611caffe18063d1777f8c4f8b4272 (diff) | |
download | kernel_samsung_smdk4412-d970432c48ab8dd28216e80942723aeb505b623e.zip kernel_samsung_smdk4412-d970432c48ab8dd28216e80942723aeb505b623e.tar.gz kernel_samsung_smdk4412-d970432c48ab8dd28216e80942723aeb505b623e.tar.bz2 |
[SCSI] qla2xxx: Correct qla2x00_eh_wait_on_command() to wait correctly.
Original code would break-out of loop after only one iteration.
Signed-off-by: Lalit Chandivade <lalit.chandivade@qlogic.com>
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_os.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index 649fd75..ea9f917 100644 --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c @@ -568,11 +568,8 @@ qla2x00_eh_wait_on_command(struct scsi_cmnd *cmd) unsigned long wait_iter = ABORT_WAIT_ITER; int ret = QLA_SUCCESS; - while (CMD_SP(cmd)) { + while (CMD_SP(cmd) && wait_iter--) { msleep(ABORT_POLLING_PERIOD); - - if (--wait_iter) - break; } if (CMD_SP(cmd)) ret = QLA_FUNCTION_FAILED; |