aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorAndrew Vasquez <andrew.vasquez@qlogic.com>2007-01-29 13:22:20 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-01-31 12:06:12 -0500
commitd88021a6710e6ed5d1899ba2e54d4638026e277d (patch)
tree4c251c19a0b98b616754046b9eaafa8176de1a25 /drivers/scsi
parenta8488abefaa863a0c3a19888f03395adb3f1c6d2 (diff)
[SCSI] qla2xxx: Handle IRQ-0 assignments by the system.
No restriction should be placed on the IRQ number assigned to a given ISP. Original code incorrectly assumed a non-zero IRQ number assignment by the system. In these circumstances the proper freeing of the IRQ (via free_irq()) would not take place. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/qla2xxx/qla_def.h1
-rw-r--r--drivers/scsi/qla2xxx/qla_isr.c8
2 files changed, 6 insertions, 3 deletions
diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h
index 8d7e8cb1e703..3b26f8e00ace 100644
--- a/drivers/scsi/qla2xxx/qla_def.h
+++ b/drivers/scsi/qla2xxx/qla_def.h
@@ -2097,6 +2097,7 @@ typedef struct scsi_qla_host {
2097 uint32_t enable_lip_full_login :1; 2097 uint32_t enable_lip_full_login :1;
2098 uint32_t enable_target_reset :1; 2098 uint32_t enable_target_reset :1;
2099 uint32_t enable_led_scheme :1; 2099 uint32_t enable_led_scheme :1;
2100 uint32_t inta_enabled :1;
2100 uint32_t msi_enabled :1; 2101 uint32_t msi_enabled :1;
2101 uint32_t msix_enabled :1; 2102 uint32_t msix_enabled :1;
2102 uint32_t disable_serdes :1; 2103 uint32_t disable_serdes :1;
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index e883b5fc3b08..6e19769b46d2 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -1725,12 +1725,14 @@ qla2x00_request_irqs(scsi_qla_host_t *ha)
1725skip_msix: 1725skip_msix:
1726 ret = request_irq(ha->pdev->irq, ha->isp_ops.intr_handler, 1726 ret = request_irq(ha->pdev->irq, ha->isp_ops.intr_handler,
1727 IRQF_DISABLED|IRQF_SHARED, QLA2XXX_DRIVER_NAME, ha); 1727 IRQF_DISABLED|IRQF_SHARED, QLA2XXX_DRIVER_NAME, ha);
1728 if (ret) { 1728 if (!ret) {
1729 ha->flags.inta_enabled = 1;
1730 ha->host->irq = ha->pdev->irq;
1731 } else {
1729 qla_printk(KERN_WARNING, ha, 1732 qla_printk(KERN_WARNING, ha,
1730 "Failed to reserve interrupt %d already in use.\n", 1733 "Failed to reserve interrupt %d already in use.\n",
1731 ha->pdev->irq); 1734 ha->pdev->irq);
1732 } 1735 }
1733 ha->host->irq = ha->pdev->irq;
1734 1736
1735 return ret; 1737 return ret;
1736} 1738}
@@ -1741,6 +1743,6 @@ qla2x00_free_irqs(scsi_qla_host_t *ha)
1741 1743
1742 if (ha->flags.msix_enabled) 1744 if (ha->flags.msix_enabled)
1743 qla24xx_disable_msix(ha); 1745 qla24xx_disable_msix(ha);
1744 else if (ha->host->irq) 1746 else if (ha->flags.inta_enabled)
1745 free_irq(ha->host->irq, ha); 1747 free_irq(ha->host->irq, ha);
1746} 1748}