aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla2xxx
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2010-05-17 19:30:58 -0400
committerDan Williams <dan.j.williams@intel.com>2010-05-17 19:30:58 -0400
commit0b28330e39bbe0ffee4c56b09fc415fcec595ea3 (patch)
treefcf504879883763557e696eff81427b1ab78f76b /drivers/scsi/qla2xxx
parent058276303dbc4ed089c1f7dad0871810b1f5ddf1 (diff)
parentcaa20d974c86af496b419eef70010e63b7fab7ac (diff)
Merge branch 'ioat' into dmaengine
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r--drivers/scsi/qla2xxx/qla_attr.c7
-rw-r--r--drivers/scsi/qla2xxx/qla_fw.h18
-rw-r--r--drivers/scsi/qla2xxx/qla_init.c1
-rw-r--r--drivers/scsi/qla2xxx/qla_isr.c38
-rw-r--r--drivers/scsi/qla2xxx/qla_mbx.c9
-rw-r--r--drivers/scsi/qla2xxx/qla_mid.c1
-rw-r--r--drivers/scsi/qla2xxx/qla_os.c5
-rw-r--r--drivers/scsi/qla2xxx/qla_sup.c1
-rw-r--r--drivers/scsi/qla2xxx/qla_version.h4
9 files changed, 56 insertions, 28 deletions
diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
index 90d1e062ec4f..359e9a71a021 100644
--- a/drivers/scsi/qla2xxx/qla_attr.c
+++ b/drivers/scsi/qla2xxx/qla_attr.c
@@ -8,6 +8,7 @@
8 8
9#include <linux/kthread.h> 9#include <linux/kthread.h>
10#include <linux/vmalloc.h> 10#include <linux/vmalloc.h>
11#include <linux/slab.h>
11#include <linux/delay.h> 12#include <linux/delay.h>
12 13
13static int qla24xx_vport_disable(struct fc_vport *, bool); 14static int qla24xx_vport_disable(struct fc_vport *, bool);
@@ -1274,7 +1275,11 @@ qla2x00_fw_state_show(struct device *dev, struct device_attribute *attr,
1274 int rval = QLA_FUNCTION_FAILED; 1275 int rval = QLA_FUNCTION_FAILED;
1275 uint16_t state[5]; 1276 uint16_t state[5];
1276 1277
1277 if (!vha->hw->flags.eeh_busy) 1278 if (test_bit(ABORT_ISP_ACTIVE, &vha->dpc_flags) ||
1279 test_bit(ISP_ABORT_NEEDED, &vha->dpc_flags))
1280 DEBUG2_3_11(printk("%s(%ld): isp reset in progress.\n",
1281 __func__, vha->host_no));
1282 else if (!vha->hw->flags.eeh_busy)
1278 rval = qla2x00_get_firmware_state(vha, state); 1283 rval = qla2x00_get_firmware_state(vha, state);
1279 if (rval != QLA_SUCCESS) 1284 if (rval != QLA_SUCCESS)
1280 memset(state, -1, sizeof(state)); 1285 memset(state, -1, sizeof(state));
diff --git a/drivers/scsi/qla2xxx/qla_fw.h b/drivers/scsi/qla2xxx/qla_fw.h
index cebf4f1bb7d9..42c5587cc50c 100644
--- a/drivers/scsi/qla2xxx/qla_fw.h
+++ b/drivers/scsi/qla2xxx/qla_fw.h
@@ -1592,10 +1592,22 @@ struct nvram_81xx {
1592 1592
1593 /* Offset 384. */ 1593 /* Offset 384. */
1594 uint8_t reserved_21[16]; 1594 uint8_t reserved_21[16];
1595 uint16_t reserved_22[8]; 1595 uint16_t reserved_22[3];
1596
1597 /*
1598 * BIT 0 = Extended BB credits for LR
1599 * BIT 1 = Virtual Fabric Enable
1600 * BIT 2 = Enhanced Features Unused
1601 * BIT 3-7 = Enhanced Features Reserved
1602 */
1603 /* Enhanced Features */
1604 uint8_t enhanced_features;
1605
1606 uint8_t reserved_23;
1607 uint16_t reserved_24[4];
1596 1608
1597 /* Offset 416. */ 1609 /* Offset 416. */
1598 uint16_t reserved_23[32]; 1610 uint16_t reserved_25[32];
1599 1611
1600 /* Offset 480. */ 1612 /* Offset 480. */
1601 uint8_t model_name[16]; 1613 uint8_t model_name[16];
@@ -1603,7 +1615,7 @@ struct nvram_81xx {
1603 /* Offset 496. */ 1615 /* Offset 496. */
1604 uint16_t feature_mask_l; 1616 uint16_t feature_mask_l;
1605 uint16_t feature_mask_h; 1617 uint16_t feature_mask_h;
1606 uint16_t reserved_24[2]; 1618 uint16_t reserved_26[2];
1607 1619
1608 uint16_t subsystem_vendor_id; 1620 uint16_t subsystem_vendor_id;
1609 uint16_t subsystem_device_id; 1621 uint16_t subsystem_device_id;
diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c
index a67b2bafb882..4229bb483c5e 100644
--- a/drivers/scsi/qla2xxx/qla_init.c
+++ b/drivers/scsi/qla2xxx/qla_init.c
@@ -8,6 +8,7 @@
8#include "qla_gbl.h" 8#include "qla_gbl.h"
9 9
10#include <linux/delay.h> 10#include <linux/delay.h>
11#include <linux/slab.h>
11#include <linux/vmalloc.h> 12#include <linux/vmalloc.h>
12 13
13#include "qla_devtbl.h" 14#include "qla_devtbl.h"
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index ab90329ff2e4..db539b0c3dae 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -7,6 +7,7 @@
7#include "qla_def.h" 7#include "qla_def.h"
8 8
9#include <linux/delay.h> 9#include <linux/delay.h>
10#include <linux/slab.h>
10#include <scsi/scsi_tcq.h> 11#include <scsi/scsi_tcq.h>
11#include <scsi/scsi_bsg_fc.h> 12#include <scsi/scsi_bsg_fc.h>
12 13
@@ -620,11 +621,10 @@ skip_rio:
620 * vp_idx does not match 621 * vp_idx does not match
621 * Event is not global, vp_idx does not match 622 * Event is not global, vp_idx does not match
622 */ 623 */
623 if ((mb[1] == 0xffff && (mb[3] & 0xff) != 0xff) 624 if (IS_QLA2XXX_MIDTYPE(ha) &&
624 || (mb[1] != 0xffff)) { 625 ((mb[1] == 0xffff && (mb[3] & 0xff) != 0xff) ||
625 if (vha->vp_idx != (mb[3] & 0xff)) 626 (mb[1] != 0xffff)) && vha->vp_idx != (mb[3] & 0xff))
626 break; 627 break;
627 }
628 628
629 /* Global event -- port logout or port unavailable. */ 629 /* Global event -- port logout or port unavailable. */
630 if (mb[1] == 0xffff && mb[2] == 0x7) { 630 if (mb[1] == 0xffff && mb[2] == 0x7) {
@@ -2272,30 +2272,28 @@ qla2x00_request_irqs(struct qla_hw_data *ha, struct rsp_que *rsp)
2272 2272
2273 /* If possible, enable MSI-X. */ 2273 /* If possible, enable MSI-X. */
2274 if (!IS_QLA2432(ha) && !IS_QLA2532(ha) && 2274 if (!IS_QLA2432(ha) && !IS_QLA2532(ha) &&
2275 !IS_QLA8432(ha) && !IS_QLA8001(ha)) 2275 !IS_QLA8432(ha) && !IS_QLA8001(ha))
2276 goto skip_msix; 2276 goto skip_msi;
2277
2278 if (ha->pdev->subsystem_vendor == PCI_VENDOR_ID_HP &&
2279 (ha->pdev->subsystem_device == 0x7040 ||
2280 ha->pdev->subsystem_device == 0x7041 ||
2281 ha->pdev->subsystem_device == 0x1705)) {
2282 DEBUG2(qla_printk(KERN_WARNING, ha,
2283 "MSI-X: Unsupported ISP2432 SSVID/SSDID (0x%X,0x%X).\n",
2284 ha->pdev->subsystem_vendor,
2285 ha->pdev->subsystem_device));
2286 goto skip_msi;
2287 }
2277 2288
2278 if (IS_QLA2432(ha) && (ha->pdev->revision < QLA_MSIX_CHIP_REV_24XX || 2289 if (IS_QLA2432(ha) && (ha->pdev->revision < QLA_MSIX_CHIP_REV_24XX ||
2279 !QLA_MSIX_FW_MODE_1(ha->fw_attributes))) { 2290 !QLA_MSIX_FW_MODE_1(ha->fw_attributes))) {
2280 DEBUG2(qla_printk(KERN_WARNING, ha, 2291 DEBUG2(qla_printk(KERN_WARNING, ha,
2281 "MSI-X: Unsupported ISP2432 (0x%X, 0x%X).\n", 2292 "MSI-X: Unsupported ISP2432 (0x%X, 0x%X).\n",
2282 ha->pdev->revision, ha->fw_attributes)); 2293 ha->pdev->revision, ha->fw_attributes));
2283
2284 goto skip_msix; 2294 goto skip_msix;
2285 } 2295 }
2286 2296
2287 if (ha->pdev->subsystem_vendor == PCI_VENDOR_ID_HP &&
2288 (ha->pdev->subsystem_device == 0x7040 ||
2289 ha->pdev->subsystem_device == 0x7041 ||
2290 ha->pdev->subsystem_device == 0x1705)) {
2291 DEBUG2(qla_printk(KERN_WARNING, ha,
2292 "MSI-X: Unsupported ISP2432 SSVID/SSDID (0x%X, 0x%X).\n",
2293 ha->pdev->subsystem_vendor,
2294 ha->pdev->subsystem_device));
2295
2296 goto skip_msi;
2297 }
2298
2299 ret = qla24xx_enable_msix(ha, rsp); 2297 ret = qla24xx_enable_msix(ha, rsp);
2300 if (!ret) { 2298 if (!ret) {
2301 DEBUG2(qla_printk(KERN_INFO, ha, 2299 DEBUG2(qla_printk(KERN_INFO, ha,
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index 6e53bdbb1da8..42eb7ffd5942 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -7,6 +7,7 @@
7#include "qla_def.h" 7#include "qla_def.h"
8 8
9#include <linux/delay.h> 9#include <linux/delay.h>
10#include <linux/gfp.h>
10 11
11 12
12/* 13/*
@@ -339,6 +340,7 @@ qla2x00_load_ram(scsi_qla_host_t *vha, dma_addr_t req_dma, uint32_t risc_addr,
339 return rval; 340 return rval;
340} 341}
341 342
343#define EXTENDED_BB_CREDITS BIT_0
342/* 344/*
343 * qla2x00_execute_fw 345 * qla2x00_execute_fw
344 * Start adapter firmware. 346 * Start adapter firmware.
@@ -371,7 +373,12 @@ qla2x00_execute_fw(scsi_qla_host_t *vha, uint32_t risc_addr)
371 mcp->mb[1] = MSW(risc_addr); 373 mcp->mb[1] = MSW(risc_addr);
372 mcp->mb[2] = LSW(risc_addr); 374 mcp->mb[2] = LSW(risc_addr);
373 mcp->mb[3] = 0; 375 mcp->mb[3] = 0;
374 mcp->mb[4] = 0; 376 if (IS_QLA81XX(ha)) {
377 struct nvram_81xx *nv = ha->nvram;
378 mcp->mb[4] = (nv->enhanced_features &
379 EXTENDED_BB_CREDITS);
380 } else
381 mcp->mb[4] = 0;
375 mcp->out_mb |= MBX_4|MBX_3|MBX_2|MBX_1; 382 mcp->out_mb |= MBX_4|MBX_3|MBX_2|MBX_1;
376 mcp->in_mb |= MBX_1; 383 mcp->in_mb |= MBX_1;
377 } else { 384 } else {
diff --git a/drivers/scsi/qla2xxx/qla_mid.c b/drivers/scsi/qla2xxx/qla_mid.c
index ff17dee28613..8220e7b9799b 100644
--- a/drivers/scsi/qla2xxx/qla_mid.c
+++ b/drivers/scsi/qla2xxx/qla_mid.c
@@ -9,6 +9,7 @@
9 9
10#include <linux/moduleparam.h> 10#include <linux/moduleparam.h>
11#include <linux/vmalloc.h> 11#include <linux/vmalloc.h>
12#include <linux/slab.h>
12#include <linux/list.h> 13#include <linux/list.h>
13 14
14#include <scsi/scsi_tcq.h> 15#include <scsi/scsi_tcq.h>
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 46720b23028f..48c37e38ed01 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -12,6 +12,7 @@
12#include <linux/kthread.h> 12#include <linux/kthread.h>
13#include <linux/mutex.h> 13#include <linux/mutex.h>
14#include <linux/kobject.h> 14#include <linux/kobject.h>
15#include <linux/slab.h>
15 16
16#include <scsi/scsi_tcq.h> 17#include <scsi/scsi_tcq.h>
17#include <scsi/scsicam.h> 18#include <scsi/scsicam.h>
@@ -1676,9 +1677,11 @@ skip_pio:
1676 1677
1677 /* Determine queue resources */ 1678 /* Determine queue resources */
1678 ha->max_req_queues = ha->max_rsp_queues = 1; 1679 ha->max_req_queues = ha->max_rsp_queues = 1;
1679 if ((ql2xmaxqueues <= 1 || ql2xmultique_tag < 1) && 1680 if ((ql2xmaxqueues <= 1 && !ql2xmultique_tag) ||
1681 (ql2xmaxqueues > 1 && ql2xmultique_tag) ||
1680 (!IS_QLA25XX(ha) && !IS_QLA81XX(ha))) 1682 (!IS_QLA25XX(ha) && !IS_QLA81XX(ha)))
1681 goto mqiobase_exit; 1683 goto mqiobase_exit;
1684
1682 ha->mqiobase = ioremap(pci_resource_start(ha->pdev, 3), 1685 ha->mqiobase = ioremap(pci_resource_start(ha->pdev, 3),
1683 pci_resource_len(ha->pdev, 3)); 1686 pci_resource_len(ha->pdev, 3));
1684 if (ha->mqiobase) { 1687 if (ha->mqiobase) {
diff --git a/drivers/scsi/qla2xxx/qla_sup.c b/drivers/scsi/qla2xxx/qla_sup.c
index 371dc895972a..8b3de4e54c28 100644
--- a/drivers/scsi/qla2xxx/qla_sup.c
+++ b/drivers/scsi/qla2xxx/qla_sup.c
@@ -7,6 +7,7 @@
7#include "qla_def.h" 7#include "qla_def.h"
8 8
9#include <linux/delay.h> 9#include <linux/delay.h>
10#include <linux/slab.h>
10#include <linux/vmalloc.h> 11#include <linux/vmalloc.h>
11#include <asm/uaccess.h> 12#include <asm/uaccess.h>
12 13
diff --git a/drivers/scsi/qla2xxx/qla_version.h b/drivers/scsi/qla2xxx/qla_version.h
index 8d2fc2fa7a6b..109068df933f 100644
--- a/drivers/scsi/qla2xxx/qla_version.h
+++ b/drivers/scsi/qla2xxx/qla_version.h
@@ -7,9 +7,9 @@
7/* 7/*
8 * Driver version 8 * Driver version
9 */ 9 */
10#define QLA2XXX_VERSION "8.03.02-k1" 10#define QLA2XXX_VERSION "8.03.02-k2"
11 11
12#define QLA_DRIVER_MAJOR_VER 8 12#define QLA_DRIVER_MAJOR_VER 8
13#define QLA_DRIVER_MINOR_VER 3 13#define QLA_DRIVER_MINOR_VER 3
14#define QLA_DRIVER_PATCH_VER 2 14#define QLA_DRIVER_PATCH_VER 2
15#define QLA_DRIVER_BETA_VER 1 15#define QLA_DRIVER_BETA_VER 2