[SCSI] qla2xxx: Query supported RISC registers bits in determining a paused-state.
authorAndrew Vasquez <andrew.vasquez@qlogic.com>
Wed, 3 Jun 2009 16:55:26 +0000 (09:55 -0700)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Mon, 8 Jun 2009 19:46:54 +0000 (14:46 -0500)
ISP24xx and above must query the host-status register, not HCCR.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/scsi/qla2xxx/qla_dbg.c
drivers/scsi/qla2xxx/qla_fw.h

index 68671a2b8b7f2c21eb1a5a8a201bc557498960ed..4a990f4da4ea95254fda1e6c233e202e86ad6cea 100644 (file)
@@ -149,11 +149,9 @@ qla24xx_pause_risc(struct device_reg_24xx __iomem *reg)
        int rval = QLA_SUCCESS;
        uint32_t cnt;
 
-       if (RD_REG_DWORD(&reg->hccr) & HCCRX_RISC_PAUSE)
-               return rval;
-
        WRT_REG_DWORD(&reg->hccr, HCCRX_SET_RISC_PAUSE);
-       for (cnt = 30000; (RD_REG_DWORD(&reg->hccr) & HCCRX_RISC_PAUSE) == 0 &&
+       for (cnt = 30000;
+           ((RD_REG_DWORD(&reg->host_status) & HSRX_RISC_PAUSED) == 0) &&
            rval == QLA_SUCCESS; cnt--) {
                if (cnt)
                        udelay(100);
index 9e56d4a4cb7525d8812b46e2fe32080c1a0d4457..dfde2dd865cbfea7008c9f104fc9c69873e24e20 100644 (file)
@@ -878,7 +878,6 @@ struct device_reg_24xx {
                                        /* HCCR statuses. */
 #define HCCRX_HOST_INT         BIT_6   /* Host to RISC interrupt bit. */
 #define HCCRX_RISC_RESET       BIT_5   /* RISC Reset mode bit. */
-#define HCCRX_RISC_PAUSE       BIT_4   /* RISC Pause mode bit. */
                                        /* HCCR commands. */
                                        /* NOOP. */
 #define HCCRX_NOOP             0x00000000