diff options
Diffstat (limited to 'drivers/scsi/qla4xxx')
-rw-r--r-- | drivers/scsi/qla4xxx/Kconfig | 2 | ||||
-rw-r--r-- | drivers/scsi/qla4xxx/ql4_dbg.h | 4 | ||||
-rw-r--r-- | drivers/scsi/qla4xxx/ql4_glbl.h | 3 | ||||
-rw-r--r-- | drivers/scsi/qla4xxx/ql4_init.c | 2 | ||||
-rw-r--r-- | drivers/scsi/qla4xxx/ql4_mbx.c | 2 | ||||
-rw-r--r-- | drivers/scsi/qla4xxx/ql4_os.c | 52 | ||||
-rw-r--r-- | drivers/scsi/qla4xxx/ql4_version.h | 7 |
7 files changed, 25 insertions, 47 deletions
diff --git a/drivers/scsi/qla4xxx/Kconfig b/drivers/scsi/qla4xxx/Kconfig index 08a07f0b8d94..69cbff3f57cf 100644 --- a/drivers/scsi/qla4xxx/Kconfig +++ b/drivers/scsi/qla4xxx/Kconfig | |||
@@ -1,6 +1,6 @@ | |||
1 | config SCSI_QLA_ISCSI | 1 | config SCSI_QLA_ISCSI |
2 | tristate "QLogic ISP4XXX host adapter family support" | 2 | tristate "QLogic ISP4XXX host adapter family support" |
3 | depends on PCI && SCSI | 3 | depends on PCI && SCSI && NET |
4 | select SCSI_ISCSI_ATTRS | 4 | select SCSI_ISCSI_ATTRS |
5 | ---help--- | 5 | ---help--- |
6 | This driver supports the QLogic 40xx (ISP4XXX) iSCSI host | 6 | This driver supports the QLogic 40xx (ISP4XXX) iSCSI host |
diff --git a/drivers/scsi/qla4xxx/ql4_dbg.h b/drivers/scsi/qla4xxx/ql4_dbg.h index 3e99dcfd5a9f..d861c3b411c8 100644 --- a/drivers/scsi/qla4xxx/ql4_dbg.h +++ b/drivers/scsi/qla4xxx/ql4_dbg.h | |||
@@ -22,14 +22,14 @@ | |||
22 | #endif | 22 | #endif |
23 | 23 | ||
24 | #if defined(QL_DEBUG_LEVEL_2) | 24 | #if defined(QL_DEBUG_LEVEL_2) |
25 | #define DEBUG2(x) do {if(qla4_extended_error_logging == 2) x;} while (0); | 25 | #define DEBUG2(x) do {if(ql4xextended_error_logging == 2) x;} while (0); |
26 | #define DEBUG2_3(x) do {x;} while (0); | 26 | #define DEBUG2_3(x) do {x;} while (0); |
27 | #else /* */ | 27 | #else /* */ |
28 | #define DEBUG2(x) do {} while (0); | 28 | #define DEBUG2(x) do {} while (0); |
29 | #endif /* */ | 29 | #endif /* */ |
30 | 30 | ||
31 | #if defined(QL_DEBUG_LEVEL_3) | 31 | #if defined(QL_DEBUG_LEVEL_3) |
32 | #define DEBUG3(x) do {if(qla4_extended_error_logging == 3) x;} while (0); | 32 | #define DEBUG3(x) do {if(ql4xextended_error_logging == 3) x;} while (0); |
33 | #else /* */ | 33 | #else /* */ |
34 | #define DEBUG3(x) do {} while (0); | 34 | #define DEBUG3(x) do {} while (0); |
35 | #if !defined(QL_DEBUG_LEVEL_2) | 35 | #if !defined(QL_DEBUG_LEVEL_2) |
diff --git a/drivers/scsi/qla4xxx/ql4_glbl.h b/drivers/scsi/qla4xxx/ql4_glbl.h index 2c803edf2de8..eeefdcb1edb5 100644 --- a/drivers/scsi/qla4xxx/ql4_glbl.h +++ b/drivers/scsi/qla4xxx/ql4_glbl.h | |||
@@ -8,6 +8,7 @@ | |||
8 | #ifndef __QLA4x_GBL_H | 8 | #ifndef __QLA4x_GBL_H |
9 | #define __QLA4x_GBL_H | 9 | #define __QLA4x_GBL_H |
10 | 10 | ||
11 | int ql4xxx_lock_drvr_wait(struct scsi_qla_host *a); | ||
11 | int qla4xxx_send_tgts(struct scsi_qla_host *ha, char *ip, uint16_t port); | 12 | int qla4xxx_send_tgts(struct scsi_qla_host *ha, char *ip, uint16_t port); |
12 | int qla4xxx_send_command_to_isp(struct scsi_qla_host *ha, struct srb * srb); | 13 | int qla4xxx_send_command_to_isp(struct scsi_qla_host *ha, struct srb * srb); |
13 | int qla4xxx_initialize_adapter(struct scsi_qla_host * ha, | 14 | int qla4xxx_initialize_adapter(struct scsi_qla_host * ha, |
@@ -72,7 +73,7 @@ int qla4xxx_reinitialize_ddb_list(struct scsi_qla_host * ha); | |||
72 | int qla4xxx_process_ddb_changed(struct scsi_qla_host * ha, | 73 | int qla4xxx_process_ddb_changed(struct scsi_qla_host * ha, |
73 | uint32_t fw_ddb_index, uint32_t state); | 74 | uint32_t fw_ddb_index, uint32_t state); |
74 | 75 | ||
75 | extern int qla4_extended_error_logging; | 76 | extern int ql4xextended_error_logging; |
76 | extern int ql4xdiscoverywait; | 77 | extern int ql4xdiscoverywait; |
77 | extern int ql4xdontresethba; | 78 | extern int ql4xdontresethba; |
78 | #endif /* _QLA4x_GBL_H */ | 79 | #endif /* _QLA4x_GBL_H */ |
diff --git a/drivers/scsi/qla4xxx/ql4_init.c b/drivers/scsi/qla4xxx/ql4_init.c index bb3a1c11f44c..9e81b810dc88 100644 --- a/drivers/scsi/qla4xxx/ql4_init.c +++ b/drivers/scsi/qla4xxx/ql4_init.c | |||
@@ -978,7 +978,7 @@ static int qla4xxx_start_firmware_from_flash(struct scsi_qla_host *ha) | |||
978 | return status; | 978 | return status; |
979 | } | 979 | } |
980 | 980 | ||
981 | static int ql4xxx_lock_drvr_wait(struct scsi_qla_host *a) | 981 | int ql4xxx_lock_drvr_wait(struct scsi_qla_host *a) |
982 | { | 982 | { |
983 | #define QL4_LOCK_DRVR_WAIT 300 | 983 | #define QL4_LOCK_DRVR_WAIT 300 |
984 | #define QL4_LOCK_DRVR_SLEEP 100 | 984 | #define QL4_LOCK_DRVR_SLEEP 100 |
diff --git a/drivers/scsi/qla4xxx/ql4_mbx.c b/drivers/scsi/qla4xxx/ql4_mbx.c index ef82399c0858..b721dc5dd711 100644 --- a/drivers/scsi/qla4xxx/ql4_mbx.c +++ b/drivers/scsi/qla4xxx/ql4_mbx.c | |||
@@ -701,7 +701,7 @@ void qla4xxx_get_conn_event_log(struct scsi_qla_host * ha) | |||
701 | DEBUG3(printk("scsi%ld: Connection Event Log Dump (%d entries):\n", | 701 | DEBUG3(printk("scsi%ld: Connection Event Log Dump (%d entries):\n", |
702 | ha->host_no, num_valid_entries)); | 702 | ha->host_no, num_valid_entries)); |
703 | 703 | ||
704 | if (qla4_extended_error_logging == 3) { | 704 | if (ql4xextended_error_logging == 3) { |
705 | if (oldest_entry == 0) { | 705 | if (oldest_entry == 0) { |
706 | /* Circular Buffer has not wrapped around */ | 706 | /* Circular Buffer has not wrapped around */ |
707 | for (i=0; i < num_valid_entries; i++) { | 707 | for (i=0; i < num_valid_entries; i++) { |
diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c index 178fcddcfd81..bab434ee774b 100644 --- a/drivers/scsi/qla4xxx/ql4_os.c +++ b/drivers/scsi/qla4xxx/ql4_os.c | |||
@@ -34,9 +34,9 @@ MODULE_PARM_DESC(ql4xdontresethba, | |||
34 | " default it will reset hba :0" | 34 | " default it will reset hba :0" |
35 | " set to 1 to avoid resetting HBA"); | 35 | " set to 1 to avoid resetting HBA"); |
36 | 36 | ||
37 | int qla4_extended_error_logging = 0; /* 0 = off, 1 = log errors */ | 37 | int ql4xextended_error_logging = 0; /* 0 = off, 1 = log errors */ |
38 | module_param(qla4_extended_error_logging, int, S_IRUGO | S_IRUSR); | 38 | module_param(ql4xextended_error_logging, int, S_IRUGO | S_IRUSR); |
39 | MODULE_PARM_DESC(qla4_extended_error_logging, | 39 | MODULE_PARM_DESC(ql4xextended_error_logging, |
40 | "Option to enable extended error logging, " | 40 | "Option to enable extended error logging, " |
41 | "Default is 0 - no logging, 1 - debug logging"); | 41 | "Default is 0 - no logging, 1 - debug logging"); |
42 | 42 | ||
@@ -919,18 +919,11 @@ static int qla4xxx_recover_adapter(struct scsi_qla_host *ha, | |||
919 | if (status == QLA_SUCCESS) { | 919 | if (status == QLA_SUCCESS) { |
920 | DEBUG2(printk("scsi%ld: %s - Performing soft reset..\n", | 920 | DEBUG2(printk("scsi%ld: %s - Performing soft reset..\n", |
921 | ha->host_no, __func__)); | 921 | ha->host_no, __func__)); |
922 | status = qla4xxx_soft_reset(ha); | 922 | qla4xxx_flush_active_srbs(ha); |
923 | } | 923 | if (ql4xxx_lock_drvr_wait(ha) == QLA_SUCCESS) |
924 | /* FIXMEkaren: Do we want to keep interrupts enabled and process | 924 | status = qla4xxx_soft_reset(ha); |
925 | AENs after soft reset */ | 925 | else |
926 | 926 | status = QLA_ERROR; | |
927 | /* If firmware (SOFT) reset failed, or if all outstanding | ||
928 | * commands have not returned, then do a HARD reset. | ||
929 | */ | ||
930 | if (status == QLA_ERROR) { | ||
931 | DEBUG2(printk("scsi%ld: %s - Performing hard reset..\n", | ||
932 | ha->host_no, __func__)); | ||
933 | status = qla4xxx_hard_reset(ha); | ||
934 | } | 927 | } |
935 | 928 | ||
936 | /* Flush any pending ddb changed AENs */ | 929 | /* Flush any pending ddb changed AENs */ |
@@ -1016,13 +1009,9 @@ static void qla4xxx_do_dpc(void *data) | |||
1016 | struct scsi_qla_host *ha = (struct scsi_qla_host *) data; | 1009 | struct scsi_qla_host *ha = (struct scsi_qla_host *) data; |
1017 | struct ddb_entry *ddb_entry, *dtemp; | 1010 | struct ddb_entry *ddb_entry, *dtemp; |
1018 | 1011 | ||
1019 | DEBUG2(printk("scsi%ld: %s: DPC handler waking up.\n", | 1012 | DEBUG2(printk("scsi%ld: %s: DPC handler waking up." |
1020 | ha->host_no, __func__)); | 1013 | "flags = 0x%08lx, dpc_flags = 0x%08lx\n", |
1021 | 1014 | ha->host_no, __func__, ha->flags, ha->dpc_flags)); | |
1022 | DEBUG2(printk("scsi%ld: %s: ha->flags = 0x%08lx\n", | ||
1023 | ha->host_no, __func__, ha->flags)); | ||
1024 | DEBUG2(printk("scsi%ld: %s: ha->dpc_flags = 0x%08lx\n", | ||
1025 | ha->host_no, __func__, ha->dpc_flags)); | ||
1026 | 1015 | ||
1027 | /* Initialization not yet finished. Don't do anything yet. */ | 1016 | /* Initialization not yet finished. Don't do anything yet. */ |
1028 | if (!test_bit(AF_INIT_DONE, &ha->flags)) | 1017 | if (!test_bit(AF_INIT_DONE, &ha->flags)) |
@@ -1032,16 +1021,8 @@ static void qla4xxx_do_dpc(void *data) | |||
1032 | test_bit(DPC_RESET_HA, &ha->dpc_flags) || | 1021 | test_bit(DPC_RESET_HA, &ha->dpc_flags) || |
1033 | test_bit(DPC_RESET_HA_INTR, &ha->dpc_flags) || | 1022 | test_bit(DPC_RESET_HA_INTR, &ha->dpc_flags) || |
1034 | test_bit(DPC_RESET_HA_DESTROY_DDB_LIST, &ha->dpc_flags)) { | 1023 | test_bit(DPC_RESET_HA_DESTROY_DDB_LIST, &ha->dpc_flags)) { |
1035 | if (test_bit(DPC_RESET_HA_DESTROY_DDB_LIST, &ha->dpc_flags)) | 1024 | if (test_bit(DPC_RESET_HA_DESTROY_DDB_LIST, &ha->dpc_flags) || |
1036 | /* | 1025 | test_bit(DPC_RESET_HA, &ha->dpc_flags)) |
1037 | * dg 09/23 Never initialize ddb list | ||
1038 | * once we up and running | ||
1039 | * qla4xxx_recover_adapter(ha, | ||
1040 | * REBUILD_DDB_LIST); | ||
1041 | */ | ||
1042 | qla4xxx_recover_adapter(ha, PRESERVE_DDB_LIST); | ||
1043 | |||
1044 | if (test_bit(DPC_RESET_HA, &ha->dpc_flags)) | ||
1045 | qla4xxx_recover_adapter(ha, PRESERVE_DDB_LIST); | 1026 | qla4xxx_recover_adapter(ha, PRESERVE_DDB_LIST); |
1046 | 1027 | ||
1047 | if (test_and_clear_bit(DPC_RESET_HA_INTR, &ha->dpc_flags)) { | 1028 | if (test_and_clear_bit(DPC_RESET_HA_INTR, &ha->dpc_flags)) { |
@@ -1122,7 +1103,8 @@ static void qla4xxx_free_adapter(struct scsi_qla_host *ha) | |||
1122 | destroy_workqueue(ha->dpc_thread); | 1103 | destroy_workqueue(ha->dpc_thread); |
1123 | 1104 | ||
1124 | /* Issue Soft Reset to put firmware in unknown state */ | 1105 | /* Issue Soft Reset to put firmware in unknown state */ |
1125 | qla4xxx_soft_reset(ha); | 1106 | if (ql4xxx_lock_drvr_wait(ha) == QLA_SUCCESS) |
1107 | qla4xxx_soft_reset(ha); | ||
1126 | 1108 | ||
1127 | /* Remove timer thread, if present */ | 1109 | /* Remove timer thread, if present */ |
1128 | if (ha->timer_active) | 1110 | if (ha->timer_active) |
@@ -1714,7 +1696,7 @@ static int __init qla4xxx_module_init(void) | |||
1714 | 1696 | ||
1715 | /* Derive version string. */ | 1697 | /* Derive version string. */ |
1716 | strcpy(qla4xxx_version_str, QLA4XXX_DRIVER_VERSION); | 1698 | strcpy(qla4xxx_version_str, QLA4XXX_DRIVER_VERSION); |
1717 | if (qla4_extended_error_logging) | 1699 | if (ql4xextended_error_logging) |
1718 | strcat(qla4xxx_version_str, "-debug"); | 1700 | strcat(qla4xxx_version_str, "-debug"); |
1719 | 1701 | ||
1720 | qla4xxx_scsi_transport = | 1702 | qla4xxx_scsi_transport = |
@@ -1724,13 +1706,13 @@ static int __init qla4xxx_module_init(void) | |||
1724 | goto release_srb_cache; | 1706 | goto release_srb_cache; |
1725 | } | 1707 | } |
1726 | 1708 | ||
1727 | printk(KERN_INFO "QLogic iSCSI HBA Driver\n"); | ||
1728 | ret = pci_register_driver(&qla4xxx_pci_driver); | 1709 | ret = pci_register_driver(&qla4xxx_pci_driver); |
1729 | if (ret) | 1710 | if (ret) |
1730 | goto unregister_transport; | 1711 | goto unregister_transport; |
1731 | 1712 | ||
1732 | printk(KERN_INFO "QLogic iSCSI HBA Driver\n"); | 1713 | printk(KERN_INFO "QLogic iSCSI HBA Driver\n"); |
1733 | return 0; | 1714 | return 0; |
1715 | |||
1734 | unregister_transport: | 1716 | unregister_transport: |
1735 | iscsi_unregister_transport(&qla4xxx_iscsi_transport); | 1717 | iscsi_unregister_transport(&qla4xxx_iscsi_transport); |
1736 | release_srb_cache: | 1718 | release_srb_cache: |
diff --git a/drivers/scsi/qla4xxx/ql4_version.h b/drivers/scsi/qla4xxx/ql4_version.h index b3fe7e68988e..d05048b4e88a 100644 --- a/drivers/scsi/qla4xxx/ql4_version.h +++ b/drivers/scsi/qla4xxx/ql4_version.h | |||
@@ -5,9 +5,4 @@ | |||
5 | * See LICENSE.qla4xxx for copyright and licensing details. | 5 | * See LICENSE.qla4xxx for copyright and licensing details. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #define QLA4XXX_DRIVER_VERSION "5.00.05b9-k" | 8 | #define QLA4XXX_DRIVER_VERSION "5.00.06-k" |
9 | |||
10 | #define QL4_DRIVER_MAJOR_VER 5 | ||
11 | #define QL4_DRIVER_MINOR_VER 0 | ||
12 | #define QL4_DRIVER_PATCH_VER 5 | ||
13 | #define QL4_DRIVER_BETA_VER 9 | ||