Skip to content

Commit

Permalink
[SCSI] qla2xxx: Don't fallback to interrupt-polling during re-initial…
Browse files Browse the repository at this point in the history
…ization with MSI-X enabled.

ROMs in recent ISPs have MSI-X support, so it's no longer
necessary for the driver to fallback to interrupt polling during
ISP re-initialization.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
  • Loading branch information
Andrew Vasquez authored and James Bottomley committed Jan 7, 2009
1 parent 1ded85e commit 124f85e
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
2 changes: 2 additions & 0 deletions drivers/scsi/qla2xxx/qla_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -2370,6 +2370,8 @@ struct qla_hw_data {
IS_QLA84XX(ha))
#define IS_QLA2XXX_MIDTYPE(ha) (IS_QLA24XX(ha) || IS_QLA84XX(ha) || \
IS_QLA25XX(ha))
#define IS_NOPOLLING_TYPE(ha) (IS_QLA25XX(ha) && \
(ha)->flags.msix_enabled)

#define IS_IIDMA_CAPABLE(ha) ((ha)->device_type & DT_IIDMA)
#define IS_FWI2_CAPABLE(ha) ((ha)->device_type & DT_FWI2)
Expand Down
3 changes: 3 additions & 0 deletions drivers/scsi/qla2xxx/qla_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -570,6 +570,9 @@ qla24xx_reset_risc(scsi_qla_host_t *vha)
}

spin_unlock_irqrestore(&ha->hardware_lock, flags);

if (IS_NOPOLLING_TYPE(ha))
ha->isp_ops->enable_intrs(ha);
}

/**
Expand Down
5 changes: 2 additions & 3 deletions drivers/scsi/qla2xxx/qla_mbx.c
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,7 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)

/* Wait for mbx cmd completion until timeout */

if (!abort_active && io_lock_on) {

if ((!abort_active && io_lock_on) || IS_NOPOLLING_TYPE(ha)) {
set_bit(MBX_INTR_WAIT, &ha->mbx_cmd_flags);

if (IS_FWI2_CAPABLE(ha))
Expand Down Expand Up @@ -218,7 +217,7 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)
/* Clean up */
ha->mcp = NULL;

if (abort_active || !io_lock_on) {
if ((abort_active || !io_lock_on) && !IS_NOPOLLING_TYPE(ha)) {
DEBUG11(printk("%s(%ld): checking for additional resp "
"interrupt.\n", __func__, base_vha->host_no));

Expand Down
2 changes: 2 additions & 0 deletions drivers/scsi/qla2xxx/qla_os.c
Original file line number Diff line number Diff line change
Expand Up @@ -1329,6 +1329,8 @@ qla24xx_disable_intrs(struct qla_hw_data *ha)
unsigned long flags = 0;
struct device_reg_24xx __iomem *reg = &ha->iobase->isp24;

if (IS_NOPOLLING_TYPE(ha))
return;
spin_lock_irqsave(&ha->hardware_lock, flags);
ha->interrupts_on = 0;
WRT_REG_DWORD(&reg->ictrl, 0);
Expand Down

0 comments on commit 124f85e

Please sign in to comment.