diff options
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_def.h | 1 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_init.c | 26 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_mbx.c | 2 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_os.c | 1 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_sup.c | 19 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_version.h | 2 |
6 files changed, 15 insertions, 36 deletions
diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h index f25f41a499e5..b97194096d8e 100644 --- a/drivers/scsi/qla2xxx/qla_def.h +++ b/drivers/scsi/qla2xxx/qla_def.h | |||
@@ -2547,7 +2547,6 @@ typedef struct scsi_qla_host { | |||
2547 | uint8_t fcode_revision[16]; | 2547 | uint8_t fcode_revision[16]; |
2548 | uint32_t fw_revision[4]; | 2548 | uint32_t fw_revision[4]; |
2549 | 2549 | ||
2550 | uint16_t fdt_odd_index; | ||
2551 | uint32_t fdt_wrt_disable; | 2550 | uint32_t fdt_wrt_disable; |
2552 | uint32_t fdt_erase_cmd; | 2551 | uint32_t fdt_erase_cmd; |
2553 | uint32_t fdt_block_size; | 2552 | uint32_t fdt_block_size; |
diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c index a470f2d3270d..4218f20f5ed5 100644 --- a/drivers/scsi/qla2xxx/qla_init.c +++ b/drivers/scsi/qla2xxx/qla_init.c | |||
@@ -140,7 +140,6 @@ int | |||
140 | qla2100_pci_config(scsi_qla_host_t *ha) | 140 | qla2100_pci_config(scsi_qla_host_t *ha) |
141 | { | 141 | { |
142 | uint16_t w; | 142 | uint16_t w; |
143 | uint32_t d; | ||
144 | unsigned long flags; | 143 | unsigned long flags; |
145 | struct device_reg_2xxx __iomem *reg = &ha->iobase->isp; | 144 | struct device_reg_2xxx __iomem *reg = &ha->iobase->isp; |
146 | 145 | ||
@@ -151,10 +150,7 @@ qla2100_pci_config(scsi_qla_host_t *ha) | |||
151 | w |= (PCI_COMMAND_PARITY | PCI_COMMAND_SERR); | 150 | w |= (PCI_COMMAND_PARITY | PCI_COMMAND_SERR); |
152 | pci_write_config_word(ha->pdev, PCI_COMMAND, w); | 151 | pci_write_config_word(ha->pdev, PCI_COMMAND, w); |
153 | 152 | ||
154 | /* Reset expansion ROM address decode enable */ | 153 | pci_disable_rom(ha->pdev); |
155 | pci_read_config_dword(ha->pdev, PCI_ROM_ADDRESS, &d); | ||
156 | d &= ~PCI_ROM_ADDRESS_ENABLE; | ||
157 | pci_write_config_dword(ha->pdev, PCI_ROM_ADDRESS, d); | ||
158 | 154 | ||
159 | /* Get PCI bus information. */ | 155 | /* Get PCI bus information. */ |
160 | spin_lock_irqsave(&ha->hardware_lock, flags); | 156 | spin_lock_irqsave(&ha->hardware_lock, flags); |
@@ -174,7 +170,6 @@ int | |||
174 | qla2300_pci_config(scsi_qla_host_t *ha) | 170 | qla2300_pci_config(scsi_qla_host_t *ha) |
175 | { | 171 | { |
176 | uint16_t w; | 172 | uint16_t w; |
177 | uint32_t d; | ||
178 | unsigned long flags = 0; | 173 | unsigned long flags = 0; |
179 | uint32_t cnt; | 174 | uint32_t cnt; |
180 | struct device_reg_2xxx __iomem *reg = &ha->iobase->isp; | 175 | struct device_reg_2xxx __iomem *reg = &ha->iobase->isp; |
@@ -236,10 +231,7 @@ qla2300_pci_config(scsi_qla_host_t *ha) | |||
236 | 231 | ||
237 | pci_write_config_byte(ha->pdev, PCI_LATENCY_TIMER, 0x80); | 232 | pci_write_config_byte(ha->pdev, PCI_LATENCY_TIMER, 0x80); |
238 | 233 | ||
239 | /* Reset expansion ROM address decode enable */ | 234 | pci_disable_rom(ha->pdev); |
240 | pci_read_config_dword(ha->pdev, PCI_ROM_ADDRESS, &d); | ||
241 | d &= ~PCI_ROM_ADDRESS_ENABLE; | ||
242 | pci_write_config_dword(ha->pdev, PCI_ROM_ADDRESS, d); | ||
243 | 235 | ||
244 | /* Get PCI bus information. */ | 236 | /* Get PCI bus information. */ |
245 | spin_lock_irqsave(&ha->hardware_lock, flags); | 237 | spin_lock_irqsave(&ha->hardware_lock, flags); |
@@ -259,7 +251,6 @@ int | |||
259 | qla24xx_pci_config(scsi_qla_host_t *ha) | 251 | qla24xx_pci_config(scsi_qla_host_t *ha) |
260 | { | 252 | { |
261 | uint16_t w; | 253 | uint16_t w; |
262 | uint32_t d; | ||
263 | unsigned long flags = 0; | 254 | unsigned long flags = 0; |
264 | struct device_reg_24xx __iomem *reg = &ha->iobase->isp24; | 255 | struct device_reg_24xx __iomem *reg = &ha->iobase->isp24; |
265 | 256 | ||
@@ -281,10 +272,7 @@ qla24xx_pci_config(scsi_qla_host_t *ha) | |||
281 | if (pci_find_capability(ha->pdev, PCI_CAP_ID_EXP)) | 272 | if (pci_find_capability(ha->pdev, PCI_CAP_ID_EXP)) |
282 | pcie_set_readrq(ha->pdev, 2048); | 273 | pcie_set_readrq(ha->pdev, 2048); |
283 | 274 | ||
284 | /* Reset expansion ROM address decode enable */ | 275 | pci_disable_rom(ha->pdev); |
285 | pci_read_config_dword(ha->pdev, PCI_ROM_ADDRESS, &d); | ||
286 | d &= ~PCI_ROM_ADDRESS_ENABLE; | ||
287 | pci_write_config_dword(ha->pdev, PCI_ROM_ADDRESS, d); | ||
288 | 276 | ||
289 | ha->chip_revision = ha->pdev->revision; | 277 | ha->chip_revision = ha->pdev->revision; |
290 | 278 | ||
@@ -306,7 +294,6 @@ int | |||
306 | qla25xx_pci_config(scsi_qla_host_t *ha) | 294 | qla25xx_pci_config(scsi_qla_host_t *ha) |
307 | { | 295 | { |
308 | uint16_t w; | 296 | uint16_t w; |
309 | uint32_t d; | ||
310 | 297 | ||
311 | pci_set_master(ha->pdev); | 298 | pci_set_master(ha->pdev); |
312 | pci_try_set_mwi(ha->pdev); | 299 | pci_try_set_mwi(ha->pdev); |
@@ -320,10 +307,7 @@ qla25xx_pci_config(scsi_qla_host_t *ha) | |||
320 | if (pci_find_capability(ha->pdev, PCI_CAP_ID_EXP)) | 307 | if (pci_find_capability(ha->pdev, PCI_CAP_ID_EXP)) |
321 | pcie_set_readrq(ha->pdev, 2048); | 308 | pcie_set_readrq(ha->pdev, 2048); |
322 | 309 | ||
323 | /* Reset expansion ROM address decode enable */ | 310 | pci_disable_rom(ha->pdev); |
324 | pci_read_config_dword(ha->pdev, PCI_ROM_ADDRESS, &d); | ||
325 | d &= ~PCI_ROM_ADDRESS_ENABLE; | ||
326 | pci_write_config_dword(ha->pdev, PCI_ROM_ADDRESS, d); | ||
327 | 311 | ||
328 | ha->chip_revision = ha->pdev->revision; | 312 | ha->chip_revision = ha->pdev->revision; |
329 | 313 | ||
@@ -980,7 +964,6 @@ qla2x00_setup_chip(scsi_qla_host_t *ha) | |||
980 | &ha->fw_minor_version, | 964 | &ha->fw_minor_version, |
981 | &ha->fw_subminor_version, | 965 | &ha->fw_subminor_version, |
982 | &ha->fw_attributes, &ha->fw_memory_size); | 966 | &ha->fw_attributes, &ha->fw_memory_size); |
983 | qla2x00_resize_request_q(ha); | ||
984 | ha->flags.npiv_supported = 0; | 967 | ha->flags.npiv_supported = 0; |
985 | if ((IS_QLA24XX(ha) || IS_QLA25XX(ha) || | 968 | if ((IS_QLA24XX(ha) || IS_QLA25XX(ha) || |
986 | IS_QLA84XX(ha)) && | 969 | IS_QLA84XX(ha)) && |
@@ -992,6 +975,7 @@ qla2x00_setup_chip(scsi_qla_host_t *ha) | |||
992 | ha->max_npiv_vports = | 975 | ha->max_npiv_vports = |
993 | MIN_MULTI_ID_FABRIC - 1; | 976 | MIN_MULTI_ID_FABRIC - 1; |
994 | } | 977 | } |
978 | qla2x00_resize_request_q(ha); | ||
995 | 979 | ||
996 | if (ql2xallocfwdump) | 980 | if (ql2xallocfwdump) |
997 | qla2x00_alloc_fw_dump(ha); | 981 | qla2x00_alloc_fw_dump(ha); |
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c index 36bc6851e23d..3402746ec128 100644 --- a/drivers/scsi/qla2xxx/qla_mbx.c +++ b/drivers/scsi/qla2xxx/qla_mbx.c | |||
@@ -1964,7 +1964,7 @@ qla2x00_get_resource_cnts(scsi_qla_host_t *ha, uint16_t *cur_xchg_cnt, | |||
1964 | *cur_iocb_cnt = mcp->mb[7]; | 1964 | *cur_iocb_cnt = mcp->mb[7]; |
1965 | if (orig_iocb_cnt) | 1965 | if (orig_iocb_cnt) |
1966 | *orig_iocb_cnt = mcp->mb[10]; | 1966 | *orig_iocb_cnt = mcp->mb[10]; |
1967 | if (max_npiv_vports) | 1967 | if (ha->flags.npiv_supported && max_npiv_vports) |
1968 | *max_npiv_vports = mcp->mb[11]; | 1968 | *max_npiv_vports = mcp->mb[11]; |
1969 | } | 1969 | } |
1970 | 1970 | ||
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index 21dd182ad512..35567203ef61 100644 --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c | |||
@@ -728,6 +728,7 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd) | |||
728 | if (ha->isp_ops->abort_command(ha, sp)) { | 728 | if (ha->isp_ops->abort_command(ha, sp)) { |
729 | DEBUG2(printk("%s(%ld): abort_command " | 729 | DEBUG2(printk("%s(%ld): abort_command " |
730 | "mbx failed.\n", __func__, ha->host_no)); | 730 | "mbx failed.\n", __func__, ha->host_no)); |
731 | ret = FAILED; | ||
731 | } else { | 732 | } else { |
732 | DEBUG3(printk("%s(%ld): abort_command " | 733 | DEBUG3(printk("%s(%ld): abort_command " |
733 | "mbx success.\n", __func__, ha->host_no)); | 734 | "mbx success.\n", __func__, ha->host_no)); |
diff --git a/drivers/scsi/qla2xxx/qla_sup.c b/drivers/scsi/qla2xxx/qla_sup.c index 90a13211717f..e4af678eb2d6 100644 --- a/drivers/scsi/qla2xxx/qla_sup.c +++ b/drivers/scsi/qla2xxx/qla_sup.c | |||
@@ -722,6 +722,7 @@ done: | |||
722 | static void | 722 | static void |
723 | qla2xxx_get_fdt_info(scsi_qla_host_t *ha) | 723 | qla2xxx_get_fdt_info(scsi_qla_host_t *ha) |
724 | { | 724 | { |
725 | #define FLASH_BLK_SIZE_4K 0x1000 | ||
725 | #define FLASH_BLK_SIZE_32K 0x8000 | 726 | #define FLASH_BLK_SIZE_32K 0x8000 |
726 | #define FLASH_BLK_SIZE_64K 0x10000 | 727 | #define FLASH_BLK_SIZE_64K 0x10000 |
727 | const char *loc, *locations[] = { "MID", "FDT" }; | 728 | const char *loc, *locations[] = { "MID", "FDT" }; |
@@ -755,7 +756,6 @@ qla2xxx_get_fdt_info(scsi_qla_host_t *ha) | |||
755 | loc = locations[1]; | 756 | loc = locations[1]; |
756 | mid = le16_to_cpu(fdt->man_id); | 757 | mid = le16_to_cpu(fdt->man_id); |
757 | fid = le16_to_cpu(fdt->id); | 758 | fid = le16_to_cpu(fdt->id); |
758 | ha->fdt_odd_index = mid == 0x1f; | ||
759 | ha->fdt_wrt_disable = fdt->wrt_disable_bits; | 759 | ha->fdt_wrt_disable = fdt->wrt_disable_bits; |
760 | ha->fdt_erase_cmd = flash_conf_to_access_addr(0x0300 | fdt->erase_cmd); | 760 | ha->fdt_erase_cmd = flash_conf_to_access_addr(0x0300 | fdt->erase_cmd); |
761 | ha->fdt_block_size = le32_to_cpu(fdt->block_size); | 761 | ha->fdt_block_size = le32_to_cpu(fdt->block_size); |
@@ -788,8 +788,7 @@ no_flash_data: | |||
788 | ha->fdt_block_size = FLASH_BLK_SIZE_64K; | 788 | ha->fdt_block_size = FLASH_BLK_SIZE_64K; |
789 | break; | 789 | break; |
790 | case 0x1f: /* Atmel 26DF081A. */ | 790 | case 0x1f: /* Atmel 26DF081A. */ |
791 | ha->fdt_odd_index = 1; | 791 | ha->fdt_block_size = FLASH_BLK_SIZE_4K; |
792 | ha->fdt_block_size = FLASH_BLK_SIZE_64K; | ||
793 | ha->fdt_erase_cmd = flash_conf_to_access_addr(0x0320); | 792 | ha->fdt_erase_cmd = flash_conf_to_access_addr(0x0320); |
794 | ha->fdt_unprotect_sec_cmd = flash_conf_to_access_addr(0x0339); | 793 | ha->fdt_unprotect_sec_cmd = flash_conf_to_access_addr(0x0339); |
795 | ha->fdt_protect_sec_cmd = flash_conf_to_access_addr(0x0336); | 794 | ha->fdt_protect_sec_cmd = flash_conf_to_access_addr(0x0336); |
@@ -801,9 +800,9 @@ no_flash_data: | |||
801 | } | 800 | } |
802 | done: | 801 | done: |
803 | DEBUG2(qla_printk(KERN_DEBUG, ha, "FDT[%s]: (0x%x/0x%x) erase=0x%x " | 802 | DEBUG2(qla_printk(KERN_DEBUG, ha, "FDT[%s]: (0x%x/0x%x) erase=0x%x " |
804 | "pro=%x upro=%x idx=%d wrtd=0x%x blk=0x%x.\n", loc, mid, fid, | 803 | "pro=%x upro=%x wrtd=0x%x blk=0x%x.\n", loc, mid, fid, |
805 | ha->fdt_erase_cmd, ha->fdt_protect_sec_cmd, | 804 | ha->fdt_erase_cmd, ha->fdt_protect_sec_cmd, |
806 | ha->fdt_unprotect_sec_cmd, ha->fdt_odd_index, ha->fdt_wrt_disable, | 805 | ha->fdt_unprotect_sec_cmd, ha->fdt_wrt_disable, |
807 | ha->fdt_block_size)); | 806 | ha->fdt_block_size)); |
808 | } | 807 | } |
809 | 808 | ||
@@ -987,13 +986,9 @@ qla24xx_write_flash_data(scsi_qla_host_t *ha, uint32_t *dwptr, uint32_t faddr, | |||
987 | qla24xx_unprotect_flash(ha); | 986 | qla24xx_unprotect_flash(ha); |
988 | 987 | ||
989 | for (liter = 0; liter < dwords; liter++, faddr++, dwptr++) { | 988 | for (liter = 0; liter < dwords; liter++, faddr++, dwptr++) { |
990 | if (ha->fdt_odd_index) { | 989 | |
991 | findex = faddr << 2; | 990 | findex = faddr; |
992 | fdata = findex & sec_mask; | 991 | fdata = (findex & sec_mask) << 2; |
993 | } else { | ||
994 | findex = faddr; | ||
995 | fdata = (findex & sec_mask) << 2; | ||
996 | } | ||
997 | 992 | ||
998 | /* Are we at the beginning of a sector? */ | 993 | /* Are we at the beginning of a sector? */ |
999 | if ((findex & rest_addr) == 0) { | 994 | if ((findex & rest_addr) == 0) { |
diff --git a/drivers/scsi/qla2xxx/qla_version.h b/drivers/scsi/qla2xxx/qla_version.h index be5e299df528..eea6720adf16 100644 --- a/drivers/scsi/qla2xxx/qla_version.h +++ b/drivers/scsi/qla2xxx/qla_version.h | |||
@@ -7,7 +7,7 @@ | |||
7 | /* | 7 | /* |
8 | * Driver version | 8 | * Driver version |
9 | */ | 9 | */ |
10 | #define QLA2XXX_VERSION "8.02.01-k8" | 10 | #define QLA2XXX_VERSION "8.02.01-k9" |
11 | 11 | ||
12 | #define QLA_DRIVER_MAJOR_VER 8 | 12 | #define QLA_DRIVER_MAJOR_VER 8 |
13 | #define QLA_DRIVER_MINOR_VER 2 | 13 | #define QLA_DRIVER_MINOR_VER 2 |