Commit 052c40c8 authored by andrew.vasquez@qlogic.com's avatar andrew.vasquez@qlogic.com Committed by James Bottomley

[SCSI] qla2xxx: Correct issue where the rport's upcall was not being made after relogin.

A target can LOGO an initiator at any time (i.e. during I/O,
due to a controller hicup, or as a simple authentication
mechanism after an initial CDB command), when this occurs,
the driver attempts to relogin (PLOGI) to the device via the
DPC thread.  Add code to make the appropriate upcall to the
FC transport layer (fc_remote_port_add()) upon successful
completion of the PLOGI.
Signed-off-by: default avatarAndrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent d97994dc
...@@ -51,6 +51,7 @@ extern void qla2x00_update_fcports(scsi_qla_host_t *); ...@@ -51,6 +51,7 @@ extern void qla2x00_update_fcports(scsi_qla_host_t *);
extern int qla2x00_abort_isp(scsi_qla_host_t *); extern int qla2x00_abort_isp(scsi_qla_host_t *);
extern void qla2x00_update_fcport(scsi_qla_host_t *, fc_port_t *);
extern void qla2x00_reg_remote_port(scsi_qla_host_t *, fc_port_t *); extern void qla2x00_reg_remote_port(scsi_qla_host_t *, fc_port_t *);
/* /*
......
...@@ -32,7 +32,6 @@ static int qla2x00_fw_ready(scsi_qla_host_t *); ...@@ -32,7 +32,6 @@ static int qla2x00_fw_ready(scsi_qla_host_t *);
static int qla2x00_configure_hba(scsi_qla_host_t *); static int qla2x00_configure_hba(scsi_qla_host_t *);
static int qla2x00_configure_loop(scsi_qla_host_t *); static int qla2x00_configure_loop(scsi_qla_host_t *);
static int qla2x00_configure_local_loop(scsi_qla_host_t *); static int qla2x00_configure_local_loop(scsi_qla_host_t *);
static void qla2x00_update_fcport(scsi_qla_host_t *, fc_port_t *);
static int qla2x00_configure_fabric(scsi_qla_host_t *); static int qla2x00_configure_fabric(scsi_qla_host_t *);
static int qla2x00_find_all_fabric_devs(scsi_qla_host_t *, struct list_head *); static int qla2x00_find_all_fabric_devs(scsi_qla_host_t *, struct list_head *);
static int qla2x00_device_resync(scsi_qla_host_t *); static int qla2x00_device_resync(scsi_qla_host_t *);
...@@ -2039,7 +2038,7 @@ qla2x00_probe_for_all_luns(scsi_qla_host_t *ha) ...@@ -2039,7 +2038,7 @@ qla2x00_probe_for_all_luns(scsi_qla_host_t *ha)
* Context: * Context:
* Kernel context. * Kernel context.
*/ */
static void void
qla2x00_update_fcport(scsi_qla_host_t *ha, fc_port_t *fcport) qla2x00_update_fcport(scsi_qla_host_t *ha, fc_port_t *fcport)
{ {
uint16_t index; uint16_t index;
......
...@@ -2250,13 +2250,8 @@ qla2x00_do_dpc(void *data) ...@@ -2250,13 +2250,8 @@ qla2x00_do_dpc(void *data)
DEBUG(printk("scsi(%ld): port login OK: logged in ID 0x%x\n", DEBUG(printk("scsi(%ld): port login OK: logged in ID 0x%x\n",
ha->host_no, fcport->loop_id)); ha->host_no, fcport->loop_id));
fcport->port_login_retry_count = qla2x00_update_fcport(ha,
ha->port_down_retry_count * PORT_RETRY_TIME; fcport);
atomic_set(&fcport->state, FCS_ONLINE);
atomic_set(&fcport->port_down_timer,
ha->port_down_retry_count * PORT_RETRY_TIME);
fcport->login_retry = 0;
} else if (status == 1) { } else if (status == 1) {
set_bit(RELOGIN_NEEDED, &ha->dpc_flags); set_bit(RELOGIN_NEEDED, &ha->dpc_flags);
/* retry the login again */ /* retry the login again */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment