diff options
author | Saurav Kashyap <saurav.kashyap@qlogic.com> | 2011-07-14 15:00:13 -0400 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2011-07-27 06:16:17 -0400 |
commit | 7c3df1320e5e875478775e78d01a09aee96b8abe (patch) | |
tree | 215326b999b3db03f4a2268a79c3848803daaf7d /drivers/scsi/qla2xxx/qla_init.c | |
parent | 3ce8866ceae87258cf66d1f7fd72abc918753cec (diff) |
[SCSI] qla2xxx: Code changes to support new dynamic logging infrastructure.
The code is changed to support the new dynamic logging infrastructure.
Following are the levels added.
Default is 0 - no logging. 0x40000000 - Module Init & Probe.
0x20000000 - Mailbox Cmnds. 0x10000000 - Device Discovery.
0x08000000 - IO tracing. 0x04000000 - DPC Thread.
0x02000000 - Async events. 0x01000000 - Timer routines.
0x00800000 - User space. 0x00400000 - Task Management.
0x00200000 - AER/EEH. 0x00100000 - Multi Q.
0x00080000 - P3P Specific. 0x00040000 - Virtual Port.
0x00020000 - Buffer Dump. 0x00010000 - Misc.
0x7fffffff - For enabling all logs, can be too many logs.
Setting ql2xextended_error_logging module parameter to any of the above
value, will enable the debug for that particular level.
Do LOGICAL OR of the value to enable more than one level.
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Joe Carnuccio <joe.carnuccio@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
Signed-off-by: Madhuranath Iyengar <Madhu.Iyengar@qlogic.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_init.c')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_init.c | 849 |
1 files changed, 426 insertions, 423 deletions
diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c index 3d0384506929..def694271bf7 100644 --- a/drivers/scsi/qla2xxx/qla_init.c +++ b/drivers/scsi/qla2xxx/qla_init.c | |||
@@ -153,11 +153,10 @@ qla2x00_async_iocb_timeout(srb_t *sp) | |||
153 | fc_port_t *fcport = sp->fcport; | 153 | fc_port_t *fcport = sp->fcport; |
154 | struct srb_ctx *ctx = sp->ctx; | 154 | struct srb_ctx *ctx = sp->ctx; |
155 | 155 | ||
156 | DEBUG2(printk(KERN_WARNING | 156 | ql_dbg(ql_dbg_disc, fcport->vha, 0x2071, |
157 | "scsi(%ld:%x): Async-%s timeout - portid=%02x%02x%02x.\n", | 157 | "Async-%s timeout - portid=%02x%02x%02x.\n", |
158 | fcport->vha->host_no, sp->handle, | 158 | ctx->name, fcport->d_id.b.domain, fcport->d_id.b.area, |
159 | ctx->name, fcport->d_id.b.domain, | 159 | fcport->d_id.b.al_pa); |
160 | fcport->d_id.b.area, fcport->d_id.b.al_pa)); | ||
161 | 160 | ||
162 | fcport->flags &= ~FCF_ASYNC_SENT; | 161 | fcport->flags &= ~FCF_ASYNC_SENT; |
163 | if (ctx->type == SRB_LOGIN_CMD) { | 162 | if (ctx->type == SRB_LOGIN_CMD) { |
@@ -211,11 +210,10 @@ qla2x00_async_login(struct scsi_qla_host *vha, fc_port_t *fcport, | |||
211 | if (rval != QLA_SUCCESS) | 210 | if (rval != QLA_SUCCESS) |
212 | goto done_free_sp; | 211 | goto done_free_sp; |
213 | 212 | ||
214 | DEBUG2(printk(KERN_DEBUG | 213 | ql_dbg(ql_dbg_disc, vha, 0x2072, |
215 | "scsi(%ld:%x): Async-login - loop-id=%x portid=%02x%02x%02x " | 214 | "Async-login - loopid=%x portid=%02x%02x%02x retries=%d.\n", |
216 | "retries=%d.\n", fcport->vha->host_no, sp->handle, fcport->loop_id, | 215 | fcport->loop_id, fcport->d_id.b.domain, fcport->d_id.b.area, |
217 | fcport->d_id.b.domain, fcport->d_id.b.area, fcport->d_id.b.al_pa, | 216 | fcport->d_id.b.al_pa, fcport->login_retry); |
218 | fcport->login_retry)); | ||
219 | return rval; | 217 | return rval; |
220 | 218 | ||
221 | done_free_sp: | 219 | done_free_sp: |
@@ -259,10 +257,10 @@ qla2x00_async_logout(struct scsi_qla_host *vha, fc_port_t *fcport) | |||
259 | if (rval != QLA_SUCCESS) | 257 | if (rval != QLA_SUCCESS) |
260 | goto done_free_sp; | 258 | goto done_free_sp; |
261 | 259 | ||
262 | DEBUG2(printk(KERN_DEBUG | 260 | ql_dbg(ql_dbg_disc, vha, 0x2070, |
263 | "scsi(%ld:%x): Async-logout - loop-id=%x portid=%02x%02x%02x.\n", | 261 | "Async-logout - loop-id=%x portid=%02x%02x%02x.\n", |
264 | fcport->vha->host_no, sp->handle, fcport->loop_id, | 262 | fcport->loop_id, fcport->d_id.b.domain, fcport->d_id.b.area, |
265 | fcport->d_id.b.domain, fcport->d_id.b.area, fcport->d_id.b.al_pa)); | 263 | fcport->d_id.b.al_pa); |
266 | return rval; | 264 | return rval; |
267 | 265 | ||
268 | done_free_sp: | 266 | done_free_sp: |
@@ -309,11 +307,10 @@ qla2x00_async_adisc(struct scsi_qla_host *vha, fc_port_t *fcport, | |||
309 | if (rval != QLA_SUCCESS) | 307 | if (rval != QLA_SUCCESS) |
310 | goto done_free_sp; | 308 | goto done_free_sp; |
311 | 309 | ||
312 | DEBUG2(printk(KERN_DEBUG | 310 | ql_dbg(ql_dbg_disc, vha, 0x206f, |
313 | "scsi(%ld:%x): Async-adisc - loop-id=%x portid=%02x%02x%02x.\n", | 311 | "Async-adisc - loopid=%x portid=%02x%02x%02x.\n", |
314 | fcport->vha->host_no, sp->handle, fcport->loop_id, | 312 | fcport->loop_id, fcport->d_id.b.domain, fcport->d_id.b.area, |
315 | fcport->d_id.b.domain, fcport->d_id.b.area, fcport->d_id.b.al_pa)); | 313 | fcport->d_id.b.al_pa); |
316 | |||
317 | return rval; | 314 | return rval; |
318 | 315 | ||
319 | done_free_sp: | 316 | done_free_sp: |
@@ -362,11 +359,10 @@ qla2x00_async_tm_cmd(fc_port_t *fcport, uint32_t flags, uint32_t lun, | |||
362 | if (rval != QLA_SUCCESS) | 359 | if (rval != QLA_SUCCESS) |
363 | goto done_free_sp; | 360 | goto done_free_sp; |
364 | 361 | ||
365 | DEBUG2(printk(KERN_DEBUG | 362 | ql_dbg(ql_dbg_taskm, vha, 0x802f, |
366 | "scsi(%ld:%x): Async-tmf - loop-id=%x portid=%02x%02x%02x.\n", | 363 | "Async-tmf loop-id=%x portid=%02x%02x%02x.\n", |
367 | fcport->vha->host_no, sp->handle, fcport->loop_id, | 364 | fcport->loop_id, fcport->d_id.b.domain, fcport->d_id.b.area, |
368 | fcport->d_id.b.domain, fcport->d_id.b.area, fcport->d_id.b.al_pa)); | 365 | fcport->d_id.b.al_pa); |
369 | |||
370 | return rval; | 366 | return rval; |
371 | 367 | ||
372 | done_free_sp: | 368 | done_free_sp: |
@@ -471,9 +467,8 @@ qla2x00_async_tm_cmd_done(struct scsi_qla_host *vha, fc_port_t *fcport, | |||
471 | flags == TCF_LUN_RESET ? MK_SYNC_ID_LUN : MK_SYNC_ID); | 467 | flags == TCF_LUN_RESET ? MK_SYNC_ID_LUN : MK_SYNC_ID); |
472 | 468 | ||
473 | if ((rval != QLA_SUCCESS) || iocb->u.tmf.data) { | 469 | if ((rval != QLA_SUCCESS) || iocb->u.tmf.data) { |
474 | DEBUG2_3_11(printk(KERN_WARNING | 470 | ql_dbg(ql_dbg_taskm, vha, 0x8030, |
475 | "%s(%ld): TM IOCB failed (%x).\n", | 471 | "TM IOCB failed (%x).\n", rval); |
476 | __func__, vha->host_no, rval)); | ||
477 | } | 472 | } |
478 | 473 | ||
479 | return; | 474 | return; |
@@ -519,11 +514,12 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha) | |||
519 | set_bit(0, ha->req_qid_map); | 514 | set_bit(0, ha->req_qid_map); |
520 | set_bit(0, ha->rsp_qid_map); | 515 | set_bit(0, ha->rsp_qid_map); |
521 | 516 | ||
522 | qla_printk(KERN_INFO, ha, "Configuring PCI space...\n"); | 517 | ql_log(ql_log_info, vha, 0x0040, |
518 | "Configuring PCI space...\n"); | ||
523 | rval = ha->isp_ops->pci_config(vha); | 519 | rval = ha->isp_ops->pci_config(vha); |
524 | if (rval) { | 520 | if (rval) { |
525 | DEBUG2(printk("scsi(%ld): Unable to configure PCI space.\n", | 521 | ql_log(ql_log_warn, vha, 0x0044, |
526 | vha->host_no)); | 522 | "Unable to configure PCI space.\n"); |
527 | return (rval); | 523 | return (rval); |
528 | } | 524 | } |
529 | 525 | ||
@@ -531,20 +527,21 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha) | |||
531 | 527 | ||
532 | rval = qla2xxx_get_flash_info(vha); | 528 | rval = qla2xxx_get_flash_info(vha); |
533 | if (rval) { | 529 | if (rval) { |
534 | DEBUG2(printk("scsi(%ld): Unable to validate FLASH data.\n", | 530 | ql_log(ql_log_fatal, vha, 0x004f, |
535 | vha->host_no)); | 531 | "Unable to validate FLASH data.\n"); |
536 | return (rval); | 532 | return (rval); |
537 | } | 533 | } |
538 | 534 | ||
539 | ha->isp_ops->get_flash_version(vha, req->ring); | 535 | ha->isp_ops->get_flash_version(vha, req->ring); |
540 | 536 | ql_log(ql_log_info, vha, 0x0061, | |
541 | qla_printk(KERN_INFO, ha, "Configure NVRAM parameters...\n"); | 537 | "Configure NVRAM parameters...\n"); |
542 | 538 | ||
543 | ha->isp_ops->nvram_config(vha); | 539 | ha->isp_ops->nvram_config(vha); |
544 | 540 | ||
545 | if (ha->flags.disable_serdes) { | 541 | if (ha->flags.disable_serdes) { |
546 | /* Mask HBA via NVRAM settings? */ | 542 | /* Mask HBA via NVRAM settings? */ |
547 | qla_printk(KERN_INFO, ha, "Masking HBA WWPN " | 543 | ql_log(ql_log_info, vha, 0x0077, |
544 | "Masking HBA WWPN " | ||
548 | "%02x%02x%02x%02x%02x%02x%02x%02x (via NVRAM).\n", | 545 | "%02x%02x%02x%02x%02x%02x%02x%02x (via NVRAM).\n", |
549 | vha->port_name[0], vha->port_name[1], | 546 | vha->port_name[0], vha->port_name[1], |
550 | vha->port_name[2], vha->port_name[3], | 547 | vha->port_name[2], vha->port_name[3], |
@@ -553,7 +550,8 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha) | |||
553 | return QLA_FUNCTION_FAILED; | 550 | return QLA_FUNCTION_FAILED; |
554 | } | 551 | } |
555 | 552 | ||
556 | qla_printk(KERN_INFO, ha, "Verifying loaded RISC code...\n"); | 553 | ql_log(ql_log_info, vha, 0x0078, |
554 | "Verifying loaded RISC code...\n"); | ||
557 | 555 | ||
558 | if (qla2x00_isp_firmware(vha) != QLA_SUCCESS) { | 556 | if (qla2x00_isp_firmware(vha) != QLA_SUCCESS) { |
559 | rval = ha->isp_ops->chip_diag(vha); | 557 | rval = ha->isp_ops->chip_diag(vha); |
@@ -567,7 +565,7 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha) | |||
567 | if (IS_QLA84XX(ha)) { | 565 | if (IS_QLA84XX(ha)) { |
568 | ha->cs84xx = qla84xx_get_chip(vha); | 566 | ha->cs84xx = qla84xx_get_chip(vha); |
569 | if (!ha->cs84xx) { | 567 | if (!ha->cs84xx) { |
570 | qla_printk(KERN_ERR, ha, | 568 | ql_log(ql_log_warn, vha, 0x00d0, |
571 | "Unable to configure ISP84XX.\n"); | 569 | "Unable to configure ISP84XX.\n"); |
572 | return QLA_FUNCTION_FAILED; | 570 | return QLA_FUNCTION_FAILED; |
573 | } | 571 | } |
@@ -579,8 +577,8 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha) | |||
579 | /* Issue verify 84xx FW IOCB to complete 84xx initialization */ | 577 | /* Issue verify 84xx FW IOCB to complete 84xx initialization */ |
580 | rval = qla84xx_init_chip(vha); | 578 | rval = qla84xx_init_chip(vha); |
581 | if (rval != QLA_SUCCESS) { | 579 | if (rval != QLA_SUCCESS) { |
582 | qla_printk(KERN_ERR, ha, | 580 | ql_log(ql_log_warn, vha, 0x00d4, |
583 | "Unable to initialize ISP84XX.\n"); | 581 | "Unable to initialize ISP84XX.\n"); |
584 | qla84xx_put_chip(vha); | 582 | qla84xx_put_chip(vha); |
585 | } | 583 | } |
586 | } | 584 | } |
@@ -797,9 +795,7 @@ qla2x00_isp_firmware(scsi_qla_host_t *vha) | |||
797 | rval = QLA_FUNCTION_FAILED; | 795 | rval = QLA_FUNCTION_FAILED; |
798 | 796 | ||
799 | if (ha->flags.disable_risc_code_load) { | 797 | if (ha->flags.disable_risc_code_load) { |
800 | DEBUG2(printk("scsi(%ld): RISC CODE NOT loaded\n", | 798 | ql_log(ql_log_info, vha, 0x0079, "RISC CODE NOT loaded.\n"); |
801 | vha->host_no)); | ||
802 | qla_printk(KERN_INFO, ha, "RISC CODE NOT loaded\n"); | ||
803 | 799 | ||
804 | /* Verify checksum of loaded RISC code. */ | 800 | /* Verify checksum of loaded RISC code. */ |
805 | rval = qla2x00_verify_checksum(vha, ha->fw_srisc_address); | 801 | rval = qla2x00_verify_checksum(vha, ha->fw_srisc_address); |
@@ -810,10 +806,9 @@ qla2x00_isp_firmware(scsi_qla_host_t *vha) | |||
810 | } | 806 | } |
811 | } | 807 | } |
812 | 808 | ||
813 | if (rval) { | 809 | if (rval) |
814 | DEBUG2_3(printk("scsi(%ld): **** Load RISC code ****\n", | 810 | ql_dbg(ql_dbg_init, vha, 0x007a, |
815 | vha->host_no)); | 811 | "**** Load RISC code ****.\n"); |
816 | } | ||
817 | 812 | ||
818 | return (rval); | 813 | return (rval); |
819 | } | 814 | } |
@@ -1105,8 +1100,8 @@ qla2x00_chip_diag(scsi_qla_host_t *vha) | |||
1105 | /* Assume a failed state */ | 1100 | /* Assume a failed state */ |
1106 | rval = QLA_FUNCTION_FAILED; | 1101 | rval = QLA_FUNCTION_FAILED; |
1107 | 1102 | ||
1108 | DEBUG3(printk("scsi(%ld): Testing device at %lx.\n", | 1103 | ql_dbg(ql_dbg_init, vha, 0x007b, |
1109 | vha->host_no, (u_long)®->flash_address)); | 1104 | "Testing device at %lx.\n", (u_long)®->flash_address); |
1110 | 1105 | ||
1111 | spin_lock_irqsave(&ha->hardware_lock, flags); | 1106 | spin_lock_irqsave(&ha->hardware_lock, flags); |
1112 | 1107 | ||
@@ -1128,8 +1123,8 @@ qla2x00_chip_diag(scsi_qla_host_t *vha) | |||
1128 | if (!cnt) | 1123 | if (!cnt) |
1129 | goto chip_diag_failed; | 1124 | goto chip_diag_failed; |
1130 | 1125 | ||
1131 | DEBUG3(printk("scsi(%ld): Reset register cleared by chip reset\n", | 1126 | ql_dbg(ql_dbg_init, vha, 0x007c, |
1132 | vha->host_no)); | 1127 | "Reset register cleared by chip reset.\n"); |
1133 | 1128 | ||
1134 | /* Reset RISC processor. */ | 1129 | /* Reset RISC processor. */ |
1135 | WRT_REG_WORD(®->hccr, HCCR_RESET_RISC); | 1130 | WRT_REG_WORD(®->hccr, HCCR_RESET_RISC); |
@@ -1150,7 +1145,7 @@ qla2x00_chip_diag(scsi_qla_host_t *vha) | |||
1150 | goto chip_diag_failed; | 1145 | goto chip_diag_failed; |
1151 | 1146 | ||
1152 | /* Check product ID of chip */ | 1147 | /* Check product ID of chip */ |
1153 | DEBUG3(printk("scsi(%ld): Checking product ID of chip\n", vha->host_no)); | 1148 | ql_dbg(ql_dbg_init, vha, 0x007d, "Checking product Id of chip.\n"); |
1154 | 1149 | ||
1155 | mb[1] = RD_MAILBOX_REG(ha, reg, 1); | 1150 | mb[1] = RD_MAILBOX_REG(ha, reg, 1); |
1156 | mb[2] = RD_MAILBOX_REG(ha, reg, 2); | 1151 | mb[2] = RD_MAILBOX_REG(ha, reg, 2); |
@@ -1158,8 +1153,9 @@ qla2x00_chip_diag(scsi_qla_host_t *vha) | |||
1158 | mb[4] = qla2x00_debounce_register(MAILBOX_REG(ha, reg, 4)); | 1153 | mb[4] = qla2x00_debounce_register(MAILBOX_REG(ha, reg, 4)); |
1159 | if (mb[1] != PROD_ID_1 || (mb[2] != PROD_ID_2 && mb[2] != PROD_ID_2a) || | 1154 | if (mb[1] != PROD_ID_1 || (mb[2] != PROD_ID_2 && mb[2] != PROD_ID_2a) || |
1160 | mb[3] != PROD_ID_3) { | 1155 | mb[3] != PROD_ID_3) { |
1161 | qla_printk(KERN_WARNING, ha, | 1156 | ql_log(ql_log_warn, vha, 0x0062, |
1162 | "Wrong product ID = 0x%x,0x%x,0x%x\n", mb[1], mb[2], mb[3]); | 1157 | "Wrong product ID = 0x%x,0x%x,0x%x.\n", |
1158 | mb[1], mb[2], mb[3]); | ||
1163 | 1159 | ||
1164 | goto chip_diag_failed; | 1160 | goto chip_diag_failed; |
1165 | } | 1161 | } |
@@ -1178,8 +1174,7 @@ qla2x00_chip_diag(scsi_qla_host_t *vha) | |||
1178 | if (IS_QLA2200(ha) && | 1174 | if (IS_QLA2200(ha) && |
1179 | RD_MAILBOX_REG(ha, reg, 7) == QLA2200A_RISC_ROM_VER) { | 1175 | RD_MAILBOX_REG(ha, reg, 7) == QLA2200A_RISC_ROM_VER) { |
1180 | /* Limit firmware transfer size with a 2200A */ | 1176 | /* Limit firmware transfer size with a 2200A */ |
1181 | DEBUG3(printk("scsi(%ld): Found QLA2200A chip.\n", | 1177 | ql_dbg(ql_dbg_init, vha, 0x007e, "Found QLA2200A Chip.\n"); |
1182 | vha->host_no)); | ||
1183 | 1178 | ||
1184 | ha->device_type |= DT_ISP2200A; | 1179 | ha->device_type |= DT_ISP2200A; |
1185 | ha->fw_transfer_size = 128; | 1180 | ha->fw_transfer_size = 128; |
@@ -1188,24 +1183,20 @@ qla2x00_chip_diag(scsi_qla_host_t *vha) | |||
1188 | /* Wrap Incoming Mailboxes Test. */ | 1183 | /* Wrap Incoming Mailboxes Test. */ |
1189 | spin_unlock_irqrestore(&ha->hardware_lock, flags); | 1184 | spin_unlock_irqrestore(&ha->hardware_lock, flags); |
1190 | 1185 | ||
1191 | DEBUG3(printk("scsi(%ld): Checking mailboxes.\n", vha->host_no)); | 1186 | ql_dbg(ql_dbg_init, vha, 0x007f, "Checking mailboxes.\n"); |
1192 | rval = qla2x00_mbx_reg_test(vha); | 1187 | rval = qla2x00_mbx_reg_test(vha); |
1193 | if (rval) { | 1188 | if (rval) |
1194 | DEBUG(printk("scsi(%ld): Failed mailbox send register test\n", | 1189 | ql_log(ql_log_warn, vha, 0x0080, |
1195 | vha->host_no)); | 1190 | "Failed mailbox send register test.\n"); |
1196 | qla_printk(KERN_WARNING, ha, | 1191 | else |
1197 | "Failed mailbox send register test\n"); | ||
1198 | } | ||
1199 | else { | ||
1200 | /* Flag a successful rval */ | 1192 | /* Flag a successful rval */ |
1201 | rval = QLA_SUCCESS; | 1193 | rval = QLA_SUCCESS; |
1202 | } | ||
1203 | spin_lock_irqsave(&ha->hardware_lock, flags); | 1194 | spin_lock_irqsave(&ha->hardware_lock, flags); |
1204 | 1195 | ||
1205 | chip_diag_failed: | 1196 | chip_diag_failed: |
1206 | if (rval) | 1197 | if (rval) |
1207 | DEBUG2_3(printk("scsi(%ld): Chip diagnostics **** FAILED " | 1198 | ql_log(ql_log_info, vha, 0x0081, |
1208 | "****\n", vha->host_no)); | 1199 | "Chip diagnostics **** FAILED ****.\n"); |
1209 | 1200 | ||
1210 | spin_unlock_irqrestore(&ha->hardware_lock, flags); | 1201 | spin_unlock_irqrestore(&ha->hardware_lock, flags); |
1211 | 1202 | ||
@@ -1232,10 +1223,8 @@ qla24xx_chip_diag(scsi_qla_host_t *vha) | |||
1232 | 1223 | ||
1233 | rval = qla2x00_mbx_reg_test(vha); | 1224 | rval = qla2x00_mbx_reg_test(vha); |
1234 | if (rval) { | 1225 | if (rval) { |
1235 | DEBUG(printk("scsi(%ld): Failed mailbox send register test\n", | 1226 | ql_log(ql_log_warn, vha, 0x0082, |
1236 | vha->host_no)); | 1227 | "Failed mailbox send register test.\n"); |
1237 | qla_printk(KERN_WARNING, ha, | ||
1238 | "Failed mailbox send register test\n"); | ||
1239 | } else { | 1228 | } else { |
1240 | /* Flag a successful rval */ | 1229 | /* Flag a successful rval */ |
1241 | rval = QLA_SUCCESS; | 1230 | rval = QLA_SUCCESS; |
@@ -1257,8 +1246,8 @@ qla2x00_alloc_fw_dump(scsi_qla_host_t *vha) | |||
1257 | struct rsp_que *rsp = ha->rsp_q_map[0]; | 1246 | struct rsp_que *rsp = ha->rsp_q_map[0]; |
1258 | 1247 | ||
1259 | if (ha->fw_dump) { | 1248 | if (ha->fw_dump) { |
1260 | qla_printk(KERN_WARNING, ha, | 1249 | ql_dbg(ql_dbg_init, vha, 0x00bd, |
1261 | "Firmware dump previously allocated.\n"); | 1250 | "Firmware dump already allocated.\n"); |
1262 | return; | 1251 | return; |
1263 | } | 1252 | } |
1264 | 1253 | ||
@@ -1288,8 +1277,9 @@ qla2x00_alloc_fw_dump(scsi_qla_host_t *vha) | |||
1288 | tc = dma_alloc_coherent(&ha->pdev->dev, FCE_SIZE, &tc_dma, | 1277 | tc = dma_alloc_coherent(&ha->pdev->dev, FCE_SIZE, &tc_dma, |
1289 | GFP_KERNEL); | 1278 | GFP_KERNEL); |
1290 | if (!tc) { | 1279 | if (!tc) { |
1291 | qla_printk(KERN_WARNING, ha, "Unable to allocate " | 1280 | ql_log(ql_log_warn, vha, 0x00be, |
1292 | "(%d KB) for FCE.\n", FCE_SIZE / 1024); | 1281 | "Unable to allocate (%d KB) for FCE.\n", |
1282 | FCE_SIZE / 1024); | ||
1293 | goto try_eft; | 1283 | goto try_eft; |
1294 | } | 1284 | } |
1295 | 1285 | ||
@@ -1297,16 +1287,15 @@ qla2x00_alloc_fw_dump(scsi_qla_host_t *vha) | |||
1297 | rval = qla2x00_enable_fce_trace(vha, tc_dma, FCE_NUM_BUFFERS, | 1287 | rval = qla2x00_enable_fce_trace(vha, tc_dma, FCE_NUM_BUFFERS, |
1298 | ha->fce_mb, &ha->fce_bufs); | 1288 | ha->fce_mb, &ha->fce_bufs); |
1299 | if (rval) { | 1289 | if (rval) { |
1300 | qla_printk(KERN_WARNING, ha, "Unable to initialize " | 1290 | ql_log(ql_log_warn, vha, 0x00bf, |
1301 | "FCE (%d).\n", rval); | 1291 | "Unable to initialize FCE (%d).\n", rval); |
1302 | dma_free_coherent(&ha->pdev->dev, FCE_SIZE, tc, | 1292 | dma_free_coherent(&ha->pdev->dev, FCE_SIZE, tc, |
1303 | tc_dma); | 1293 | tc_dma); |
1304 | ha->flags.fce_enabled = 0; | 1294 | ha->flags.fce_enabled = 0; |
1305 | goto try_eft; | 1295 | goto try_eft; |
1306 | } | 1296 | } |
1307 | 1297 | ql_log(ql_log_info, vha, 0x00c0, | |
1308 | qla_printk(KERN_INFO, ha, "Allocated (%d KB) for FCE...\n", | 1298 | "Allocate (%d KB) for FCE...\n", FCE_SIZE / 1024); |
1309 | FCE_SIZE / 1024); | ||
1310 | 1299 | ||
1311 | fce_size = sizeof(struct qla2xxx_fce_chain) + FCE_SIZE; | 1300 | fce_size = sizeof(struct qla2xxx_fce_chain) + FCE_SIZE; |
1312 | ha->flags.fce_enabled = 1; | 1301 | ha->flags.fce_enabled = 1; |
@@ -1317,23 +1306,23 @@ try_eft: | |||
1317 | tc = dma_alloc_coherent(&ha->pdev->dev, EFT_SIZE, &tc_dma, | 1306 | tc = dma_alloc_coherent(&ha->pdev->dev, EFT_SIZE, &tc_dma, |
1318 | GFP_KERNEL); | 1307 | GFP_KERNEL); |
1319 | if (!tc) { | 1308 | if (!tc) { |
1320 | qla_printk(KERN_WARNING, ha, "Unable to allocate " | 1309 | ql_log(ql_log_warn, vha, 0x00c1, |
1321 | "(%d KB) for EFT.\n", EFT_SIZE / 1024); | 1310 | "Unable to allocate (%d KB) for EFT.\n", |
1311 | EFT_SIZE / 1024); | ||
1322 | goto cont_alloc; | 1312 | goto cont_alloc; |
1323 | } | 1313 | } |
1324 | 1314 | ||
1325 | memset(tc, 0, EFT_SIZE); | 1315 | memset(tc, 0, EFT_SIZE); |
1326 | rval = qla2x00_enable_eft_trace(vha, tc_dma, EFT_NUM_BUFFERS); | 1316 | rval = qla2x00_enable_eft_trace(vha, tc_dma, EFT_NUM_BUFFERS); |
1327 | if (rval) { | 1317 | if (rval) { |
1328 | qla_printk(KERN_WARNING, ha, "Unable to initialize " | 1318 | ql_log(ql_log_warn, vha, 0x00c2, |
1329 | "EFT (%d).\n", rval); | 1319 | "Unable to initialize EFT (%d).\n", rval); |
1330 | dma_free_coherent(&ha->pdev->dev, EFT_SIZE, tc, | 1320 | dma_free_coherent(&ha->pdev->dev, EFT_SIZE, tc, |
1331 | tc_dma); | 1321 | tc_dma); |
1332 | goto cont_alloc; | 1322 | goto cont_alloc; |
1333 | } | 1323 | } |
1334 | 1324 | ql_log(ql_log_info, vha, 0x00c3, | |
1335 | qla_printk(KERN_INFO, ha, "Allocated (%d KB) for EFT...\n", | 1325 | "Allocated (%d KB) EFT ...\n", EFT_SIZE / 1024); |
1336 | EFT_SIZE / 1024); | ||
1337 | 1326 | ||
1338 | eft_size = EFT_SIZE; | 1327 | eft_size = EFT_SIZE; |
1339 | ha->eft_dma = tc_dma; | 1328 | ha->eft_dma = tc_dma; |
@@ -1350,8 +1339,9 @@ cont_alloc: | |||
1350 | 1339 | ||
1351 | ha->fw_dump = vmalloc(dump_size); | 1340 | ha->fw_dump = vmalloc(dump_size); |
1352 | if (!ha->fw_dump) { | 1341 | if (!ha->fw_dump) { |
1353 | qla_printk(KERN_WARNING, ha, "Unable to allocate (%d KB) for " | 1342 | ql_log(ql_log_warn, vha, 0x00c4, |
1354 | "firmware dump!!!\n", dump_size / 1024); | 1343 | "Unable to allocate (%d KB) for firmware dump.\n", |
1344 | dump_size / 1024); | ||
1355 | 1345 | ||
1356 | if (ha->fce) { | 1346 | if (ha->fce) { |
1357 | dma_free_coherent(&ha->pdev->dev, FCE_SIZE, ha->fce, | 1347 | dma_free_coherent(&ha->pdev->dev, FCE_SIZE, ha->fce, |
@@ -1368,8 +1358,8 @@ cont_alloc: | |||
1368 | } | 1358 | } |
1369 | return; | 1359 | return; |
1370 | } | 1360 | } |
1371 | qla_printk(KERN_INFO, ha, "Allocated (%d KB) for firmware dump...\n", | 1361 | ql_log(ql_log_info, vha, 0x00c5, |
1372 | dump_size / 1024); | 1362 | "Allocated (%d KB) for firmware dump.\n", dump_size / 1024); |
1373 | 1363 | ||
1374 | ha->fw_dump_len = dump_size; | 1364 | ha->fw_dump_len = dump_size; |
1375 | ha->fw_dump->signature[0] = 'Q'; | 1365 | ha->fw_dump->signature[0] = 'Q'; |
@@ -1398,23 +1388,21 @@ qla81xx_mpi_sync(scsi_qla_host_t *vha) | |||
1398 | int rval; | 1388 | int rval; |
1399 | uint16_t dc; | 1389 | uint16_t dc; |
1400 | uint32_t dw; | 1390 | uint32_t dw; |
1401 | struct qla_hw_data *ha = vha->hw; | ||
1402 | 1391 | ||
1403 | if (!IS_QLA81XX(vha->hw)) | 1392 | if (!IS_QLA81XX(vha->hw)) |
1404 | return QLA_SUCCESS; | 1393 | return QLA_SUCCESS; |
1405 | 1394 | ||
1406 | rval = qla2x00_write_ram_word(vha, 0x7c00, 1); | 1395 | rval = qla2x00_write_ram_word(vha, 0x7c00, 1); |
1407 | if (rval != QLA_SUCCESS) { | 1396 | if (rval != QLA_SUCCESS) { |
1408 | DEBUG2(qla_printk(KERN_WARNING, ha, | 1397 | ql_log(ql_log_warn, vha, 0x0105, |
1409 | "Sync-MPI: Unable to acquire semaphore.\n")); | 1398 | "Unable to acquire semaphore.\n"); |
1410 | goto done; | 1399 | goto done; |
1411 | } | 1400 | } |
1412 | 1401 | ||
1413 | pci_read_config_word(vha->hw->pdev, 0x54, &dc); | 1402 | pci_read_config_word(vha->hw->pdev, 0x54, &dc); |
1414 | rval = qla2x00_read_ram_word(vha, 0x7a15, &dw); | 1403 | rval = qla2x00_read_ram_word(vha, 0x7a15, &dw); |
1415 | if (rval != QLA_SUCCESS) { | 1404 | if (rval != QLA_SUCCESS) { |
1416 | DEBUG2(qla_printk(KERN_WARNING, ha, | 1405 | ql_log(ql_log_warn, vha, 0x0067, "Unable to read sync.\n"); |
1417 | "Sync-MPI: Unable to read sync.\n")); | ||
1418 | goto done_release; | 1406 | goto done_release; |
1419 | } | 1407 | } |
1420 | 1408 | ||
@@ -1426,15 +1414,14 @@ qla81xx_mpi_sync(scsi_qla_host_t *vha) | |||
1426 | dw |= dc; | 1414 | dw |= dc; |
1427 | rval = qla2x00_write_ram_word(vha, 0x7a15, dw); | 1415 | rval = qla2x00_write_ram_word(vha, 0x7a15, dw); |
1428 | if (rval != QLA_SUCCESS) { | 1416 | if (rval != QLA_SUCCESS) { |
1429 | DEBUG2(qla_printk(KERN_WARNING, ha, | 1417 | ql_log(ql_log_warn, vha, 0x0114, "Unable to gain sync.\n"); |
1430 | "Sync-MPI: Unable to gain sync.\n")); | ||
1431 | } | 1418 | } |
1432 | 1419 | ||
1433 | done_release: | 1420 | done_release: |
1434 | rval = qla2x00_write_ram_word(vha, 0x7c00, 0); | 1421 | rval = qla2x00_write_ram_word(vha, 0x7c00, 0); |
1435 | if (rval != QLA_SUCCESS) { | 1422 | if (rval != QLA_SUCCESS) { |
1436 | DEBUG2(qla_printk(KERN_WARNING, ha, | 1423 | ql_log(ql_log_warn, vha, 0x006d, |
1437 | "Sync-MPI: Unable to release semaphore.\n")); | 1424 | "Unable to release semaphore.\n"); |
1438 | } | 1425 | } |
1439 | 1426 | ||
1440 | done: | 1427 | done: |
@@ -1479,14 +1466,14 @@ qla2x00_setup_chip(scsi_qla_host_t *vha) | |||
1479 | /* Load firmware sequences */ | 1466 | /* Load firmware sequences */ |
1480 | rval = ha->isp_ops->load_risc(vha, &srisc_address); | 1467 | rval = ha->isp_ops->load_risc(vha, &srisc_address); |
1481 | if (rval == QLA_SUCCESS) { | 1468 | if (rval == QLA_SUCCESS) { |
1482 | DEBUG(printk("scsi(%ld): Verifying Checksum of loaded RISC " | 1469 | ql_dbg(ql_dbg_init, vha, 0x00c9, |
1483 | "code.\n", vha->host_no)); | 1470 | "Verifying Checksum of loaded RISC code.\n"); |
1484 | 1471 | ||
1485 | rval = qla2x00_verify_checksum(vha, srisc_address); | 1472 | rval = qla2x00_verify_checksum(vha, srisc_address); |
1486 | if (rval == QLA_SUCCESS) { | 1473 | if (rval == QLA_SUCCESS) { |
1487 | /* Start firmware execution. */ | 1474 | /* Start firmware execution. */ |
1488 | DEBUG(printk("scsi(%ld): Checksum OK, start " | 1475 | ql_dbg(ql_dbg_init, vha, 0x00ca, |
1489 | "firmware.\n", vha->host_no)); | 1476 | "Starting firmware.\n"); |
1490 | 1477 | ||
1491 | rval = qla2x00_execute_fw(vha, srisc_address); | 1478 | rval = qla2x00_execute_fw(vha, srisc_address); |
1492 | /* Retrieve firmware information. */ | 1479 | /* Retrieve firmware information. */ |
@@ -1522,9 +1509,9 @@ enable_82xx_npiv: | |||
1522 | } | 1509 | } |
1523 | } | 1510 | } |
1524 | } else { | 1511 | } else { |
1525 | DEBUG2(printk(KERN_INFO | 1512 | ql_log(ql_log_fatal, vha, 0x00cd, |
1526 | "scsi(%ld): ISP Firmware failed checksum.\n", | 1513 | "ISP Firmware failed checksum.\n"); |
1527 | vha->host_no)); | 1514 | goto failed; |
1528 | } | 1515 | } |
1529 | } | 1516 | } |
1530 | 1517 | ||
@@ -1549,7 +1536,7 @@ enable_82xx_npiv: | |||
1549 | ha->flags.fac_supported = 1; | 1536 | ha->flags.fac_supported = 1; |
1550 | ha->fdt_block_size = size << 2; | 1537 | ha->fdt_block_size = size << 2; |
1551 | } else { | 1538 | } else { |
1552 | qla_printk(KERN_ERR, ha, | 1539 | ql_log(ql_log_warn, vha, 0x00ce, |
1553 | "Unsupported FAC firmware (%d.%02d.%02d).\n", | 1540 | "Unsupported FAC firmware (%d.%02d.%02d).\n", |
1554 | ha->fw_major_version, ha->fw_minor_version, | 1541 | ha->fw_major_version, ha->fw_minor_version, |
1555 | ha->fw_subminor_version); | 1542 | ha->fw_subminor_version); |
@@ -1557,8 +1544,8 @@ enable_82xx_npiv: | |||
1557 | } | 1544 | } |
1558 | failed: | 1545 | failed: |
1559 | if (rval) { | 1546 | if (rval) { |
1560 | DEBUG2_3(printk("scsi(%ld): Setup chip **** FAILED ****.\n", | 1547 | ql_log(ql_log_fatal, vha, 0x00cf, |
1561 | vha->host_no)); | 1548 | "Setup chip ****FAILED****.\n"); |
1562 | } | 1549 | } |
1563 | 1550 | ||
1564 | return (rval); | 1551 | return (rval); |
@@ -1608,10 +1595,11 @@ qla2x00_update_fw_options(scsi_qla_host_t *vha) | |||
1608 | return; | 1595 | return; |
1609 | 1596 | ||
1610 | /* Serial Link options. */ | 1597 | /* Serial Link options. */ |
1611 | DEBUG3(printk("scsi(%ld): Serial link options:\n", | 1598 | ql_dbg(ql_dbg_init + ql_dbg_buffer, vha, 0x0115, |
1612 | vha->host_no)); | 1599 | "Serial link options.\n"); |
1613 | DEBUG3(qla2x00_dump_buffer((uint8_t *)&ha->fw_seriallink_options, | 1600 | ql_dump_buffer(ql_dbg_init + ql_dbg_buffer, vha, 0x0109, |
1614 | sizeof(ha->fw_seriallink_options))); | 1601 | (uint8_t *)&ha->fw_seriallink_options, |
1602 | sizeof(ha->fw_seriallink_options)); | ||
1615 | 1603 | ||
1616 | ha->fw_options[1] &= ~FO1_SET_EMPHASIS_SWING; | 1604 | ha->fw_options[1] &= ~FO1_SET_EMPHASIS_SWING; |
1617 | if (ha->fw_seriallink_options[3] & BIT_2) { | 1605 | if (ha->fw_seriallink_options[3] & BIT_2) { |
@@ -1688,7 +1676,7 @@ qla24xx_update_fw_options(scsi_qla_host_t *vha) | |||
1688 | le16_to_cpu(ha->fw_seriallink_options24[2]), | 1676 | le16_to_cpu(ha->fw_seriallink_options24[2]), |
1689 | le16_to_cpu(ha->fw_seriallink_options24[3])); | 1677 | le16_to_cpu(ha->fw_seriallink_options24[3])); |
1690 | if (rval != QLA_SUCCESS) { | 1678 | if (rval != QLA_SUCCESS) { |
1691 | qla_printk(KERN_WARNING, ha, | 1679 | ql_log(ql_log_warn, vha, 0x0104, |
1692 | "Unable to update Serial Link options (%x).\n", rval); | 1680 | "Unable to update Serial Link options (%x).\n", rval); |
1693 | } | 1681 | } |
1694 | } | 1682 | } |
@@ -1746,8 +1734,9 @@ qla24xx_config_rings(struct scsi_qla_host *vha) | |||
1746 | icb->rid = __constant_cpu_to_le16(rid); | 1734 | icb->rid = __constant_cpu_to_le16(rid); |
1747 | if (ha->flags.msix_enabled) { | 1735 | if (ha->flags.msix_enabled) { |
1748 | msix = &ha->msix_entries[1]; | 1736 | msix = &ha->msix_entries[1]; |
1749 | DEBUG2_17(printk(KERN_INFO | 1737 | ql_dbg(ql_dbg_init, vha, 0x00fd, |
1750 | "Registering vector 0x%x for base que\n", msix->entry)); | 1738 | "Registering vector 0x%x for base que.\n", |
1739 | msix->entry); | ||
1751 | icb->msix = cpu_to_le16(msix->entry); | 1740 | icb->msix = cpu_to_le16(msix->entry); |
1752 | } | 1741 | } |
1753 | /* Use alternate PCI bus number */ | 1742 | /* Use alternate PCI bus number */ |
@@ -1764,8 +1753,8 @@ qla24xx_config_rings(struct scsi_qla_host *vha) | |||
1764 | icb->firmware_options_2 &= | 1753 | icb->firmware_options_2 &= |
1765 | __constant_cpu_to_le32(~BIT_22); | 1754 | __constant_cpu_to_le32(~BIT_22); |
1766 | ha->flags.disable_msix_handshake = 1; | 1755 | ha->flags.disable_msix_handshake = 1; |
1767 | qla_printk(KERN_INFO, ha, | 1756 | ql_dbg(ql_dbg_init, vha, 0x00fe, |
1768 | "MSIX Handshake Disable Mode turned on\n"); | 1757 | "MSIX Handshake Disable Mode turned on.\n"); |
1769 | } else { | 1758 | } else { |
1770 | icb->firmware_options_2 |= | 1759 | icb->firmware_options_2 |= |
1771 | __constant_cpu_to_le32(BIT_22); | 1760 | __constant_cpu_to_le32(BIT_22); |
@@ -1850,7 +1839,7 @@ qla2x00_init_rings(scsi_qla_host_t *vha) | |||
1850 | /* Update any ISP specific firmware options before initialization. */ | 1839 | /* Update any ISP specific firmware options before initialization. */ |
1851 | ha->isp_ops->update_fw_options(vha); | 1840 | ha->isp_ops->update_fw_options(vha); |
1852 | 1841 | ||
1853 | DEBUG(printk("scsi(%ld): Issue init firmware.\n", vha->host_no)); | 1842 | ql_dbg(ql_dbg_init, vha, 0x00d1, "Issue init firmware.\n"); |
1854 | 1843 | ||
1855 | if (ha->flags.npiv_supported) { | 1844 | if (ha->flags.npiv_supported) { |
1856 | if (ha->operating_mode == LOOP) | 1845 | if (ha->operating_mode == LOOP) |
@@ -1866,11 +1855,11 @@ qla2x00_init_rings(scsi_qla_host_t *vha) | |||
1866 | 1855 | ||
1867 | rval = qla2x00_init_firmware(vha, ha->init_cb_size); | 1856 | rval = qla2x00_init_firmware(vha, ha->init_cb_size); |
1868 | if (rval) { | 1857 | if (rval) { |
1869 | DEBUG2_3(printk("scsi(%ld): Init firmware **** FAILED ****.\n", | 1858 | ql_log(ql_log_fatal, vha, 0x00d2, |
1870 | vha->host_no)); | 1859 | "Init Firmware **** FAILED ****.\n"); |
1871 | } else { | 1860 | } else { |
1872 | DEBUG3(printk("scsi(%ld): Init firmware -- success.\n", | 1861 | ql_dbg(ql_dbg_init, vha, 0x00d3, |
1873 | vha->host_no)); | 1862 | "Init Firmware -- success.\n"); |
1874 | } | 1863 | } |
1875 | 1864 | ||
1876 | return (rval); | 1865 | return (rval); |
@@ -1913,10 +1902,8 @@ qla2x00_fw_ready(scsi_qla_host_t *vha) | |||
1913 | 1902 | ||
1914 | /* Wait for ISP to finish LIP */ | 1903 | /* Wait for ISP to finish LIP */ |
1915 | if (!vha->flags.init_done) | 1904 | if (!vha->flags.init_done) |
1916 | qla_printk(KERN_INFO, ha, "Waiting for LIP to complete...\n"); | 1905 | ql_log(ql_log_info, vha, 0x801e, |
1917 | 1906 | "Waiting for LIP to complete.\n"); | |
1918 | DEBUG3(printk("scsi(%ld): Waiting for LIP to complete...\n", | ||
1919 | vha->host_no)); | ||
1920 | 1907 | ||
1921 | do { | 1908 | do { |
1922 | rval = qla2x00_get_firmware_state(vha, state); | 1909 | rval = qla2x00_get_firmware_state(vha, state); |
@@ -1925,30 +1912,35 @@ qla2x00_fw_ready(scsi_qla_host_t *vha) | |||
1925 | vha->device_flags &= ~DFLG_NO_CABLE; | 1912 | vha->device_flags &= ~DFLG_NO_CABLE; |
1926 | } | 1913 | } |
1927 | if (IS_QLA84XX(ha) && state[0] != FSTATE_READY) { | 1914 | if (IS_QLA84XX(ha) && state[0] != FSTATE_READY) { |
1928 | DEBUG16(printk("scsi(%ld): fw_state=%x " | 1915 | ql_dbg(ql_dbg_taskm, vha, 0x801f, |
1929 | "84xx=%x.\n", vha->host_no, state[0], | 1916 | "fw_state=%x 84xx=%x.\n", state[0], |
1930 | state[2])); | 1917 | state[2]); |
1931 | if ((state[2] & FSTATE_LOGGED_IN) && | 1918 | if ((state[2] & FSTATE_LOGGED_IN) && |
1932 | (state[2] & FSTATE_WAITING_FOR_VERIFY)) { | 1919 | (state[2] & FSTATE_WAITING_FOR_VERIFY)) { |
1933 | DEBUG16(printk("scsi(%ld): Sending " | 1920 | ql_dbg(ql_dbg_taskm, vha, 0x8028, |
1934 | "verify iocb.\n", vha->host_no)); | 1921 | "Sending verify iocb.\n"); |
1935 | 1922 | ||
1936 | cs84xx_time = jiffies; | 1923 | cs84xx_time = jiffies; |
1937 | rval = qla84xx_init_chip(vha); | 1924 | rval = qla84xx_init_chip(vha); |
1938 | if (rval != QLA_SUCCESS) | 1925 | if (rval != QLA_SUCCESS) { |
1926 | ql_log(ql_log_warn, | ||
1927 | vha, 0x8043, | ||
1928 | "Init chip failed.\n"); | ||
1939 | break; | 1929 | break; |
1930 | } | ||
1940 | 1931 | ||
1941 | /* Add time taken to initialize. */ | 1932 | /* Add time taken to initialize. */ |
1942 | cs84xx_time = jiffies - cs84xx_time; | 1933 | cs84xx_time = jiffies - cs84xx_time; |
1943 | wtime += cs84xx_time; | 1934 | wtime += cs84xx_time; |
1944 | mtime += cs84xx_time; | 1935 | mtime += cs84xx_time; |
1945 | DEBUG16(printk("scsi(%ld): Increasing " | 1936 | ql_dbg(ql_dbg_taskm, vha, 0x8042, |
1946 | "wait time by %ld. New time %ld\n", | 1937 | "Increasing wait time by %ld. " |
1947 | vha->host_no, cs84xx_time, wtime)); | 1938 | "New time %ld.\n", cs84xx_time, |
1939 | wtime); | ||
1948 | } | 1940 | } |
1949 | } else if (state[0] == FSTATE_READY) { | 1941 | } else if (state[0] == FSTATE_READY) { |
1950 | DEBUG(printk("scsi(%ld): F/W Ready - OK \n", | 1942 | ql_dbg(ql_dbg_taskm, vha, 0x8037, |
1951 | vha->host_no)); | 1943 | "F/W Ready - OK.\n"); |
1952 | 1944 | ||
1953 | qla2x00_get_retry_cnt(vha, &ha->retry_count, | 1945 | qla2x00_get_retry_cnt(vha, &ha->retry_count, |
1954 | &ha->login_timeout, &ha->r_a_tov); | 1946 | &ha->login_timeout, &ha->r_a_tov); |
@@ -1965,7 +1957,7 @@ qla2x00_fw_ready(scsi_qla_host_t *vha) | |||
1965 | * other than Wait for Login. | 1957 | * other than Wait for Login. |
1966 | */ | 1958 | */ |
1967 | if (time_after_eq(jiffies, mtime)) { | 1959 | if (time_after_eq(jiffies, mtime)) { |
1968 | qla_printk(KERN_INFO, ha, | 1960 | ql_log(ql_log_info, vha, 0x8038, |
1969 | "Cable is unplugged...\n"); | 1961 | "Cable is unplugged...\n"); |
1970 | 1962 | ||
1971 | vha->device_flags |= DFLG_NO_CABLE; | 1963 | vha->device_flags |= DFLG_NO_CABLE; |
@@ -1985,17 +1977,17 @@ qla2x00_fw_ready(scsi_qla_host_t *vha) | |||
1985 | /* Delay for a while */ | 1977 | /* Delay for a while */ |
1986 | msleep(500); | 1978 | msleep(500); |
1987 | 1979 | ||
1988 | DEBUG3(printk("scsi(%ld): fw_state=%x curr time=%lx.\n", | 1980 | ql_dbg(ql_dbg_taskm, vha, 0x8039, |
1989 | vha->host_no, state[0], jiffies)); | 1981 | "fw_state=%x curr time=%lx.\n", state[0], jiffies); |
1990 | } while (1); | 1982 | } while (1); |
1991 | 1983 | ||
1992 | DEBUG(printk("scsi(%ld): fw_state=%x (%x, %x, %x, %x) curr time=%lx.\n", | 1984 | ql_dbg(ql_dbg_taskm, vha, 0x803a, |
1993 | vha->host_no, state[0], state[1], state[2], state[3], state[4], | 1985 | "fw_state=%x (%x, %x, %x, %x) " "curr time=%lx.\n", state[0], |
1994 | jiffies)); | 1986 | state[1], state[2], state[3], state[4], jiffies); |
1995 | 1987 | ||
1996 | if (rval) { | 1988 | if (rval) { |
1997 | DEBUG2_3(printk("scsi(%ld): Firmware ready **** FAILED ****.\n", | 1989 | ql_log(ql_log_warn, vha, 0x803b, |
1998 | vha->host_no)); | 1990 | "Firmware ready **** FAILED ****.\n"); |
1999 | } | 1991 | } |
2000 | 1992 | ||
2001 | return (rval); | 1993 | return (rval); |
@@ -2034,19 +2026,19 @@ qla2x00_configure_hba(scsi_qla_host_t *vha) | |||
2034 | if (LOOP_TRANSITION(vha) || atomic_read(&ha->loop_down_timer) || | 2026 | if (LOOP_TRANSITION(vha) || atomic_read(&ha->loop_down_timer) || |
2035 | IS_QLA8XXX_TYPE(ha) || | 2027 | IS_QLA8XXX_TYPE(ha) || |
2036 | (rval == QLA_COMMAND_ERROR && loop_id == 0x7)) { | 2028 | (rval == QLA_COMMAND_ERROR && loop_id == 0x7)) { |
2037 | DEBUG2(printk("%s(%ld) Loop is in a transition state\n", | 2029 | ql_dbg(ql_dbg_disc, vha, 0x2008, |
2038 | __func__, vha->host_no)); | 2030 | "Loop is in a transition state.\n"); |
2039 | } else { | 2031 | } else { |
2040 | qla_printk(KERN_WARNING, ha, | 2032 | ql_log(ql_log_warn, vha, 0x2009, |
2041 | "ERROR -- Unable to get host loop ID.\n"); | 2033 | "Unable to get host loop ID.\n"); |
2042 | set_bit(ISP_ABORT_NEEDED, &vha->dpc_flags); | 2034 | set_bit(ISP_ABORT_NEEDED, &vha->dpc_flags); |
2043 | } | 2035 | } |
2044 | return (rval); | 2036 | return (rval); |
2045 | } | 2037 | } |
2046 | 2038 | ||
2047 | if (topo == 4) { | 2039 | if (topo == 4) { |
2048 | qla_printk(KERN_INFO, ha, | 2040 | ql_log(ql_log_info, vha, 0x200a, |
2049 | "Cannot get topology - retrying.\n"); | 2041 | "Cannot get topology - retrying.\n"); |
2050 | return (QLA_FUNCTION_FAILED); | 2042 | return (QLA_FUNCTION_FAILED); |
2051 | } | 2043 | } |
2052 | 2044 | ||
@@ -2059,31 +2051,27 @@ qla2x00_configure_hba(scsi_qla_host_t *vha) | |||
2059 | 2051 | ||
2060 | switch (topo) { | 2052 | switch (topo) { |
2061 | case 0: | 2053 | case 0: |
2062 | DEBUG3(printk("scsi(%ld): HBA in NL topology.\n", | 2054 | ql_dbg(ql_dbg_disc, vha, 0x200b, "HBA in NL topology.\n"); |
2063 | vha->host_no)); | ||
2064 | ha->current_topology = ISP_CFG_NL; | 2055 | ha->current_topology = ISP_CFG_NL; |
2065 | strcpy(connect_type, "(Loop)"); | 2056 | strcpy(connect_type, "(Loop)"); |
2066 | break; | 2057 | break; |
2067 | 2058 | ||
2068 | case 1: | 2059 | case 1: |
2069 | DEBUG3(printk("scsi(%ld): HBA in FL topology.\n", | 2060 | ql_dbg(ql_dbg_disc, vha, 0x200c, "HBA in FL topology.\n"); |
2070 | vha->host_no)); | ||
2071 | ha->switch_cap = sw_cap; | 2061 | ha->switch_cap = sw_cap; |
2072 | ha->current_topology = ISP_CFG_FL; | 2062 | ha->current_topology = ISP_CFG_FL; |
2073 | strcpy(connect_type, "(FL_Port)"); | 2063 | strcpy(connect_type, "(FL_Port)"); |
2074 | break; | 2064 | break; |
2075 | 2065 | ||
2076 | case 2: | 2066 | case 2: |
2077 | DEBUG3(printk("scsi(%ld): HBA in N P2P topology.\n", | 2067 | ql_dbg(ql_dbg_disc, vha, 0x200d, "HBA in N P2P topology.\n"); |
2078 | vha->host_no)); | ||
2079 | ha->operating_mode = P2P; | 2068 | ha->operating_mode = P2P; |
2080 | ha->current_topology = ISP_CFG_N; | 2069 | ha->current_topology = ISP_CFG_N; |
2081 | strcpy(connect_type, "(N_Port-to-N_Port)"); | 2070 | strcpy(connect_type, "(N_Port-to-N_Port)"); |
2082 | break; | 2071 | break; |
2083 | 2072 | ||
2084 | case 3: | 2073 | case 3: |
2085 | DEBUG3(printk("scsi(%ld): HBA in F P2P topology.\n", | 2074 | ql_dbg(ql_dbg_disc, vha, 0x200e, "HBA in F P2P topology.\n"); |
2086 | vha->host_no)); | ||
2087 | ha->switch_cap = sw_cap; | 2075 | ha->switch_cap = sw_cap; |
2088 | ha->operating_mode = P2P; | 2076 | ha->operating_mode = P2P; |
2089 | ha->current_topology = ISP_CFG_F; | 2077 | ha->current_topology = ISP_CFG_F; |
@@ -2091,9 +2079,8 @@ qla2x00_configure_hba(scsi_qla_host_t *vha) | |||
2091 | break; | 2079 | break; |
2092 | 2080 | ||
2093 | default: | 2081 | default: |
2094 | DEBUG3(printk("scsi(%ld): HBA in unknown topology %x. " | 2082 | ql_dbg(ql_dbg_disc, vha, 0x200f, |
2095 | "Using NL.\n", | 2083 | "HBA in unknown topology %x, using NL.\n", topo); |
2096 | vha->host_no, topo)); | ||
2097 | ha->current_topology = ISP_CFG_NL; | 2084 | ha->current_topology = ISP_CFG_NL; |
2098 | strcpy(connect_type, "(Loop)"); | 2085 | strcpy(connect_type, "(Loop)"); |
2099 | break; | 2086 | break; |
@@ -2106,14 +2093,16 @@ qla2x00_configure_hba(scsi_qla_host_t *vha) | |||
2106 | vha->d_id.b.al_pa = al_pa; | 2093 | vha->d_id.b.al_pa = al_pa; |
2107 | 2094 | ||
2108 | if (!vha->flags.init_done) | 2095 | if (!vha->flags.init_done) |
2109 | qla_printk(KERN_INFO, ha, | 2096 | ql_log(ql_log_info, vha, 0x2010, |
2110 | "Topology - %s, Host Loop address 0x%x\n", | 2097 | "Topology - %s, Host Loop address 0x%x.\n", |
2111 | connect_type, vha->loop_id); | 2098 | connect_type, vha->loop_id); |
2112 | 2099 | ||
2113 | if (rval) { | 2100 | if (rval) { |
2114 | DEBUG2_3(printk("scsi(%ld): FAILED.\n", vha->host_no)); | 2101 | ql_log(ql_log_warn, vha, 0x2011, |
2102 | "%s FAILED\n", __func__); | ||
2115 | } else { | 2103 | } else { |
2116 | DEBUG3(printk("scsi(%ld): exiting normally.\n", vha->host_no)); | 2104 | ql_dbg(ql_dbg_disc, vha, 0x2012, |
2105 | "%s success\n", __func__); | ||
2117 | } | 2106 | } |
2118 | 2107 | ||
2119 | return(rval); | 2108 | return(rval); |
@@ -2227,18 +2216,22 @@ qla2x00_nvram_config(scsi_qla_host_t *vha) | |||
2227 | for (cnt = 0, chksum = 0; cnt < ha->nvram_size; cnt++) | 2216 | for (cnt = 0, chksum = 0; cnt < ha->nvram_size; cnt++) |
2228 | chksum += *ptr++; | 2217 | chksum += *ptr++; |
2229 | 2218 | ||
2230 | DEBUG5(printk("scsi(%ld): Contents of NVRAM\n", vha->host_no)); | 2219 | ql_dbg(ql_dbg_init + ql_dbg_buffer, vha, 0x010f, |
2231 | DEBUG5(qla2x00_dump_buffer((uint8_t *)nv, ha->nvram_size)); | 2220 | "Contents of NVRAM.\n"); |
2221 | ql_dump_buffer(ql_dbg_init + ql_dbg_buffer, vha, 0x0110, | ||
2222 | (uint8_t *)nv, ha->nvram_size); | ||
2232 | 2223 | ||
2233 | /* Bad NVRAM data, set defaults parameters. */ | 2224 | /* Bad NVRAM data, set defaults parameters. */ |
2234 | if (chksum || nv->id[0] != 'I' || nv->id[1] != 'S' || | 2225 | if (chksum || nv->id[0] != 'I' || nv->id[1] != 'S' || |
2235 | nv->id[2] != 'P' || nv->id[3] != ' ' || nv->nvram_version < 1) { | 2226 | nv->id[2] != 'P' || nv->id[3] != ' ' || nv->nvram_version < 1) { |
2236 | /* Reset NVRAM data. */ | 2227 | /* Reset NVRAM data. */ |
2237 | qla_printk(KERN_WARNING, ha, "Inconsistent NVRAM detected: " | 2228 | ql_log(ql_log_warn, vha, 0x0064, |
2238 | "checksum=0x%x id=%c version=0x%x.\n", chksum, nv->id[0], | 2229 | "Inconisistent NVRAM " |
2239 | nv->nvram_version); | 2230 | "detected: checksum=0x%x id=%c version=0x%x.\n", |
2240 | qla_printk(KERN_WARNING, ha, "Falling back to functioning (yet " | 2231 | chksum, nv->id[0], nv->nvram_version); |
2241 | "invalid -- WWPN) defaults.\n"); | 2232 | ql_log(ql_log_warn, vha, 0x0065, |
2233 | "Falling back to " | ||
2234 | "functioning (yet invalid -- WWPN) defaults.\n"); | ||
2242 | 2235 | ||
2243 | /* | 2236 | /* |
2244 | * Set default initialization control block. | 2237 | * Set default initialization control block. |
@@ -2493,10 +2486,7 @@ qla2x00_nvram_config(scsi_qla_host_t *vha) | |||
2493 | if (ha->zio_mode != QLA_ZIO_DISABLED) { | 2486 | if (ha->zio_mode != QLA_ZIO_DISABLED) { |
2494 | ha->zio_mode = QLA_ZIO_MODE_6; | 2487 | ha->zio_mode = QLA_ZIO_MODE_6; |
2495 | 2488 | ||
2496 | DEBUG2(printk("scsi(%ld): ZIO mode %d enabled; timer " | 2489 | ql_log(ql_log_info, vha, 0x0068, |
2497 | "delay (%d us).\n", vha->host_no, ha->zio_mode, | ||
2498 | ha->zio_timer * 100)); | ||
2499 | qla_printk(KERN_INFO, ha, | ||
2500 | "ZIO mode %d enabled; timer delay (%d us).\n", | 2490 | "ZIO mode %d enabled; timer delay (%d us).\n", |
2501 | ha->zio_mode, ha->zio_timer * 100); | 2491 | ha->zio_mode, ha->zio_timer * 100); |
2502 | 2492 | ||
@@ -2507,8 +2497,8 @@ qla2x00_nvram_config(scsi_qla_host_t *vha) | |||
2507 | } | 2497 | } |
2508 | 2498 | ||
2509 | if (rval) { | 2499 | if (rval) { |
2510 | DEBUG2_3(printk(KERN_WARNING | 2500 | ql_log(ql_log_warn, vha, 0x0069, |
2511 | "scsi(%ld): NVRAM configuration failed!\n", vha->host_no)); | 2501 | "NVRAM configuration failed.\n"); |
2512 | } | 2502 | } |
2513 | return (rval); | 2503 | return (rval); |
2514 | } | 2504 | } |
@@ -2579,15 +2569,15 @@ qla2x00_configure_loop(scsi_qla_host_t *vha) | |||
2579 | if (test_bit(LOCAL_LOOP_UPDATE, &vha->dpc_flags)) { | 2569 | if (test_bit(LOCAL_LOOP_UPDATE, &vha->dpc_flags)) { |
2580 | rval = qla2x00_configure_hba(vha); | 2570 | rval = qla2x00_configure_hba(vha); |
2581 | if (rval != QLA_SUCCESS) { | 2571 | if (rval != QLA_SUCCESS) { |
2582 | DEBUG(printk("scsi(%ld): Unable to configure HBA.\n", | 2572 | ql_dbg(ql_dbg_disc, vha, 0x2013, |
2583 | vha->host_no)); | 2573 | "Unable to configure HBA.\n"); |
2584 | return (rval); | 2574 | return (rval); |
2585 | } | 2575 | } |
2586 | } | 2576 | } |
2587 | 2577 | ||
2588 | save_flags = flags = vha->dpc_flags; | 2578 | save_flags = flags = vha->dpc_flags; |
2589 | DEBUG(printk("scsi(%ld): Configure loop -- dpc flags =0x%lx\n", | 2579 | ql_dbg(ql_dbg_disc, vha, 0x2014, |
2590 | vha->host_no, flags)); | 2580 | "Configure loop -- dpc flags = 0x%lx.\n", flags); |
2591 | 2581 | ||
2592 | /* | 2582 | /* |
2593 | * If we have both an RSCN and PORT UPDATE pending then handle them | 2583 | * If we have both an RSCN and PORT UPDATE pending then handle them |
@@ -2624,15 +2614,21 @@ qla2x00_configure_loop(scsi_qla_host_t *vha) | |||
2624 | } | 2614 | } |
2625 | 2615 | ||
2626 | if (test_bit(LOCAL_LOOP_UPDATE, &flags)) { | 2616 | if (test_bit(LOCAL_LOOP_UPDATE, &flags)) { |
2627 | if (test_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags)) | 2617 | if (test_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags)) { |
2618 | ql_dbg(ql_dbg_disc, vha, 0x2015, | ||
2619 | "Loop resync needed, failing.\n"); | ||
2628 | rval = QLA_FUNCTION_FAILED; | 2620 | rval = QLA_FUNCTION_FAILED; |
2621 | } | ||
2629 | else | 2622 | else |
2630 | rval = qla2x00_configure_local_loop(vha); | 2623 | rval = qla2x00_configure_local_loop(vha); |
2631 | } | 2624 | } |
2632 | 2625 | ||
2633 | if (rval == QLA_SUCCESS && test_bit(RSCN_UPDATE, &flags)) { | 2626 | if (rval == QLA_SUCCESS && test_bit(RSCN_UPDATE, &flags)) { |
2634 | if (LOOP_TRANSITION(vha)) | 2627 | if (LOOP_TRANSITION(vha)) { |
2628 | ql_dbg(ql_dbg_disc, vha, 0x201e, | ||
2629 | "Needs RSCN update and loop transition.\n"); | ||
2635 | rval = QLA_FUNCTION_FAILED; | 2630 | rval = QLA_FUNCTION_FAILED; |
2631 | } | ||
2636 | else | 2632 | else |
2637 | rval = qla2x00_configure_fabric(vha); | 2633 | rval = qla2x00_configure_fabric(vha); |
2638 | } | 2634 | } |
@@ -2643,16 +2639,17 @@ qla2x00_configure_loop(scsi_qla_host_t *vha) | |||
2643 | rval = QLA_FUNCTION_FAILED; | 2639 | rval = QLA_FUNCTION_FAILED; |
2644 | } else { | 2640 | } else { |
2645 | atomic_set(&vha->loop_state, LOOP_READY); | 2641 | atomic_set(&vha->loop_state, LOOP_READY); |
2646 | 2642 | ql_dbg(ql_dbg_disc, vha, 0x2069, | |
2647 | DEBUG(printk("scsi(%ld): LOOP READY\n", vha->host_no)); | 2643 | "LOOP READY.\n"); |
2648 | } | 2644 | } |
2649 | } | 2645 | } |
2650 | 2646 | ||
2651 | if (rval) { | 2647 | if (rval) { |
2652 | DEBUG2_3(printk("%s(%ld): *** FAILED ***\n", | 2648 | ql_dbg(ql_dbg_disc, vha, 0x206a, |
2653 | __func__, vha->host_no)); | 2649 | "%s *** FAILED ***.\n", __func__); |
2654 | } else { | 2650 | } else { |
2655 | DEBUG3(printk("%s: exiting normally\n", __func__)); | 2651 | ql_dbg(ql_dbg_disc, vha, 0x206b, |
2652 | "%s: exiting normally.\n", __func__); | ||
2656 | } | 2653 | } |
2657 | 2654 | ||
2658 | /* Restore state if a resync event occurred during processing */ | 2655 | /* Restore state if a resync event occurred during processing */ |
@@ -2700,8 +2697,10 @@ qla2x00_configure_local_loop(scsi_qla_host_t *vha) | |||
2700 | new_fcport = NULL; | 2697 | new_fcport = NULL; |
2701 | entries = MAX_FIBRE_DEVICES; | 2698 | entries = MAX_FIBRE_DEVICES; |
2702 | 2699 | ||
2703 | DEBUG3(printk("scsi(%ld): Getting FCAL position map\n", vha->host_no)); | 2700 | ql_dbg(ql_dbg_disc, vha, 0x2016, |
2704 | DEBUG3(qla2x00_get_fcal_position_map(vha, NULL)); | 2701 | "Getting FCAL position map.\n"); |
2702 | if (ql2xextended_error_logging & ql_dbg_disc) | ||
2703 | qla2x00_get_fcal_position_map(vha, NULL); | ||
2705 | 2704 | ||
2706 | /* Get list of logged in devices. */ | 2705 | /* Get list of logged in devices. */ |
2707 | memset(ha->gid_list, 0, GID_LIST_SIZE); | 2706 | memset(ha->gid_list, 0, GID_LIST_SIZE); |
@@ -2710,14 +2709,17 @@ qla2x00_configure_local_loop(scsi_qla_host_t *vha) | |||
2710 | if (rval != QLA_SUCCESS) | 2709 | if (rval != QLA_SUCCESS) |
2711 | goto cleanup_allocation; | 2710 | goto cleanup_allocation; |
2712 | 2711 | ||
2713 | DEBUG3(printk("scsi(%ld): Entries in ID list (%d)\n", | 2712 | ql_dbg(ql_dbg_disc, vha, 0x2017, |
2714 | vha->host_no, entries)); | 2713 | "Entries in ID list (%d).\n", entries); |
2715 | DEBUG3(qla2x00_dump_buffer((uint8_t *)ha->gid_list, | 2714 | ql_dump_buffer(ql_dbg_disc + ql_dbg_buffer, vha, 0x2075, |
2716 | entries * sizeof(struct gid_list_info))); | 2715 | (uint8_t *)ha->gid_list, |
2716 | entries * sizeof(struct gid_list_info)); | ||
2717 | 2717 | ||
2718 | /* Allocate temporary fcport for any new fcports discovered. */ | 2718 | /* Allocate temporary fcport for any new fcports discovered. */ |
2719 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); | 2719 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); |
2720 | if (new_fcport == NULL) { | 2720 | if (new_fcport == NULL) { |
2721 | ql_log(ql_log_warn, vha, 0x2018, | ||
2722 | "Memory allocation failed for fcport.\n"); | ||
2721 | rval = QLA_MEMORY_ALLOC_FAILED; | 2723 | rval = QLA_MEMORY_ALLOC_FAILED; |
2722 | goto cleanup_allocation; | 2724 | goto cleanup_allocation; |
2723 | } | 2725 | } |
@@ -2731,9 +2733,9 @@ qla2x00_configure_local_loop(scsi_qla_host_t *vha) | |||
2731 | fcport->port_type != FCT_BROADCAST && | 2733 | fcport->port_type != FCT_BROADCAST && |
2732 | (fcport->flags & FCF_FABRIC_DEVICE) == 0) { | 2734 | (fcport->flags & FCF_FABRIC_DEVICE) == 0) { |
2733 | 2735 | ||
2734 | DEBUG(printk("scsi(%ld): Marking port lost, " | 2736 | ql_dbg(ql_dbg_disc, vha, 0x2019, |
2735 | "loop_id=0x%04x\n", | 2737 | "Marking port lost loop_id=0x%04x.\n", |
2736 | vha->host_no, fcport->loop_id)); | 2738 | fcport->loop_id); |
2737 | 2739 | ||
2738 | qla2x00_set_fcport_state(fcport, FCS_DEVICE_LOST); | 2740 | qla2x00_set_fcport_state(fcport, FCS_DEVICE_LOST); |
2739 | } | 2741 | } |
@@ -2774,12 +2776,12 @@ qla2x00_configure_local_loop(scsi_qla_host_t *vha) | |||
2774 | new_fcport->vp_idx = vha->vp_idx; | 2776 | new_fcport->vp_idx = vha->vp_idx; |
2775 | rval2 = qla2x00_get_port_database(vha, new_fcport, 0); | 2777 | rval2 = qla2x00_get_port_database(vha, new_fcport, 0); |
2776 | if (rval2 != QLA_SUCCESS) { | 2778 | if (rval2 != QLA_SUCCESS) { |
2777 | DEBUG2(printk("scsi(%ld): Failed to retrieve fcport " | 2779 | ql_dbg(ql_dbg_disc, vha, 0x201a, |
2778 | "information -- get_port_database=%x, " | 2780 | "Failed to retrieve fcport information " |
2779 | "loop_id=0x%04x\n", | 2781 | "-- get_port_database=%x, loop_id=0x%04x.\n", |
2780 | vha->host_no, rval2, new_fcport->loop_id)); | 2782 | rval2, new_fcport->loop_id); |
2781 | DEBUG2(printk("scsi(%ld): Scheduling resync...\n", | 2783 | ql_dbg(ql_dbg_disc, vha, 0x201b, |
2782 | vha->host_no)); | 2784 | "Scheduling resync.\n"); |
2783 | set_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags); | 2785 | set_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags); |
2784 | continue; | 2786 | continue; |
2785 | } | 2787 | } |
@@ -2815,6 +2817,8 @@ qla2x00_configure_local_loop(scsi_qla_host_t *vha) | |||
2815 | fcport = new_fcport; | 2817 | fcport = new_fcport; |
2816 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); | 2818 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); |
2817 | if (new_fcport == NULL) { | 2819 | if (new_fcport == NULL) { |
2820 | ql_log(ql_log_warn, vha, 0x201c, | ||
2821 | "Failed to allocate memory for fcport.\n"); | ||
2818 | rval = QLA_MEMORY_ALLOC_FAILED; | 2822 | rval = QLA_MEMORY_ALLOC_FAILED; |
2819 | goto cleanup_allocation; | 2823 | goto cleanup_allocation; |
2820 | } | 2824 | } |
@@ -2833,8 +2837,8 @@ cleanup_allocation: | |||
2833 | kfree(new_fcport); | 2837 | kfree(new_fcport); |
2834 | 2838 | ||
2835 | if (rval != QLA_SUCCESS) { | 2839 | if (rval != QLA_SUCCESS) { |
2836 | DEBUG2(printk("scsi(%ld): Configure local loop error exit: " | 2840 | ql_dbg(ql_dbg_disc, vha, 0x201d, |
2837 | "rval=%x\n", vha->host_no, rval)); | 2841 | "Configure local loop error exit: rval=%x.\n", rval); |
2838 | } | 2842 | } |
2839 | 2843 | ||
2840 | return (rval); | 2844 | return (rval); |
@@ -2863,27 +2867,27 @@ qla2x00_iidma_fcport(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
2863 | rval = qla2x00_set_idma_speed(vha, fcport->loop_id, fcport->fp_speed, | 2867 | rval = qla2x00_set_idma_speed(vha, fcport->loop_id, fcport->fp_speed, |
2864 | mb); | 2868 | mb); |
2865 | if (rval != QLA_SUCCESS) { | 2869 | if (rval != QLA_SUCCESS) { |
2866 | DEBUG2(printk("scsi(%ld): Unable to adjust iIDMA " | 2870 | ql_dbg(ql_dbg_disc, vha, 0x2004, |
2867 | "%02x%02x%02x%02x%02x%02x%02x%02x -- %04x %x %04x %04x.\n", | 2871 | "Unable to adjust iIDMA " |
2868 | vha->host_no, fcport->port_name[0], fcport->port_name[1], | 2872 | "%02x%02x%02x%02x%02x%02x%02x%02x -- %04x %x %04x " |
2873 | "%04x.\n", fcport->port_name[0], fcport->port_name[1], | ||
2869 | fcport->port_name[2], fcport->port_name[3], | 2874 | fcport->port_name[2], fcport->port_name[3], |
2870 | fcport->port_name[4], fcport->port_name[5], | 2875 | fcport->port_name[4], fcport->port_name[5], |
2871 | fcport->port_name[6], fcport->port_name[7], rval, | 2876 | fcport->port_name[6], fcport->port_name[7], rval, |
2872 | fcport->fp_speed, mb[0], mb[1])); | 2877 | fcport->fp_speed, mb[0], mb[1]); |
2873 | } else { | 2878 | } else { |
2874 | link_speed = link_speeds[LS_UNKNOWN]; | 2879 | link_speed = link_speeds[LS_UNKNOWN]; |
2875 | if (fcport->fp_speed < 5) | 2880 | if (fcport->fp_speed < 5) |
2876 | link_speed = link_speeds[fcport->fp_speed]; | 2881 | link_speed = link_speeds[fcport->fp_speed]; |
2877 | else if (fcport->fp_speed == 0x13) | 2882 | else if (fcport->fp_speed == 0x13) |
2878 | link_speed = link_speeds[5]; | 2883 | link_speed = link_speeds[5]; |
2879 | DEBUG2(qla_printk(KERN_INFO, ha, | 2884 | ql_dbg(ql_dbg_disc, vha, 0x2005, |
2880 | "iIDMA adjusted to %s GB/s on " | 2885 | "iIDMA adjusted to %s GB/s " |
2881 | "%02x%02x%02x%02x%02x%02x%02x%02x.\n", | 2886 | "on %02x%02x%02x%02x%02x%02x%02x%02x.\n", link_speed, |
2882 | link_speed, fcport->port_name[0], | 2887 | fcport->port_name[0], fcport->port_name[1], |
2883 | fcport->port_name[1], fcport->port_name[2], | 2888 | fcport->port_name[2], fcport->port_name[3], |
2884 | fcport->port_name[3], fcport->port_name[4], | 2889 | fcport->port_name[4], fcport->port_name[5], |
2885 | fcport->port_name[5], fcport->port_name[6], | 2890 | fcport->port_name[6], fcport->port_name[7]); |
2886 | fcport->port_name[7])); | ||
2887 | } | 2891 | } |
2888 | } | 2892 | } |
2889 | 2893 | ||
@@ -2892,7 +2896,6 @@ qla2x00_reg_remote_port(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
2892 | { | 2896 | { |
2893 | struct fc_rport_identifiers rport_ids; | 2897 | struct fc_rport_identifiers rport_ids; |
2894 | struct fc_rport *rport; | 2898 | struct fc_rport *rport; |
2895 | struct qla_hw_data *ha = vha->hw; | ||
2896 | unsigned long flags; | 2899 | unsigned long flags; |
2897 | 2900 | ||
2898 | qla2x00_rport_del(fcport); | 2901 | qla2x00_rport_del(fcport); |
@@ -2904,8 +2907,8 @@ qla2x00_reg_remote_port(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
2904 | rport_ids.roles = FC_RPORT_ROLE_UNKNOWN; | 2907 | rport_ids.roles = FC_RPORT_ROLE_UNKNOWN; |
2905 | fcport->rport = rport = fc_remote_port_add(vha->host, 0, &rport_ids); | 2908 | fcport->rport = rport = fc_remote_port_add(vha->host, 0, &rport_ids); |
2906 | if (!rport) { | 2909 | if (!rport) { |
2907 | qla_printk(KERN_WARNING, ha, | 2910 | ql_log(ql_log_warn, vha, 0x2006, |
2908 | "Unable to allocate fc remote port!\n"); | 2911 | "Unable to allocate fc remote port.\n"); |
2909 | return; | 2912 | return; |
2910 | } | 2913 | } |
2911 | spin_lock_irqsave(fcport->vha->host->host_lock, flags); | 2914 | spin_lock_irqsave(fcport->vha->host->host_lock, flags); |
@@ -2980,8 +2983,8 @@ qla2x00_configure_fabric(scsi_qla_host_t *vha) | |||
2980 | loop_id = SNS_FL_PORT; | 2983 | loop_id = SNS_FL_PORT; |
2981 | rval = qla2x00_get_port_name(vha, loop_id, vha->fabric_node_name, 1); | 2984 | rval = qla2x00_get_port_name(vha, loop_id, vha->fabric_node_name, 1); |
2982 | if (rval != QLA_SUCCESS) { | 2985 | if (rval != QLA_SUCCESS) { |
2983 | DEBUG2(printk("scsi(%ld): MBC_GET_PORT_NAME Failed, No FL " | 2986 | ql_dbg(ql_dbg_disc, vha, 0x201f, |
2984 | "Port\n", vha->host_no)); | 2987 | "MBX_GET_PORT_NAME failed, No FL Port.\n"); |
2985 | 2988 | ||
2986 | vha->device_flags &= ~SWITCH_FOUND; | 2989 | vha->device_flags &= ~SWITCH_FOUND; |
2987 | return (QLA_SUCCESS); | 2990 | return (QLA_SUCCESS); |
@@ -3008,32 +3011,32 @@ qla2x00_configure_fabric(scsi_qla_host_t *vha) | |||
3008 | ha->isp_ops->fabric_login(vha, loop_id, 0xff, 0xff, | 3011 | ha->isp_ops->fabric_login(vha, loop_id, 0xff, 0xff, |
3009 | 0xfc, mb, BIT_1 | BIT_0); | 3012 | 0xfc, mb, BIT_1 | BIT_0); |
3010 | if (mb[0] != MBS_COMMAND_COMPLETE) { | 3013 | if (mb[0] != MBS_COMMAND_COMPLETE) { |
3011 | DEBUG2(qla_printk(KERN_INFO, ha, | 3014 | ql_dbg(ql_dbg_disc, vha, 0x2042, |
3012 | "Failed SNS login: loop_id=%x mb[0]=%x mb[1]=%x " | 3015 | "Failed SNS login: loop_id=%x mb[0]=%x mb[1]=%x mb[2]=%x " |
3013 | "mb[2]=%x mb[6]=%x mb[7]=%x\n", loop_id, | 3016 | "mb[6]=%x mb[7]=%x.\n", loop_id, mb[0], mb[1], |
3014 | mb[0], mb[1], mb[2], mb[6], mb[7])); | 3017 | mb[2], mb[6], mb[7]); |
3015 | return (QLA_SUCCESS); | 3018 | return (QLA_SUCCESS); |
3016 | } | 3019 | } |
3017 | 3020 | ||
3018 | if (test_and_clear_bit(REGISTER_FC4_NEEDED, &vha->dpc_flags)) { | 3021 | if (test_and_clear_bit(REGISTER_FC4_NEEDED, &vha->dpc_flags)) { |
3019 | if (qla2x00_rft_id(vha)) { | 3022 | if (qla2x00_rft_id(vha)) { |
3020 | /* EMPTY */ | 3023 | /* EMPTY */ |
3021 | DEBUG2(printk("scsi(%ld): Register FC-4 " | 3024 | ql_dbg(ql_dbg_disc, vha, 0x2045, |
3022 | "TYPE failed.\n", vha->host_no)); | 3025 | "Register FC-4 TYPE failed.\n"); |
3023 | } | 3026 | } |
3024 | if (qla2x00_rff_id(vha)) { | 3027 | if (qla2x00_rff_id(vha)) { |
3025 | /* EMPTY */ | 3028 | /* EMPTY */ |
3026 | DEBUG2(printk("scsi(%ld): Register FC-4 " | 3029 | ql_dbg(ql_dbg_disc, vha, 0x2049, |
3027 | "Features failed.\n", vha->host_no)); | 3030 | "Register FC-4 Features failed.\n"); |
3028 | } | 3031 | } |
3029 | if (qla2x00_rnn_id(vha)) { | 3032 | if (qla2x00_rnn_id(vha)) { |
3030 | /* EMPTY */ | 3033 | /* EMPTY */ |
3031 | DEBUG2(printk("scsi(%ld): Register Node Name " | 3034 | ql_dbg(ql_dbg_disc, vha, 0x204f, |
3032 | "failed.\n", vha->host_no)); | 3035 | "Register Node Name failed.\n"); |
3033 | } else if (qla2x00_rsnn_nn(vha)) { | 3036 | } else if (qla2x00_rsnn_nn(vha)) { |
3034 | /* EMPTY */ | 3037 | /* EMPTY */ |
3035 | DEBUG2(printk("scsi(%ld): Register Symbolic " | 3038 | ql_dbg(ql_dbg_disc, vha, 0x2053, |
3036 | "Node Name failed.\n", vha->host_no)); | 3039 | "Register Symobilic Node Name failed.\n"); |
3037 | } | 3040 | } |
3038 | } | 3041 | } |
3039 | 3042 | ||
@@ -3137,8 +3140,8 @@ qla2x00_configure_fabric(scsi_qla_host_t *vha) | |||
3137 | } | 3140 | } |
3138 | 3141 | ||
3139 | if (rval) { | 3142 | if (rval) { |
3140 | DEBUG2(printk("scsi(%ld): Configure fabric error exit: " | 3143 | ql_dbg(ql_dbg_disc, vha, 0x2068, |
3141 | "rval=%d\n", vha->host_no, rval)); | 3144 | "Configure fabric error exit rval=%d.\n", rval); |
3142 | } | 3145 | } |
3143 | 3146 | ||
3144 | return (rval); | 3147 | return (rval); |
@@ -3180,8 +3183,8 @@ qla2x00_find_all_fabric_devs(scsi_qla_host_t *vha, | |||
3180 | swl = kcalloc(MAX_FIBRE_DEVICES, sizeof(sw_info_t), GFP_KERNEL); | 3183 | swl = kcalloc(MAX_FIBRE_DEVICES, sizeof(sw_info_t), GFP_KERNEL); |
3181 | if (!swl) { | 3184 | if (!swl) { |
3182 | /*EMPTY*/ | 3185 | /*EMPTY*/ |
3183 | DEBUG2(printk("scsi(%ld): GID_PT allocations failed, fallback " | 3186 | ql_dbg(ql_dbg_disc, vha, 0x2054, |
3184 | "on GA_NXT\n", vha->host_no)); | 3187 | "GID_PT allocations failed, fallback on GA_NXT.\n"); |
3185 | } else { | 3188 | } else { |
3186 | if (qla2x00_gid_pt(vha, swl) != QLA_SUCCESS) { | 3189 | if (qla2x00_gid_pt(vha, swl) != QLA_SUCCESS) { |
3187 | kfree(swl); | 3190 | kfree(swl); |
@@ -3206,6 +3209,8 @@ qla2x00_find_all_fabric_devs(scsi_qla_host_t *vha, | |||
3206 | /* Allocate temporary fcport for any new fcports discovered. */ | 3209 | /* Allocate temporary fcport for any new fcports discovered. */ |
3207 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); | 3210 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); |
3208 | if (new_fcport == NULL) { | 3211 | if (new_fcport == NULL) { |
3212 | ql_log(ql_log_warn, vha, 0x205e, | ||
3213 | "Failed to allocate memory for fcport.\n"); | ||
3209 | kfree(swl); | 3214 | kfree(swl); |
3210 | return (QLA_MEMORY_ALLOC_FAILED); | 3215 | return (QLA_MEMORY_ALLOC_FAILED); |
3211 | } | 3216 | } |
@@ -3252,9 +3257,9 @@ qla2x00_find_all_fabric_devs(scsi_qla_host_t *vha, | |||
3252 | /* Send GA_NXT to the switch */ | 3257 | /* Send GA_NXT to the switch */ |
3253 | rval = qla2x00_ga_nxt(vha, new_fcport); | 3258 | rval = qla2x00_ga_nxt(vha, new_fcport); |
3254 | if (rval != QLA_SUCCESS) { | 3259 | if (rval != QLA_SUCCESS) { |
3255 | qla_printk(KERN_WARNING, ha, | 3260 | ql_log(ql_log_warn, vha, 0x2064, |
3256 | "SNS scan failed -- assuming zero-entry " | 3261 | "SNS scan failed -- assuming " |
3257 | "result...\n"); | 3262 | "zero-entry result.\n"); |
3258 | list_for_each_entry_safe(fcport, fcptemp, | 3263 | list_for_each_entry_safe(fcport, fcptemp, |
3259 | new_fcports, list) { | 3264 | new_fcports, list) { |
3260 | list_del(&fcport->list); | 3265 | list_del(&fcport->list); |
@@ -3270,9 +3275,11 @@ qla2x00_find_all_fabric_devs(scsi_qla_host_t *vha, | |||
3270 | wrap.b24 = new_fcport->d_id.b24; | 3275 | wrap.b24 = new_fcport->d_id.b24; |
3271 | first_dev = 0; | 3276 | first_dev = 0; |
3272 | } else if (new_fcport->d_id.b24 == wrap.b24) { | 3277 | } else if (new_fcport->d_id.b24 == wrap.b24) { |
3273 | DEBUG2(printk("scsi(%ld): device wrap (%02x%02x%02x)\n", | 3278 | ql_dbg(ql_dbg_disc, vha, 0x2065, |
3274 | vha->host_no, new_fcport->d_id.b.domain, | 3279 | "Device wrap (%02x%02x%02x).\n", |
3275 | new_fcport->d_id.b.area, new_fcport->d_id.b.al_pa)); | 3280 | new_fcport->d_id.b.domain, |
3281 | new_fcport->d_id.b.area, | ||
3282 | new_fcport->d_id.b.al_pa); | ||
3276 | break; | 3283 | break; |
3277 | } | 3284 | } |
3278 | 3285 | ||
@@ -3377,6 +3384,8 @@ qla2x00_find_all_fabric_devs(scsi_qla_host_t *vha, | |||
3377 | nxt_d_id.b24 = new_fcport->d_id.b24; | 3384 | nxt_d_id.b24 = new_fcport->d_id.b24; |
3378 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); | 3385 | new_fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL); |
3379 | if (new_fcport == NULL) { | 3386 | if (new_fcport == NULL) { |
3387 | ql_log(ql_log_warn, vha, 0x2066, | ||
3388 | "Memory allocation failed for fcport.\n"); | ||
3380 | kfree(swl); | 3389 | kfree(swl); |
3381 | return (QLA_MEMORY_ALLOC_FAILED); | 3390 | return (QLA_MEMORY_ALLOC_FAILED); |
3382 | } | 3391 | } |
@@ -3506,10 +3515,10 @@ qla2x00_device_resync(scsi_qla_host_t *vha) | |||
3506 | d_id.b.area = MSB(LSW(rscn_entry)); | 3515 | d_id.b.area = MSB(LSW(rscn_entry)); |
3507 | d_id.b.al_pa = LSB(LSW(rscn_entry)); | 3516 | d_id.b.al_pa = LSB(LSW(rscn_entry)); |
3508 | 3517 | ||
3509 | DEBUG(printk("scsi(%ld): RSCN queue entry[%d] = " | 3518 | ql_dbg(ql_dbg_disc, vha, 0x2020, |
3510 | "[%02x/%02x%02x%02x].\n", | 3519 | "RSCN queue entry[%d] = [%02x/%02x%02x%02x].\n", |
3511 | vha->host_no, vha->rscn_out_ptr, format, d_id.b.domain, | 3520 | vha->rscn_out_ptr, format, d_id.b.domain, d_id.b.area, |
3512 | d_id.b.area, d_id.b.al_pa)); | 3521 | d_id.b.al_pa); |
3513 | 3522 | ||
3514 | vha->rscn_out_ptr++; | 3523 | vha->rscn_out_ptr++; |
3515 | if (vha->rscn_out_ptr == MAX_RSCN_COUNT) | 3524 | if (vha->rscn_out_ptr == MAX_RSCN_COUNT) |
@@ -3525,17 +3534,17 @@ qla2x00_device_resync(scsi_qla_host_t *vha) | |||
3525 | if (rscn_entry != vha->rscn_queue[rscn_out_iter]) | 3534 | if (rscn_entry != vha->rscn_queue[rscn_out_iter]) |
3526 | break; | 3535 | break; |
3527 | 3536 | ||
3528 | DEBUG(printk("scsi(%ld): Skipping duplicate RSCN queue " | 3537 | ql_dbg(ql_dbg_disc, vha, 0x2021, |
3529 | "entry found at [%d].\n", vha->host_no, | 3538 | "Skipping duplicate RSCN queue entry found at " |
3530 | rscn_out_iter)); | 3539 | "[%d].\n", rscn_out_iter); |
3531 | 3540 | ||
3532 | vha->rscn_out_ptr = rscn_out_iter; | 3541 | vha->rscn_out_ptr = rscn_out_iter; |
3533 | } | 3542 | } |
3534 | 3543 | ||
3535 | /* Queue overflow, set switch default case. */ | 3544 | /* Queue overflow, set switch default case. */ |
3536 | if (vha->flags.rscn_queue_overflow) { | 3545 | if (vha->flags.rscn_queue_overflow) { |
3537 | DEBUG(printk("scsi(%ld): device_resync: rscn " | 3546 | ql_dbg(ql_dbg_disc, vha, 0x2022, |
3538 | "overflow.\n", vha->host_no)); | 3547 | "device_resync: rscn overflow.\n"); |
3539 | 3548 | ||
3540 | format = 3; | 3549 | format = 3; |
3541 | vha->flags.rscn_queue_overflow = 0; | 3550 | vha->flags.rscn_queue_overflow = 0; |
@@ -3664,10 +3673,11 @@ qla2x00_fabric_login(scsi_qla_host_t *vha, fc_port_t *fcport, | |||
3664 | tmp_loopid = 0; | 3673 | tmp_loopid = 0; |
3665 | 3674 | ||
3666 | for (;;) { | 3675 | for (;;) { |
3667 | DEBUG(printk("scsi(%ld): Trying Fabric Login w/loop id 0x%04x " | 3676 | ql_dbg(ql_dbg_disc, vha, 0x2000, |
3668 | "for port %02x%02x%02x.\n", | 3677 | "Trying Fabric Login w/loop id 0x%04x for port " |
3669 | vha->host_no, fcport->loop_id, fcport->d_id.b.domain, | 3678 | "%02x%02x%02x.\n", |
3670 | fcport->d_id.b.area, fcport->d_id.b.al_pa)); | 3679 | fcport->loop_id, fcport->d_id.b.domain, |
3680 | fcport->d_id.b.area, fcport->d_id.b.al_pa); | ||
3671 | 3681 | ||
3672 | /* Login fcport on switch. */ | 3682 | /* Login fcport on switch. */ |
3673 | ha->isp_ops->fabric_login(vha, fcport->loop_id, | 3683 | ha->isp_ops->fabric_login(vha, fcport->loop_id, |
@@ -3685,10 +3695,11 @@ qla2x00_fabric_login(scsi_qla_host_t *vha, fc_port_t *fcport, | |||
3685 | tmp_loopid = fcport->loop_id; | 3695 | tmp_loopid = fcport->loop_id; |
3686 | fcport->loop_id = mb[1]; | 3696 | fcport->loop_id = mb[1]; |
3687 | 3697 | ||
3688 | DEBUG(printk("Fabric Login: port in use - next " | 3698 | ql_dbg(ql_dbg_disc, vha, 0x2001, |
3689 | "loop id=0x%04x, port Id=%02x%02x%02x.\n", | 3699 | "Fabric Login: port in use - next loop " |
3700 | "id=0x%04x, port id= %02x%02x%02x.\n", | ||
3690 | fcport->loop_id, fcport->d_id.b.domain, | 3701 | fcport->loop_id, fcport->d_id.b.domain, |
3691 | fcport->d_id.b.area, fcport->d_id.b.al_pa)); | 3702 | fcport->d_id.b.area, fcport->d_id.b.al_pa); |
3692 | 3703 | ||
3693 | } else if (mb[0] == MBS_COMMAND_COMPLETE) { | 3704 | } else if (mb[0] == MBS_COMMAND_COMPLETE) { |
3694 | /* | 3705 | /* |
@@ -3749,11 +3760,11 @@ qla2x00_fabric_login(scsi_qla_host_t *vha, fc_port_t *fcport, | |||
3749 | /* | 3760 | /* |
3750 | * unrecoverable / not handled error | 3761 | * unrecoverable / not handled error |
3751 | */ | 3762 | */ |
3752 | DEBUG2(printk("%s(%ld): failed=%x port_id=%02x%02x%02x " | 3763 | ql_dbg(ql_dbg_disc, vha, 0x2002, |
3753 | "loop_id=%x jiffies=%lx.\n", | 3764 | "Failed=%x port_id=%02x%02x%02x loop_id=%x " |
3754 | __func__, vha->host_no, mb[0], | 3765 | "jiffies=%lx.\n", mb[0], fcport->d_id.b.domain, |
3755 | fcport->d_id.b.domain, fcport->d_id.b.area, | 3766 | fcport->d_id.b.area, fcport->d_id.b.al_pa, |
3756 | fcport->d_id.b.al_pa, fcport->loop_id, jiffies)); | 3767 | fcport->loop_id, jiffies); |
3757 | 3768 | ||
3758 | *next_loopid = fcport->loop_id; | 3769 | *next_loopid = fcport->loop_id; |
3759 | ha->isp_ops->fabric_logout(vha, fcport->loop_id, | 3770 | ha->isp_ops->fabric_logout(vha, fcport->loop_id, |
@@ -3857,7 +3868,8 @@ qla2x00_loop_resync(scsi_qla_host_t *vha) | |||
3857 | return (QLA_FUNCTION_FAILED); | 3868 | return (QLA_FUNCTION_FAILED); |
3858 | 3869 | ||
3859 | if (rval) | 3870 | if (rval) |
3860 | DEBUG2_3(printk("%s(): **** FAILED ****\n", __func__)); | 3871 | ql_dbg(ql_dbg_disc, vha, 0x206c, |
3872 | "%s *** FAILED ***.\n", __func__); | ||
3861 | 3873 | ||
3862 | return (rval); | 3874 | return (rval); |
3863 | } | 3875 | } |
@@ -3934,8 +3946,8 @@ qla82xx_quiescent_state_cleanup(scsi_qla_host_t *vha) | |||
3934 | struct qla_hw_data *ha = vha->hw; | 3946 | struct qla_hw_data *ha = vha->hw; |
3935 | struct scsi_qla_host *vp; | 3947 | struct scsi_qla_host *vp; |
3936 | 3948 | ||
3937 | qla_printk(KERN_INFO, ha, | 3949 | ql_dbg(ql_dbg_p3p, vha, 0xb002, |
3938 | "Performing ISP error recovery - ha= %p.\n", ha); | 3950 | "Performing ISP error recovery - ha=%p.\n", ha); |
3939 | 3951 | ||
3940 | atomic_set(&ha->loop_down_timer, LOOP_DOWN_TIME); | 3952 | atomic_set(&ha->loop_down_timer, LOOP_DOWN_TIME); |
3941 | if (atomic_read(&vha->loop_state) != LOOP_DOWN) { | 3953 | if (atomic_read(&vha->loop_state) != LOOP_DOWN) { |
@@ -3969,8 +3981,8 @@ qla2x00_abort_isp_cleanup(scsi_qla_host_t *vha) | |||
3969 | clear_bit(ISP_ABORT_NEEDED, &vha->dpc_flags); | 3981 | clear_bit(ISP_ABORT_NEEDED, &vha->dpc_flags); |
3970 | ha->qla_stats.total_isp_aborts++; | 3982 | ha->qla_stats.total_isp_aborts++; |
3971 | 3983 | ||
3972 | qla_printk(KERN_INFO, ha, | 3984 | ql_log(ql_log_info, vha, 0x00af, |
3973 | "Performing ISP error recovery - ha= %p.\n", ha); | 3985 | "Performing ISP error recovery - ha=%p.\n", ha); |
3974 | 3986 | ||
3975 | /* For ISP82XX, reset_chip is just disabling interrupts. | 3987 | /* For ISP82XX, reset_chip is just disabling interrupts. |
3976 | * Driver waits for the completion of the commands. | 3988 | * Driver waits for the completion of the commands. |
@@ -4021,6 +4033,8 @@ qla2x00_abort_isp_cleanup(scsi_qla_host_t *vha) | |||
4021 | /* Make sure for ISP 82XX IO DMA is complete */ | 4033 | /* Make sure for ISP 82XX IO DMA is complete */ |
4022 | if (IS_QLA82XX(ha)) { | 4034 | if (IS_QLA82XX(ha)) { |
4023 | qla82xx_chip_reset_cleanup(vha); | 4035 | qla82xx_chip_reset_cleanup(vha); |
4036 | ql_log(ql_log_info, vha, 0x00b4, | ||
4037 | "Done chip reset cleanup.\n"); | ||
4024 | 4038 | ||
4025 | /* Done waiting for pending commands. | 4039 | /* Done waiting for pending commands. |
4026 | * Reset the online flag. | 4040 | * Reset the online flag. |
@@ -4102,7 +4116,7 @@ qla2x00_abort_isp(scsi_qla_host_t *vha) | |||
4102 | ha->fce_dma, ha->fce_bufs, ha->fce_mb, | 4116 | ha->fce_dma, ha->fce_bufs, ha->fce_mb, |
4103 | &ha->fce_bufs); | 4117 | &ha->fce_bufs); |
4104 | if (rval) { | 4118 | if (rval) { |
4105 | qla_printk(KERN_WARNING, ha, | 4119 | ql_log(ql_log_warn, vha, 0x8033, |
4106 | "Unable to reinitialize FCE " | 4120 | "Unable to reinitialize FCE " |
4107 | "(%d).\n", rval); | 4121 | "(%d).\n", rval); |
4108 | ha->flags.fce_enabled = 0; | 4122 | ha->flags.fce_enabled = 0; |
@@ -4114,7 +4128,7 @@ qla2x00_abort_isp(scsi_qla_host_t *vha) | |||
4114 | rval = qla2x00_enable_eft_trace(vha, | 4128 | rval = qla2x00_enable_eft_trace(vha, |
4115 | ha->eft_dma, EFT_NUM_BUFFERS); | 4129 | ha->eft_dma, EFT_NUM_BUFFERS); |
4116 | if (rval) { | 4130 | if (rval) { |
4117 | qla_printk(KERN_WARNING, ha, | 4131 | ql_log(ql_log_warn, vha, 0x8034, |
4118 | "Unable to reinitialize EFT " | 4132 | "Unable to reinitialize EFT " |
4119 | "(%d).\n", rval); | 4133 | "(%d).\n", rval); |
4120 | } | 4134 | } |
@@ -4123,9 +4137,9 @@ qla2x00_abort_isp(scsi_qla_host_t *vha) | |||
4123 | vha->flags.online = 1; | 4137 | vha->flags.online = 1; |
4124 | if (test_bit(ISP_ABORT_RETRY, &vha->dpc_flags)) { | 4138 | if (test_bit(ISP_ABORT_RETRY, &vha->dpc_flags)) { |
4125 | if (ha->isp_abort_cnt == 0) { | 4139 | if (ha->isp_abort_cnt == 0) { |
4126 | qla_printk(KERN_WARNING, ha, | 4140 | ql_log(ql_log_fatal, vha, 0x8035, |
4127 | "ISP error recovery failed - " | 4141 | "ISP error recover failed - " |
4128 | "board disabled\n"); | 4142 | "board disabled.\n"); |
4129 | /* | 4143 | /* |
4130 | * The next call disables the board | 4144 | * The next call disables the board |
4131 | * completely. | 4145 | * completely. |
@@ -4137,16 +4151,16 @@ qla2x00_abort_isp(scsi_qla_host_t *vha) | |||
4137 | status = 0; | 4151 | status = 0; |
4138 | } else { /* schedule another ISP abort */ | 4152 | } else { /* schedule another ISP abort */ |
4139 | ha->isp_abort_cnt--; | 4153 | ha->isp_abort_cnt--; |
4140 | DEBUG(printk("qla%ld: ISP abort - " | 4154 | ql_dbg(ql_dbg_taskm, vha, 0x8020, |
4141 | "retry remaining %d\n", | 4155 | "ISP abort - retry remaining %d.\n", |
4142 | vha->host_no, ha->isp_abort_cnt)); | 4156 | ha->isp_abort_cnt); |
4143 | status = 1; | 4157 | status = 1; |
4144 | } | 4158 | } |
4145 | } else { | 4159 | } else { |
4146 | ha->isp_abort_cnt = MAX_RETRIES_OF_ISP_ABORT; | 4160 | ha->isp_abort_cnt = MAX_RETRIES_OF_ISP_ABORT; |
4147 | DEBUG(printk("qla2x00(%ld): ISP error recovery " | 4161 | ql_dbg(ql_dbg_taskm, vha, 0x8021, |
4148 | "- retrying (%d) more times\n", | 4162 | "ISP error recovery - retrying (%d) " |
4149 | vha->host_no, ha->isp_abort_cnt)); | 4163 | "more times.\n", ha->isp_abort_cnt); |
4150 | set_bit(ISP_ABORT_RETRY, &vha->dpc_flags); | 4164 | set_bit(ISP_ABORT_RETRY, &vha->dpc_flags); |
4151 | status = 1; | 4165 | status = 1; |
4152 | } | 4166 | } |
@@ -4155,9 +4169,7 @@ qla2x00_abort_isp(scsi_qla_host_t *vha) | |||
4155 | } | 4169 | } |
4156 | 4170 | ||
4157 | if (!status) { | 4171 | if (!status) { |
4158 | DEBUG(printk(KERN_INFO | 4172 | ql_dbg(ql_dbg_taskm, vha, 0x8022, "%s succeeded.\n", __func__); |
4159 | "qla2x00_abort_isp(%ld): succeeded.\n", | ||
4160 | vha->host_no)); | ||
4161 | 4173 | ||
4162 | spin_lock_irqsave(&ha->vport_slock, flags); | 4174 | spin_lock_irqsave(&ha->vport_slock, flags); |
4163 | list_for_each_entry(vp, &ha->vp_list, list) { | 4175 | list_for_each_entry(vp, &ha->vp_list, list) { |
@@ -4174,8 +4186,7 @@ qla2x00_abort_isp(scsi_qla_host_t *vha) | |||
4174 | spin_unlock_irqrestore(&ha->vport_slock, flags); | 4186 | spin_unlock_irqrestore(&ha->vport_slock, flags); |
4175 | 4187 | ||
4176 | } else { | 4188 | } else { |
4177 | qla_printk(KERN_INFO, ha, | 4189 | ql_log(ql_log_warn, vha, 0x8023, "%s **** FAILED ****.\n"); |
4178 | "qla2x00_abort_isp: **** FAILED ****\n"); | ||
4179 | } | 4190 | } |
4180 | 4191 | ||
4181 | return(status); | 4192 | return(status); |
@@ -4216,8 +4227,8 @@ qla2x00_restart_isp(scsi_qla_host_t *vha) | |||
4216 | 4227 | ||
4217 | status = qla2x00_fw_ready(vha); | 4228 | status = qla2x00_fw_ready(vha); |
4218 | if (!status) { | 4229 | if (!status) { |
4219 | DEBUG(printk("%s(): Start configure loop, " | 4230 | ql_dbg(ql_dbg_taskm, vha, 0x8031, |
4220 | "status = %d\n", __func__, status)); | 4231 | "Start configure loop status = %d.\n", status); |
4221 | 4232 | ||
4222 | /* Issue a marker after FW becomes ready. */ | 4233 | /* Issue a marker after FW becomes ready. */ |
4223 | qla2x00_marker(vha, req, rsp, 0, 0, MK_SYNC_ALL); | 4234 | qla2x00_marker(vha, req, rsp, 0, 0, MK_SYNC_ALL); |
@@ -4239,9 +4250,8 @@ qla2x00_restart_isp(scsi_qla_host_t *vha) | |||
4239 | if ((vha->device_flags & DFLG_NO_CABLE)) | 4250 | if ((vha->device_flags & DFLG_NO_CABLE)) |
4240 | status = 0; | 4251 | status = 0; |
4241 | 4252 | ||
4242 | DEBUG(printk("%s(): Configure loop done, status = 0x%x\n", | 4253 | ql_dbg(ql_dbg_taskm, vha, 0x8032, |
4243 | __func__, | 4254 | "Configure loop done, status = 0x%x.\n", status); |
4244 | status)); | ||
4245 | } | 4255 | } |
4246 | return (status); | 4256 | return (status); |
4247 | } | 4257 | } |
@@ -4261,13 +4271,13 @@ qla25xx_init_queues(struct qla_hw_data *ha) | |||
4261 | rsp->options &= ~BIT_0; | 4271 | rsp->options &= ~BIT_0; |
4262 | ret = qla25xx_init_rsp_que(base_vha, rsp); | 4272 | ret = qla25xx_init_rsp_que(base_vha, rsp); |
4263 | if (ret != QLA_SUCCESS) | 4273 | if (ret != QLA_SUCCESS) |
4264 | DEBUG2_17(printk(KERN_WARNING | 4274 | ql_dbg(ql_dbg_init, base_vha, 0x00ff, |
4265 | "%s Rsp que:%d init failed\n", __func__, | 4275 | "%s Rsp que: %d init failed.\n", |
4266 | rsp->id)); | 4276 | __func__, rsp->id); |
4267 | else | 4277 | else |
4268 | DEBUG2_17(printk(KERN_INFO | 4278 | ql_dbg(ql_dbg_init, base_vha, 0x0100, |
4269 | "%s Rsp que:%d inited\n", __func__, | 4279 | "%s Rsp que: %d inited.\n", |
4270 | rsp->id)); | 4280 | __func__, rsp->id); |
4271 | } | 4281 | } |
4272 | } | 4282 | } |
4273 | for (i = 1; i < ha->max_req_queues; i++) { | 4283 | for (i = 1; i < ha->max_req_queues; i++) { |
@@ -4277,13 +4287,13 @@ qla25xx_init_queues(struct qla_hw_data *ha) | |||
4277 | req->options &= ~BIT_0; | 4287 | req->options &= ~BIT_0; |
4278 | ret = qla25xx_init_req_que(base_vha, req); | 4288 | ret = qla25xx_init_req_que(base_vha, req); |
4279 | if (ret != QLA_SUCCESS) | 4289 | if (ret != QLA_SUCCESS) |
4280 | DEBUG2_17(printk(KERN_WARNING | 4290 | ql_dbg(ql_dbg_init, base_vha, 0x0101, |
4281 | "%s Req que:%d init failed\n", __func__, | 4291 | "%s Req que: %d init failed.\n", |
4282 | req->id)); | 4292 | __func__, req->id); |
4283 | else | 4293 | else |
4284 | DEBUG2_17(printk(KERN_WARNING | 4294 | ql_dbg(ql_dbg_init, base_vha, 0x0102, |
4285 | "%s Req que:%d inited\n", __func__, | 4295 | "%s Req que: %d inited.\n", |
4286 | req->id)); | 4296 | __func__, req->id); |
4287 | } | 4297 | } |
4288 | } | 4298 | } |
4289 | return ret; | 4299 | return ret; |
@@ -4402,19 +4412,22 @@ qla24xx_nvram_config(scsi_qla_host_t *vha) | |||
4402 | for (cnt = 0, chksum = 0; cnt < ha->nvram_size >> 2; cnt++) | 4412 | for (cnt = 0, chksum = 0; cnt < ha->nvram_size >> 2; cnt++) |
4403 | chksum += le32_to_cpu(*dptr++); | 4413 | chksum += le32_to_cpu(*dptr++); |
4404 | 4414 | ||
4405 | DEBUG5(printk("scsi(%ld): Contents of NVRAM\n", vha->host_no)); | 4415 | ql_dbg(ql_dbg_init + ql_dbg_buffer, vha, 0x006a, |
4406 | DEBUG5(qla2x00_dump_buffer((uint8_t *)nv, ha->nvram_size)); | 4416 | "Contents of NVRAM\n"); |
4417 | ql_dump_buffer(ql_dbg_init + ql_dbg_buffer, vha, 0x010d, | ||
4418 | (uint8_t *)nv, ha->nvram_size); | ||
4407 | 4419 | ||
4408 | /* Bad NVRAM data, set defaults parameters. */ | 4420 | /* Bad NVRAM data, set defaults parameters. */ |
4409 | if (chksum || nv->id[0] != 'I' || nv->id[1] != 'S' || nv->id[2] != 'P' | 4421 | if (chksum || nv->id[0] != 'I' || nv->id[1] != 'S' || nv->id[2] != 'P' |
4410 | || nv->id[3] != ' ' || | 4422 | || nv->id[3] != ' ' || |
4411 | nv->nvram_version < __constant_cpu_to_le16(ICB_VERSION)) { | 4423 | nv->nvram_version < __constant_cpu_to_le16(ICB_VERSION)) { |
4412 | /* Reset NVRAM data. */ | 4424 | /* Reset NVRAM data. */ |
4413 | qla_printk(KERN_WARNING, ha, "Inconsistent NVRAM detected: " | 4425 | ql_log(ql_log_warn, vha, 0x006b, |
4414 | "checksum=0x%x id=%c version=0x%x.\n", chksum, nv->id[0], | 4426 | "Inconisistent NVRAM detected: checksum=0x%x id=%c " |
4415 | le16_to_cpu(nv->nvram_version)); | 4427 | "version=0x%x.\n", chksum, nv->id[0], nv->nvram_version); |
4416 | qla_printk(KERN_WARNING, ha, "Falling back to functioning (yet " | 4428 | ql_log(ql_log_warn, vha, 0x006c, |
4417 | "invalid -- WWPN) defaults.\n"); | 4429 | "Falling back to functioning (yet invalid -- WWPN) " |
4430 | "defaults.\n"); | ||
4418 | 4431 | ||
4419 | /* | 4432 | /* |
4420 | * Set default initialization control block. | 4433 | * Set default initialization control block. |
@@ -4592,10 +4605,7 @@ qla24xx_nvram_config(scsi_qla_host_t *vha) | |||
4592 | if (ha->zio_mode != QLA_ZIO_DISABLED) { | 4605 | if (ha->zio_mode != QLA_ZIO_DISABLED) { |
4593 | ha->zio_mode = QLA_ZIO_MODE_6; | 4606 | ha->zio_mode = QLA_ZIO_MODE_6; |
4594 | 4607 | ||
4595 | DEBUG2(printk("scsi(%ld): ZIO mode %d enabled; timer delay " | 4608 | ql_log(ql_log_info, vha, 0x006f, |
4596 | "(%d us).\n", vha->host_no, ha->zio_mode, | ||
4597 | ha->zio_timer * 100)); | ||
4598 | qla_printk(KERN_INFO, ha, | ||
4599 | "ZIO mode %d enabled; timer delay (%d us).\n", | 4609 | "ZIO mode %d enabled; timer delay (%d us).\n", |
4600 | ha->zio_mode, ha->zio_timer * 100); | 4610 | ha->zio_mode, ha->zio_timer * 100); |
4601 | 4611 | ||
@@ -4606,8 +4616,8 @@ qla24xx_nvram_config(scsi_qla_host_t *vha) | |||
4606 | } | 4616 | } |
4607 | 4617 | ||
4608 | if (rval) { | 4618 | if (rval) { |
4609 | DEBUG2_3(printk(KERN_WARNING | 4619 | ql_log(ql_log_warn, vha, 0x0070, |
4610 | "scsi(%ld): NVRAM configuration failed!\n", vha->host_no)); | 4620 | "NVRAM configuration failed.\n"); |
4611 | } | 4621 | } |
4612 | return (rval); | 4622 | return (rval); |
4613 | } | 4623 | } |
@@ -4625,8 +4635,8 @@ qla24xx_load_risc_flash(scsi_qla_host_t *vha, uint32_t *srisc_addr, | |||
4625 | struct qla_hw_data *ha = vha->hw; | 4635 | struct qla_hw_data *ha = vha->hw; |
4626 | struct req_que *req = ha->req_q_map[0]; | 4636 | struct req_que *req = ha->req_q_map[0]; |
4627 | 4637 | ||
4628 | qla_printk(KERN_INFO, ha, | 4638 | ql_dbg(ql_dbg_init, vha, 0x008b, |
4629 | "FW: Loading from flash (%x)...\n", faddr); | 4639 | "Loading firmware from flash (%x).\n", faddr); |
4630 | 4640 | ||
4631 | rval = QLA_SUCCESS; | 4641 | rval = QLA_SUCCESS; |
4632 | 4642 | ||
@@ -4642,11 +4652,12 @@ qla24xx_load_risc_flash(scsi_qla_host_t *vha, uint32_t *srisc_addr, | |||
4642 | dcode[2] == 0xffffffff && dcode[3] == 0xffffffff) || | 4652 | dcode[2] == 0xffffffff && dcode[3] == 0xffffffff) || |
4643 | (dcode[0] == 0 && dcode[1] == 0 && dcode[2] == 0 && | 4653 | (dcode[0] == 0 && dcode[1] == 0 && dcode[2] == 0 && |
4644 | dcode[3] == 0)) { | 4654 | dcode[3] == 0)) { |
4645 | qla_printk(KERN_WARNING, ha, | 4655 | ql_log(ql_log_fatal, vha, 0x008c, |
4646 | "Unable to verify integrity of flash firmware image!\n"); | 4656 | "Unable to verify the integrity of flash firmware " |
4647 | qla_printk(KERN_WARNING, ha, | 4657 | "image.\n"); |
4648 | "Firmware data: %08x %08x %08x %08x!\n", dcode[0], | 4658 | ql_log(ql_log_fatal, vha, 0x008d, |
4649 | dcode[1], dcode[2], dcode[3]); | 4659 | "Firmware data: %08x %08x %08x %08x.\n", |
4660 | dcode[0], dcode[1], dcode[2], dcode[3]); | ||
4650 | 4661 | ||
4651 | return QLA_FUNCTION_FAILED; | 4662 | return QLA_FUNCTION_FAILED; |
4652 | } | 4663 | } |
@@ -4665,9 +4676,10 @@ qla24xx_load_risc_flash(scsi_qla_host_t *vha, uint32_t *srisc_addr, | |||
4665 | if (dlen > risc_size) | 4676 | if (dlen > risc_size) |
4666 | dlen = risc_size; | 4677 | dlen = risc_size; |
4667 | 4678 | ||
4668 | DEBUG7(printk("scsi(%ld): Loading risc segment@ risc " | 4679 | ql_dbg(ql_dbg_init, vha, 0x008e, |
4669 | "addr %x, number of dwords 0x%x, offset 0x%x.\n", | 4680 | "Loading risc segment@ risc addr %x " |
4670 | vha->host_no, risc_addr, dlen, faddr)); | 4681 | "number of dwords 0x%x offset 0x%x.\n", |
4682 | risc_addr, dlen, faddr); | ||
4671 | 4683 | ||
4672 | qla24xx_read_flash_data(vha, dcode, faddr, dlen); | 4684 | qla24xx_read_flash_data(vha, dcode, faddr, dlen); |
4673 | for (i = 0; i < dlen; i++) | 4685 | for (i = 0; i < dlen; i++) |
@@ -4676,12 +4688,9 @@ qla24xx_load_risc_flash(scsi_qla_host_t *vha, uint32_t *srisc_addr, | |||
4676 | rval = qla2x00_load_ram(vha, req->dma, risc_addr, | 4688 | rval = qla2x00_load_ram(vha, req->dma, risc_addr, |
4677 | dlen); | 4689 | dlen); |
4678 | if (rval) { | 4690 | if (rval) { |
4679 | DEBUG(printk("scsi(%ld):[ERROR] Failed to load " | 4691 | ql_log(ql_log_fatal, vha, 0x008f, |
4680 | "segment %d of firmware\n", vha->host_no, | 4692 | "Failed to load segment %d of firmware.\n", |
4681 | fragment)); | 4693 | fragment); |
4682 | qla_printk(KERN_WARNING, ha, | ||
4683 | "[ERROR] Failed to load segment %d of " | ||
4684 | "firmware\n", fragment); | ||
4685 | break; | 4694 | break; |
4686 | } | 4695 | } |
4687 | 4696 | ||
@@ -4714,9 +4723,10 @@ qla2x00_load_risc(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4714 | /* Load firmware blob. */ | 4723 | /* Load firmware blob. */ |
4715 | blob = qla2x00_request_firmware(vha); | 4724 | blob = qla2x00_request_firmware(vha); |
4716 | if (!blob) { | 4725 | if (!blob) { |
4717 | qla_printk(KERN_ERR, ha, "Firmware image unavailable.\n"); | 4726 | ql_log(ql_log_info, vha, 0x0083, |
4718 | qla_printk(KERN_ERR, ha, "Firmware images can be retrieved " | 4727 | "Fimware image unavailable.\n"); |
4719 | "from: " QLA_FW_URL ".\n"); | 4728 | ql_log(ql_log_info, vha, 0x0084, |
4729 | "Firmware images can be retrieved from: "QLA_FW_URL ".\n"); | ||
4720 | return QLA_FUNCTION_FAILED; | 4730 | return QLA_FUNCTION_FAILED; |
4721 | } | 4731 | } |
4722 | 4732 | ||
@@ -4729,8 +4739,8 @@ qla2x00_load_risc(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4729 | 4739 | ||
4730 | /* Validate firmware image by checking version. */ | 4740 | /* Validate firmware image by checking version. */ |
4731 | if (blob->fw->size < 8 * sizeof(uint16_t)) { | 4741 | if (blob->fw->size < 8 * sizeof(uint16_t)) { |
4732 | qla_printk(KERN_WARNING, ha, | 4742 | ql_log(ql_log_fatal, vha, 0x0085, |
4733 | "Unable to verify integrity of firmware image (%Zd)!\n", | 4743 | "Unable to verify integrity of firmware image (%Zd).\n", |
4734 | blob->fw->size); | 4744 | blob->fw->size); |
4735 | goto fail_fw_integrity; | 4745 | goto fail_fw_integrity; |
4736 | } | 4746 | } |
@@ -4739,11 +4749,11 @@ qla2x00_load_risc(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4739 | if ((wcode[0] == 0xffff && wcode[1] == 0xffff && wcode[2] == 0xffff && | 4749 | if ((wcode[0] == 0xffff && wcode[1] == 0xffff && wcode[2] == 0xffff && |
4740 | wcode[3] == 0xffff) || (wcode[0] == 0 && wcode[1] == 0 && | 4750 | wcode[3] == 0xffff) || (wcode[0] == 0 && wcode[1] == 0 && |
4741 | wcode[2] == 0 && wcode[3] == 0)) { | 4751 | wcode[2] == 0 && wcode[3] == 0)) { |
4742 | qla_printk(KERN_WARNING, ha, | 4752 | ql_log(ql_log_fatal, vha, 0x0086, |
4743 | "Unable to verify integrity of firmware image!\n"); | 4753 | "Unable to verify integrity of firmware image.\n"); |
4744 | qla_printk(KERN_WARNING, ha, | 4754 | ql_log(ql_log_fatal, vha, 0x0087, |
4745 | "Firmware data: %04x %04x %04x %04x!\n", wcode[0], | 4755 | "Firmware data: %04x %04x %04x %04x.\n", |
4746 | wcode[1], wcode[2], wcode[3]); | 4756 | wcode[0], wcode[1], wcode[2], wcode[3]); |
4747 | goto fail_fw_integrity; | 4757 | goto fail_fw_integrity; |
4748 | } | 4758 | } |
4749 | 4759 | ||
@@ -4756,9 +4766,9 @@ qla2x00_load_risc(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4756 | /* Validate firmware image size. */ | 4766 | /* Validate firmware image size. */ |
4757 | fwclen += risc_size * sizeof(uint16_t); | 4767 | fwclen += risc_size * sizeof(uint16_t); |
4758 | if (blob->fw->size < fwclen) { | 4768 | if (blob->fw->size < fwclen) { |
4759 | qla_printk(KERN_WARNING, ha, | 4769 | ql_log(ql_log_fatal, vha, 0x0088, |
4760 | "Unable to verify integrity of firmware image " | 4770 | "Unable to verify integrity of firmware image " |
4761 | "(%Zd)!\n", blob->fw->size); | 4771 | "(%Zd).\n", blob->fw->size); |
4762 | goto fail_fw_integrity; | 4772 | goto fail_fw_integrity; |
4763 | } | 4773 | } |
4764 | 4774 | ||
@@ -4767,10 +4777,9 @@ qla2x00_load_risc(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4767 | wlen = (uint16_t)(ha->fw_transfer_size >> 1); | 4777 | wlen = (uint16_t)(ha->fw_transfer_size >> 1); |
4768 | if (wlen > risc_size) | 4778 | if (wlen > risc_size) |
4769 | wlen = risc_size; | 4779 | wlen = risc_size; |
4770 | 4780 | ql_dbg(ql_dbg_init, vha, 0x0089, | |
4771 | DEBUG7(printk("scsi(%ld): Loading risc segment@ risc " | 4781 | "Loading risc segment@ risc addr %x number of " |
4772 | "addr %x, number of words 0x%x.\n", vha->host_no, | 4782 | "words 0x%x.\n", risc_addr, wlen); |
4773 | risc_addr, wlen)); | ||
4774 | 4783 | ||
4775 | for (i = 0; i < wlen; i++) | 4784 | for (i = 0; i < wlen; i++) |
4776 | wcode[i] = swab16(fwcode[i]); | 4785 | wcode[i] = swab16(fwcode[i]); |
@@ -4778,12 +4787,9 @@ qla2x00_load_risc(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4778 | rval = qla2x00_load_ram(vha, req->dma, risc_addr, | 4787 | rval = qla2x00_load_ram(vha, req->dma, risc_addr, |
4779 | wlen); | 4788 | wlen); |
4780 | if (rval) { | 4789 | if (rval) { |
4781 | DEBUG(printk("scsi(%ld):[ERROR] Failed to load " | 4790 | ql_log(ql_log_fatal, vha, 0x008a, |
4782 | "segment %d of firmware\n", vha->host_no, | 4791 | "Failed to load segment %d of firmware.\n", |
4783 | fragment)); | 4792 | fragment); |
4784 | qla_printk(KERN_WARNING, ha, | ||
4785 | "[ERROR] Failed to load segment %d of " | ||
4786 | "firmware\n", fragment); | ||
4787 | break; | 4793 | break; |
4788 | } | 4794 | } |
4789 | 4795 | ||
@@ -4819,15 +4825,17 @@ qla24xx_load_risc_blob(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4819 | /* Load firmware blob. */ | 4825 | /* Load firmware blob. */ |
4820 | blob = qla2x00_request_firmware(vha); | 4826 | blob = qla2x00_request_firmware(vha); |
4821 | if (!blob) { | 4827 | if (!blob) { |
4822 | qla_printk(KERN_ERR, ha, "Firmware image unavailable.\n"); | 4828 | ql_log(ql_log_warn, vha, 0x0090, |
4823 | qla_printk(KERN_ERR, ha, "Firmware images can be retrieved " | 4829 | "Fimware image unavailable.\n"); |
4824 | "from: " QLA_FW_URL ".\n"); | 4830 | ql_log(ql_log_warn, vha, 0x0091, |
4831 | "Firmware images can be retrieved from: " | ||
4832 | QLA_FW_URL ".\n"); | ||
4825 | 4833 | ||
4826 | return QLA_FUNCTION_FAILED; | 4834 | return QLA_FUNCTION_FAILED; |
4827 | } | 4835 | } |
4828 | 4836 | ||
4829 | qla_printk(KERN_INFO, ha, | 4837 | ql_log(ql_log_info, vha, 0x0092, |
4830 | "FW: Loading via request-firmware...\n"); | 4838 | "Loading via request-firmware.\n"); |
4831 | 4839 | ||
4832 | rval = QLA_SUCCESS; | 4840 | rval = QLA_SUCCESS; |
4833 | 4841 | ||
@@ -4839,8 +4847,8 @@ qla24xx_load_risc_blob(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4839 | 4847 | ||
4840 | /* Validate firmware image by checking version. */ | 4848 | /* Validate firmware image by checking version. */ |
4841 | if (blob->fw->size < 8 * sizeof(uint32_t)) { | 4849 | if (blob->fw->size < 8 * sizeof(uint32_t)) { |
4842 | qla_printk(KERN_WARNING, ha, | 4850 | ql_log(ql_log_fatal, vha, 0x0093, |
4843 | "Unable to verify integrity of firmware image (%Zd)!\n", | 4851 | "Unable to verify integrity of firmware image (%Zd).\n", |
4844 | blob->fw->size); | 4852 | blob->fw->size); |
4845 | goto fail_fw_integrity; | 4853 | goto fail_fw_integrity; |
4846 | } | 4854 | } |
@@ -4850,11 +4858,12 @@ qla24xx_load_risc_blob(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4850 | dcode[2] == 0xffffffff && dcode[3] == 0xffffffff) || | 4858 | dcode[2] == 0xffffffff && dcode[3] == 0xffffffff) || |
4851 | (dcode[0] == 0 && dcode[1] == 0 && dcode[2] == 0 && | 4859 | (dcode[0] == 0 && dcode[1] == 0 && dcode[2] == 0 && |
4852 | dcode[3] == 0)) { | 4860 | dcode[3] == 0)) { |
4853 | qla_printk(KERN_WARNING, ha, | 4861 | ql_log(ql_log_fatal, vha, 0x0094, |
4854 | "Unable to verify integrity of firmware image!\n"); | 4862 | "Unable to verify integrity of firmware image (%Zd).\n", |
4855 | qla_printk(KERN_WARNING, ha, | 4863 | blob->fw->size); |
4856 | "Firmware data: %08x %08x %08x %08x!\n", dcode[0], | 4864 | ql_log(ql_log_fatal, vha, 0x0095, |
4857 | dcode[1], dcode[2], dcode[3]); | 4865 | "Firmware data: %08x %08x %08x %08x.\n", |
4866 | dcode[0], dcode[1], dcode[2], dcode[3]); | ||
4858 | goto fail_fw_integrity; | 4867 | goto fail_fw_integrity; |
4859 | } | 4868 | } |
4860 | 4869 | ||
@@ -4866,9 +4875,9 @@ qla24xx_load_risc_blob(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4866 | /* Validate firmware image size. */ | 4875 | /* Validate firmware image size. */ |
4867 | fwclen += risc_size * sizeof(uint32_t); | 4876 | fwclen += risc_size * sizeof(uint32_t); |
4868 | if (blob->fw->size < fwclen) { | 4877 | if (blob->fw->size < fwclen) { |
4869 | qla_printk(KERN_WARNING, ha, | 4878 | ql_log(ql_log_fatal, vha, 0x0096, |
4870 | "Unable to verify integrity of firmware image " | 4879 | "Unable to verify integrity of firmware image " |
4871 | "(%Zd)!\n", blob->fw->size); | 4880 | "(%Zd).\n", blob->fw->size); |
4872 | 4881 | ||
4873 | goto fail_fw_integrity; | 4882 | goto fail_fw_integrity; |
4874 | } | 4883 | } |
@@ -4879,9 +4888,9 @@ qla24xx_load_risc_blob(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4879 | if (dlen > risc_size) | 4888 | if (dlen > risc_size) |
4880 | dlen = risc_size; | 4889 | dlen = risc_size; |
4881 | 4890 | ||
4882 | DEBUG7(printk("scsi(%ld): Loading risc segment@ risc " | 4891 | ql_dbg(ql_dbg_init, vha, 0x0097, |
4883 | "addr %x, number of dwords 0x%x.\n", vha->host_no, | 4892 | "Loading risc segment@ risc addr %x " |
4884 | risc_addr, dlen)); | 4893 | "number of dwords 0x%x.\n", risc_addr, dlen); |
4885 | 4894 | ||
4886 | for (i = 0; i < dlen; i++) | 4895 | for (i = 0; i < dlen; i++) |
4887 | dcode[i] = swab32(fwcode[i]); | 4896 | dcode[i] = swab32(fwcode[i]); |
@@ -4889,12 +4898,9 @@ qla24xx_load_risc_blob(scsi_qla_host_t *vha, uint32_t *srisc_addr) | |||
4889 | rval = qla2x00_load_ram(vha, req->dma, risc_addr, | 4898 | rval = qla2x00_load_ram(vha, req->dma, risc_addr, |
4890 | dlen); | 4899 | dlen); |
4891 | if (rval) { | 4900 | if (rval) { |
4892 | DEBUG(printk("scsi(%ld):[ERROR] Failed to load " | 4901 | ql_log(ql_log_fatal, vha, 0x0098, |
4893 | "segment %d of firmware\n", vha->host_no, | 4902 | "Failed to load segment %d of firmware.\n", |
4894 | fragment)); | 4903 | fragment); |
4895 | qla_printk(KERN_WARNING, ha, | ||
4896 | "[ERROR] Failed to load segment %d of " | ||
4897 | "firmware\n", fragment); | ||
4898 | break; | 4904 | break; |
4899 | } | 4905 | } |
4900 | 4906 | ||
@@ -4958,14 +4964,13 @@ try_blob_fw: | |||
4958 | if (rval == QLA_SUCCESS || !ha->flt_region_gold_fw) | 4964 | if (rval == QLA_SUCCESS || !ha->flt_region_gold_fw) |
4959 | return rval; | 4965 | return rval; |
4960 | 4966 | ||
4961 | qla_printk(KERN_ERR, ha, | 4967 | ql_log(ql_log_info, vha, 0x0099, |
4962 | "FW: Attempting to fallback to golden firmware...\n"); | 4968 | "Attempting to fallback to golden firmware.\n"); |
4963 | rval = qla24xx_load_risc_flash(vha, srisc_addr, ha->flt_region_gold_fw); | 4969 | rval = qla24xx_load_risc_flash(vha, srisc_addr, ha->flt_region_gold_fw); |
4964 | if (rval != QLA_SUCCESS) | 4970 | if (rval != QLA_SUCCESS) |
4965 | return rval; | 4971 | return rval; |
4966 | 4972 | ||
4967 | qla_printk(KERN_ERR, ha, | 4973 | ql_log(ql_log_info, vha, 0x009a, "Update operational firmware.\n"); |
4968 | "FW: Please update operational firmware...\n"); | ||
4969 | ha->flags.running_gold_fw = 1; | 4974 | ha->flags.running_gold_fw = 1; |
4970 | 4975 | ||
4971 | return rval; | 4976 | return rval; |
@@ -4992,8 +4997,8 @@ qla2x00_try_to_stop_firmware(scsi_qla_host_t *vha) | |||
4992 | continue; | 4997 | continue; |
4993 | if (qla2x00_setup_chip(vha) != QLA_SUCCESS) | 4998 | if (qla2x00_setup_chip(vha) != QLA_SUCCESS) |
4994 | continue; | 4999 | continue; |
4995 | qla_printk(KERN_INFO, ha, | 5000 | ql_log(ql_log_info, vha, 0x8015, |
4996 | "Attempting retry of stop-firmware command...\n"); | 5001 | "Attempting retry of stop-firmware command.\n"); |
4997 | ret = qla2x00_stop_firmware(vha); | 5002 | ret = qla2x00_stop_firmware(vha); |
4998 | } | 5003 | } |
4999 | } | 5004 | } |
@@ -5028,10 +5033,10 @@ qla24xx_configure_vhba(scsi_qla_host_t *vha) | |||
5028 | /* Login to SNS first */ | 5033 | /* Login to SNS first */ |
5029 | ha->isp_ops->fabric_login(vha, NPH_SNS, 0xff, 0xff, 0xfc, mb, BIT_1); | 5034 | ha->isp_ops->fabric_login(vha, NPH_SNS, 0xff, 0xff, 0xfc, mb, BIT_1); |
5030 | if (mb[0] != MBS_COMMAND_COMPLETE) { | 5035 | if (mb[0] != MBS_COMMAND_COMPLETE) { |
5031 | DEBUG15(qla_printk(KERN_INFO, ha, | 5036 | ql_dbg(ql_dbg_init, vha, 0x0103, |
5032 | "Failed SNS login: loop_id=%x mb[0]=%x mb[1]=%x " | 5037 | "Failed SNS login: loop_id=%x mb[0]=%x mb[1]=%x mb[2]=%x " |
5033 | "mb[2]=%x mb[6]=%x mb[7]=%x\n", NPH_SNS, | 5038 | "mb[6]=%x mb[7]=%x.\n", |
5034 | mb[0], mb[1], mb[2], mb[6], mb[7])); | 5039 | NPH_SNS, mb[0], mb[1], mb[2], mb[6], mb[7]); |
5035 | return (QLA_FUNCTION_FAILED); | 5040 | return (QLA_FUNCTION_FAILED); |
5036 | } | 5041 | } |
5037 | 5042 | ||
@@ -5151,19 +5156,23 @@ qla81xx_nvram_config(scsi_qla_host_t *vha) | |||
5151 | for (cnt = 0, chksum = 0; cnt < ha->nvram_size >> 2; cnt++) | 5156 | for (cnt = 0, chksum = 0; cnt < ha->nvram_size >> 2; cnt++) |
5152 | chksum += le32_to_cpu(*dptr++); | 5157 | chksum += le32_to_cpu(*dptr++); |
5153 | 5158 | ||
5154 | DEBUG5(printk("scsi(%ld): Contents of NVRAM\n", vha->host_no)); | 5159 | ql_dbg(ql_dbg_init + ql_dbg_buffer, vha, 0x0111, |
5155 | DEBUG5(qla2x00_dump_buffer((uint8_t *)nv, ha->nvram_size)); | 5160 | "Contents of NVRAM:\n"); |
5161 | ql_dump_buffer(ql_dbg_init + ql_dbg_buffer, vha, 0x0112, | ||
5162 | (uint8_t *)nv, ha->nvram_size); | ||
5156 | 5163 | ||
5157 | /* Bad NVRAM data, set defaults parameters. */ | 5164 | /* Bad NVRAM data, set defaults parameters. */ |
5158 | if (chksum || nv->id[0] != 'I' || nv->id[1] != 'S' || nv->id[2] != 'P' | 5165 | if (chksum || nv->id[0] != 'I' || nv->id[1] != 'S' || nv->id[2] != 'P' |
5159 | || nv->id[3] != ' ' || | 5166 | || nv->id[3] != ' ' || |
5160 | nv->nvram_version < __constant_cpu_to_le16(ICB_VERSION)) { | 5167 | nv->nvram_version < __constant_cpu_to_le16(ICB_VERSION)) { |
5161 | /* Reset NVRAM data. */ | 5168 | /* Reset NVRAM data. */ |
5162 | qla_printk(KERN_WARNING, ha, "Inconsistent NVRAM detected: " | 5169 | ql_log(ql_log_info, vha, 0x0073, |
5163 | "checksum=0x%x id=%c version=0x%x.\n", chksum, nv->id[0], | 5170 | "Inconisistent NVRAM detected: checksum=0x%x id=%c " |
5171 | "version=0x%x.\n", chksum, nv->id[0], | ||
5164 | le16_to_cpu(nv->nvram_version)); | 5172 | le16_to_cpu(nv->nvram_version)); |
5165 | qla_printk(KERN_WARNING, ha, "Falling back to functioning (yet " | 5173 | ql_log(ql_log_info, vha, 0x0074, |
5166 | "invalid -- WWPN) defaults.\n"); | 5174 | "Falling back to functioning (yet invalid -- WWPN) " |
5175 | "defaults.\n"); | ||
5167 | 5176 | ||
5168 | /* | 5177 | /* |
5169 | * Set default initialization control block. | 5178 | * Set default initialization control block. |
@@ -5355,12 +5364,10 @@ qla81xx_nvram_config(scsi_qla_host_t *vha) | |||
5355 | if (ha->zio_mode != QLA_ZIO_DISABLED) { | 5364 | if (ha->zio_mode != QLA_ZIO_DISABLED) { |
5356 | ha->zio_mode = QLA_ZIO_MODE_6; | 5365 | ha->zio_mode = QLA_ZIO_MODE_6; |
5357 | 5366 | ||
5358 | DEBUG2(printk("scsi(%ld): ZIO mode %d enabled; timer delay " | 5367 | ql_log(ql_log_info, vha, 0x0075, |
5359 | "(%d us).\n", vha->host_no, ha->zio_mode, | ||
5360 | ha->zio_timer * 100)); | ||
5361 | qla_printk(KERN_INFO, ha, | ||
5362 | "ZIO mode %d enabled; timer delay (%d us).\n", | 5368 | "ZIO mode %d enabled; timer delay (%d us).\n", |
5363 | ha->zio_mode, ha->zio_timer * 100); | 5369 | ha->zio_mode, |
5370 | ha->zio_timer * 100); | ||
5364 | 5371 | ||
5365 | icb->firmware_options_2 |= cpu_to_le32( | 5372 | icb->firmware_options_2 |= cpu_to_le32( |
5366 | (uint32_t)ha->zio_mode); | 5373 | (uint32_t)ha->zio_mode); |
@@ -5369,8 +5376,8 @@ qla81xx_nvram_config(scsi_qla_host_t *vha) | |||
5369 | } | 5376 | } |
5370 | 5377 | ||
5371 | if (rval) { | 5378 | if (rval) { |
5372 | DEBUG2_3(printk(KERN_WARNING | 5379 | ql_log(ql_log_warn, vha, 0x0076, |
5373 | "scsi(%ld): NVRAM configuration failed!\n", vha->host_no)); | 5380 | "NVRAM configuration failed.\n"); |
5374 | } | 5381 | } |
5375 | return (rval); | 5382 | return (rval); |
5376 | } | 5383 | } |
@@ -5393,9 +5400,8 @@ qla82xx_restart_isp(scsi_qla_host_t *vha) | |||
5393 | 5400 | ||
5394 | status = qla2x00_fw_ready(vha); | 5401 | status = qla2x00_fw_ready(vha); |
5395 | if (!status) { | 5402 | if (!status) { |
5396 | qla_printk(KERN_INFO, ha, | 5403 | ql_log(ql_log_info, vha, 0x803c, |
5397 | "%s(): Start configure loop, " | 5404 | "Start configure loop, status =%d.\n", status); |
5398 | "status = %d\n", __func__, status); | ||
5399 | 5405 | ||
5400 | /* Issue a marker after FW becomes ready. */ | 5406 | /* Issue a marker after FW becomes ready. */ |
5401 | qla2x00_marker(vha, req, rsp, 0, 0, MK_SYNC_ALL); | 5407 | qla2x00_marker(vha, req, rsp, 0, 0, MK_SYNC_ALL); |
@@ -5417,9 +5423,8 @@ qla82xx_restart_isp(scsi_qla_host_t *vha) | |||
5417 | if ((vha->device_flags & DFLG_NO_CABLE)) | 5423 | if ((vha->device_flags & DFLG_NO_CABLE)) |
5418 | status = 0; | 5424 | status = 0; |
5419 | 5425 | ||
5420 | qla_printk(KERN_INFO, ha, | 5426 | ql_log(ql_log_info, vha, 0x803d, |
5421 | "%s(): Configure loop done, status = 0x%x\n", | 5427 | "Configure loop done, status = 0x%x.\n", status); |
5422 | __func__, status); | ||
5423 | } | 5428 | } |
5424 | 5429 | ||
5425 | if (!status) { | 5430 | if (!status) { |
@@ -5455,9 +5460,9 @@ qla82xx_restart_isp(scsi_qla_host_t *vha) | |||
5455 | ha->fce_dma, ha->fce_bufs, ha->fce_mb, | 5460 | ha->fce_dma, ha->fce_bufs, ha->fce_mb, |
5456 | &ha->fce_bufs); | 5461 | &ha->fce_bufs); |
5457 | if (rval) { | 5462 | if (rval) { |
5458 | qla_printk(KERN_WARNING, ha, | 5463 | ql_log(ql_log_warn, vha, 0x803e, |
5459 | "Unable to reinitialize FCE " | 5464 | "Unable to reinitialize FCE (%d).\n", |
5460 | "(%d).\n", rval); | 5465 | rval); |
5461 | ha->flags.fce_enabled = 0; | 5466 | ha->flags.fce_enabled = 0; |
5462 | } | 5467 | } |
5463 | } | 5468 | } |
@@ -5467,17 +5472,16 @@ qla82xx_restart_isp(scsi_qla_host_t *vha) | |||
5467 | rval = qla2x00_enable_eft_trace(vha, | 5472 | rval = qla2x00_enable_eft_trace(vha, |
5468 | ha->eft_dma, EFT_NUM_BUFFERS); | 5473 | ha->eft_dma, EFT_NUM_BUFFERS); |
5469 | if (rval) { | 5474 | if (rval) { |
5470 | qla_printk(KERN_WARNING, ha, | 5475 | ql_log(ql_log_warn, vha, 0x803f, |
5471 | "Unable to reinitialize EFT " | 5476 | "Unable to reinitialize EFT (%d).\n", |
5472 | "(%d).\n", rval); | 5477 | rval); |
5473 | } | 5478 | } |
5474 | } | 5479 | } |
5475 | } | 5480 | } |
5476 | 5481 | ||
5477 | if (!status) { | 5482 | if (!status) { |
5478 | DEBUG(printk(KERN_INFO | 5483 | ql_dbg(ql_dbg_taskm, vha, 0x8040, |
5479 | "qla82xx_restart_isp(%ld): succeeded.\n", | 5484 | "qla82xx_restart_isp succeeded.\n"); |
5480 | vha->host_no)); | ||
5481 | 5485 | ||
5482 | spin_lock_irqsave(&ha->vport_slock, flags); | 5486 | spin_lock_irqsave(&ha->vport_slock, flags); |
5483 | list_for_each_entry(vp, &ha->vp_list, list) { | 5487 | list_for_each_entry(vp, &ha->vp_list, list) { |
@@ -5494,8 +5498,8 @@ qla82xx_restart_isp(scsi_qla_host_t *vha) | |||
5494 | spin_unlock_irqrestore(&ha->vport_slock, flags); | 5498 | spin_unlock_irqrestore(&ha->vport_slock, flags); |
5495 | 5499 | ||
5496 | } else { | 5500 | } else { |
5497 | qla_printk(KERN_INFO, ha, | 5501 | ql_log(ql_log_warn, vha, 0x8041, |
5498 | "qla82xx_restart_isp: **** FAILED ****\n"); | 5502 | "qla82xx_restart_isp **** FAILED ****.\n"); |
5499 | } | 5503 | } |
5500 | 5504 | ||
5501 | return status; | 5505 | return status; |
@@ -5645,9 +5649,8 @@ qla24xx_update_fcport_fcp_prio(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
5645 | if (ret == QLA_SUCCESS) | 5649 | if (ret == QLA_SUCCESS) |
5646 | fcport->fcp_prio = priority; | 5650 | fcport->fcp_prio = priority; |
5647 | else | 5651 | else |
5648 | DEBUG2(printk(KERN_WARNING | 5652 | ql_dbg(ql_dbg_user, vha, 0x704f, |
5649 | "scsi(%ld): Unable to activate fcp priority, " | 5653 | "Unable to activate fcp priority, ret=0x%x.\n", ret); |
5650 | " ret=0x%x\n", vha->host_no, ret)); | ||
5651 | 5654 | ||
5652 | return ret; | 5655 | return ret; |
5653 | } | 5656 | } |