aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla2xxx
diff options
context:
space:
mode:
authorJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-06-10 14:47:26 -0400
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-06-10 14:47:26 -0400
commitf0cd91a68acdc9b49d7f6738b514a426da627649 (patch)
tree8ad73564015794197583b094217ae0a71e71e753 /drivers/scsi/qla2xxx
parent60eef25701d25e99c991dd0f4a9f3832a0c3ad3e (diff)
parent128e6ced247cda88f96fa9f2e4ba8b2c4a681560 (diff)
Merge ../linux-2.6
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r--drivers/scsi/qla2xxx/qla_os.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 1052528c3109..ccaad0b08d35 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -589,6 +589,7 @@ qla2x00_wait_for_loop_ready(scsi_qla_host_t *ha)
589* Either SUCCESS or FAILED. 589* Either SUCCESS or FAILED.
590* 590*
591* Note: 591* Note:
592* Only return FAILED if command not returned by firmware.
592**************************************************************************/ 593**************************************************************************/
593int 594int
594qla2xxx_eh_abort(struct scsi_cmnd *cmd) 595qla2xxx_eh_abort(struct scsi_cmnd *cmd)
@@ -599,11 +600,12 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
599 unsigned int id, lun; 600 unsigned int id, lun;
600 unsigned long serial; 601 unsigned long serial;
601 unsigned long flags; 602 unsigned long flags;
603 int wait = 0;
602 604
603 if (!CMD_SP(cmd)) 605 if (!CMD_SP(cmd))
604 return FAILED; 606 return SUCCESS;
605 607
606 ret = FAILED; 608 ret = SUCCESS;
607 609
608 id = cmd->device->id; 610 id = cmd->device->id;
609 lun = cmd->device->lun; 611 lun = cmd->device->lun;
@@ -631,7 +633,7 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
631 } else { 633 } else {
632 DEBUG3(printk("%s(%ld): abort_command " 634 DEBUG3(printk("%s(%ld): abort_command "
633 "mbx success.\n", __func__, ha->host_no)); 635 "mbx success.\n", __func__, ha->host_no));
634 ret = SUCCESS; 636 wait = 1;
635 } 637 }
636 spin_lock_irqsave(&ha->hardware_lock, flags); 638 spin_lock_irqsave(&ha->hardware_lock, flags);
637 639
@@ -640,17 +642,18 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
640 spin_unlock_irqrestore(&ha->hardware_lock, flags); 642 spin_unlock_irqrestore(&ha->hardware_lock, flags);
641 643
642 /* Wait for the command to be returned. */ 644 /* Wait for the command to be returned. */
643 if (ret == SUCCESS) { 645 if (wait) {
644 if (qla2x00_eh_wait_on_command(ha, cmd) != QLA_SUCCESS) { 646 if (qla2x00_eh_wait_on_command(ha, cmd) != QLA_SUCCESS) {
645 qla_printk(KERN_ERR, ha, 647 qla_printk(KERN_ERR, ha,
646 "scsi(%ld:%d:%d): Abort handler timed out -- %lx " 648 "scsi(%ld:%d:%d): Abort handler timed out -- %lx "
647 "%x.\n", ha->host_no, id, lun, serial, ret); 649 "%x.\n", ha->host_no, id, lun, serial, ret);
650 ret = FAILED;
648 } 651 }
649 } 652 }
650 653
651 qla_printk(KERN_INFO, ha, 654 qla_printk(KERN_INFO, ha,
652 "scsi(%ld:%d:%d): Abort command issued -- %lx %x.\n", ha->host_no, 655 "scsi(%ld:%d:%d): Abort command issued -- %d %lx %x.\n",
653 id, lun, serial, ret); 656 ha->host_no, id, lun, wait, serial, ret);
654 657
655 return ret; 658 return ret;
656} 659}
@@ -1687,8 +1690,8 @@ qla2x00_free_device(scsi_qla_host_t *ha)
1687 ha->flags.online = 0; 1690 ha->flags.online = 0;
1688 1691
1689 /* Detach interrupts */ 1692 /* Detach interrupts */
1690 if (ha->pdev->irq) 1693 if (ha->host->irq)
1691 free_irq(ha->pdev->irq, ha); 1694 free_irq(ha->host->irq, ha);
1692 1695
1693 /* release io space registers */ 1696 /* release io space registers */
1694 if (ha->iobase) 1697 if (ha->iobase)