diff options
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_init.c')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_init.c | 33 |
1 files changed, 1 insertions, 32 deletions
diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c index 0387005fcb6d..7629558eba25 100644 --- a/drivers/scsi/qla2xxx/qla_init.c +++ b/drivers/scsi/qla2xxx/qla_init.c | |||
@@ -85,9 +85,7 @@ qla2x00_initialize_adapter(scsi_qla_host_t *ha) | |||
85 | atomic_set(&ha->loop_down_timer, LOOP_DOWN_TIME); | 85 | atomic_set(&ha->loop_down_timer, LOOP_DOWN_TIME); |
86 | atomic_set(&ha->loop_state, LOOP_DOWN); | 86 | atomic_set(&ha->loop_state, LOOP_DOWN); |
87 | ha->device_flags = 0; | 87 | ha->device_flags = 0; |
88 | ha->sns_retry_cnt = 0; | ||
89 | ha->dpc_flags = 0; | 88 | ha->dpc_flags = 0; |
90 | ha->failback_delay = 0; | ||
91 | ha->flags.management_server_logged_in = 0; | 89 | ha->flags.management_server_logged_in = 0; |
92 | ha->marker_needed = 0; | 90 | ha->marker_needed = 0; |
93 | ha->mbx_flags = 0; | 91 | ha->mbx_flags = 0; |
@@ -171,8 +169,6 @@ check_fw_ready_again: | |||
171 | 169 | ||
172 | if (wait_time == 0) | 170 | if (wait_time == 0) |
173 | rval = QLA_FUNCTION_FAILED; | 171 | rval = QLA_FUNCTION_FAILED; |
174 | if (ha->mem_err) | ||
175 | restart_risc = 1; | ||
176 | } else if (ha->device_flags & DFLG_NO_CABLE) | 172 | } else if (ha->device_flags & DFLG_NO_CABLE) |
177 | /* If no cable, then all is good. */ | 173 | /* If no cable, then all is good. */ |
178 | rval = QLA_SUCCESS; | 174 | rval = QLA_SUCCESS; |
@@ -1410,13 +1406,8 @@ qla2x00_nvram_config(scsi_qla_host_t *ha) | |||
1410 | /* Set minimum RATOV to 200 tenths of a second. */ | 1406 | /* Set minimum RATOV to 200 tenths of a second. */ |
1411 | ha->r_a_tov = 200; | 1407 | ha->r_a_tov = 200; |
1412 | 1408 | ||
1413 | ha->minimum_timeout = | ||
1414 | (ha->login_timeout * ha->retry_count) + nv->port_down_retry_count; | ||
1415 | ha->loop_reset_delay = nv->reset_delay; | 1409 | ha->loop_reset_delay = nv->reset_delay; |
1416 | 1410 | ||
1417 | /* Will get the value from NVRAM. */ | ||
1418 | ha->loop_down_timeout = LOOP_DOWN_TIMEOUT; | ||
1419 | |||
1420 | /* Link Down Timeout = 0: | 1411 | /* Link Down Timeout = 0: |
1421 | * | 1412 | * |
1422 | * When Port Down timer expires we will start returning | 1413 | * When Port Down timer expires we will start returning |
@@ -1429,18 +1420,13 @@ qla2x00_nvram_config(scsi_qla_host_t *ha) | |||
1429 | */ | 1420 | */ |
1430 | if (nv->link_down_timeout == 0) { | 1421 | if (nv->link_down_timeout == 0) { |
1431 | ha->loop_down_abort_time = | 1422 | ha->loop_down_abort_time = |
1432 | (LOOP_DOWN_TIME - ha->loop_down_timeout); | 1423 | (LOOP_DOWN_TIME - LOOP_DOWN_TIMEOUT); |
1433 | } else { | 1424 | } else { |
1434 | ha->link_down_timeout = nv->link_down_timeout; | 1425 | ha->link_down_timeout = nv->link_down_timeout; |
1435 | ha->loop_down_abort_time = | 1426 | ha->loop_down_abort_time = |
1436 | (LOOP_DOWN_TIME - ha->link_down_timeout); | 1427 | (LOOP_DOWN_TIME - ha->link_down_timeout); |
1437 | } | 1428 | } |
1438 | 1429 | ||
1439 | ha->max_luns = MAX_LUNS; | ||
1440 | ha->max_probe_luns = le16_to_cpu(nv->max_luns_per_target); | ||
1441 | if (ha->max_probe_luns == 0) | ||
1442 | ha->max_probe_luns = MIN_LUNS; | ||
1443 | |||
1444 | /* | 1430 | /* |
1445 | * Need enough time to try and get the port back. | 1431 | * Need enough time to try and get the port back. |
1446 | */ | 1432 | */ |
@@ -1457,16 +1443,6 @@ qla2x00_nvram_config(scsi_qla_host_t *ha) | |||
1457 | if (ql2xloginretrycount) | 1443 | if (ql2xloginretrycount) |
1458 | ha->login_retry_count = ql2xloginretrycount; | 1444 | ha->login_retry_count = ql2xloginretrycount; |
1459 | 1445 | ||
1460 | ha->binding_type = Bind; | ||
1461 | if (ha->binding_type != BIND_BY_PORT_NAME && | ||
1462 | ha->binding_type != BIND_BY_PORT_ID) { | ||
1463 | qla_printk(KERN_WARNING, ha, | ||
1464 | "Invalid binding type specified (%d), " | ||
1465 | "defaulting to BIND_BY_PORT_NAME!!!\n", ha->binding_type); | ||
1466 | |||
1467 | ha->binding_type = BIND_BY_PORT_NAME; | ||
1468 | } | ||
1469 | |||
1470 | icb->lun_enables = __constant_cpu_to_le16(0); | 1446 | icb->lun_enables = __constant_cpu_to_le16(0); |
1471 | icb->command_resource_count = 0; | 1447 | icb->command_resource_count = 0; |
1472 | icb->immediate_notify_resource_count = 0; | 1448 | icb->immediate_notify_resource_count = 0; |
@@ -1578,7 +1554,6 @@ qla2x00_configure_loop(scsi_qla_host_t *ha) | |||
1578 | */ | 1554 | */ |
1579 | clear_bit(LOCAL_LOOP_UPDATE, &ha->dpc_flags); | 1555 | clear_bit(LOCAL_LOOP_UPDATE, &ha->dpc_flags); |
1580 | clear_bit(RSCN_UPDATE, &ha->dpc_flags); | 1556 | clear_bit(RSCN_UPDATE, &ha->dpc_flags); |
1581 | ha->mem_err = 0 ; | ||
1582 | 1557 | ||
1583 | /* Determine what we need to do */ | 1558 | /* Determine what we need to do */ |
1584 | if (ha->current_topology == ISP_CFG_FL && | 1559 | if (ha->current_topology == ISP_CFG_FL && |
@@ -2707,7 +2682,6 @@ qla2x00_loop_resync(scsi_qla_host_t *ha) | |||
2707 | rval = QLA_SUCCESS; | 2682 | rval = QLA_SUCCESS; |
2708 | 2683 | ||
2709 | atomic_set(&ha->loop_state, LOOP_UPDATE); | 2684 | atomic_set(&ha->loop_state, LOOP_UPDATE); |
2710 | qla2x00_stats.loop_resync++; | ||
2711 | clear_bit(ISP_ABORT_RETRY, &ha->dpc_flags); | 2685 | clear_bit(ISP_ABORT_RETRY, &ha->dpc_flags); |
2712 | if (ha->flags.online) { | 2686 | if (ha->flags.online) { |
2713 | if (!(rval = qla2x00_fw_ready(ha))) { | 2687 | if (!(rval = qla2x00_fw_ready(ha))) { |
@@ -2786,9 +2760,6 @@ qla2x00_abort_isp(scsi_qla_host_t *ha) | |||
2786 | if (ha->flags.online) { | 2760 | if (ha->flags.online) { |
2787 | ha->flags.online = 0; | 2761 | ha->flags.online = 0; |
2788 | clear_bit(ISP_ABORT_NEEDED, &ha->dpc_flags); | 2762 | clear_bit(ISP_ABORT_NEEDED, &ha->dpc_flags); |
2789 | qla2x00_stats.ispAbort++; | ||
2790 | ha->total_isp_aborts++; /* used by ioctl */ | ||
2791 | ha->sns_retry_cnt = 0; | ||
2792 | 2763 | ||
2793 | qla_printk(KERN_INFO, ha, | 2764 | qla_printk(KERN_INFO, ha, |
2794 | "Performing ISP error recovery - ha= %p.\n", ha); | 2765 | "Performing ISP error recovery - ha= %p.\n", ha); |
@@ -2810,8 +2781,6 @@ qla2x00_abort_isp(scsi_qla_host_t *ha) | |||
2810 | sp = ha->outstanding_cmds[cnt]; | 2781 | sp = ha->outstanding_cmds[cnt]; |
2811 | if (sp) { | 2782 | if (sp) { |
2812 | ha->outstanding_cmds[cnt] = NULL; | 2783 | ha->outstanding_cmds[cnt] = NULL; |
2813 | if (ha->actthreads) | ||
2814 | ha->actthreads--; | ||
2815 | sp->flags = 0; | 2784 | sp->flags = 0; |
2816 | sp->cmd->result = DID_RESET << 16; | 2785 | sp->cmd->result = DID_RESET << 16; |
2817 | sp->cmd->host_scribble = (unsigned char *)NULL; | 2786 | sp->cmd->host_scribble = (unsigned char *)NULL; |