Commit cb873ba4 authored by Quinn Tran's avatar Quinn Tran Committed by Martin K. Petersen

scsi: qla2xxx: Update rscn_rcvd field to more meaningful scan_needed

Rename rscn_rcvd field to scan_needed to be more meaningful.
Signed-off-by: default avatarQuinn Tran <quinn.tran@cavium.com>
Signed-off-by: default avatarHimanshu Madhani <himanshu.madhani@cavium.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 49cecca7
...@@ -2351,7 +2351,7 @@ typedef struct fc_port { ...@@ -2351,7 +2351,7 @@ typedef struct fc_port {
unsigned int login_succ:1; unsigned int login_succ:1;
unsigned int query:1; unsigned int query:1;
unsigned int id_changed:1; unsigned int id_changed:1;
unsigned int rscn_rcvd:1; unsigned int scan_needed:1;
struct work_struct nvme_del_work; struct work_struct nvme_del_work;
struct completion nvme_del_done; struct completion nvme_del_done;
......
...@@ -3951,7 +3951,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp) ...@@ -3951,7 +3951,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp)
list_for_each_entry(fcport, &vha->vp_fcports, list) { list_for_each_entry(fcport, &vha->vp_fcports, list) {
if (memcmp(rp->port_name, fcport->port_name, WWN_SIZE)) if (memcmp(rp->port_name, fcport->port_name, WWN_SIZE))
continue; continue;
fcport->rscn_rcvd = 0; fcport->scan_needed = 0;
fcport->scan_state = QLA_FCPORT_FOUND; fcport->scan_state = QLA_FCPORT_FOUND;
found = true; found = true;
/* /*
...@@ -3981,12 +3981,12 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp) ...@@ -3981,12 +3981,12 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp)
*/ */
list_for_each_entry(fcport, &vha->vp_fcports, list) { list_for_each_entry(fcport, &vha->vp_fcports, list) {
if ((fcport->flags & FCF_FABRIC_DEVICE) == 0) { if ((fcport->flags & FCF_FABRIC_DEVICE) == 0) {
fcport->rscn_rcvd = 0; fcport->scan_needed = 0;
continue; continue;
} }
if (fcport->scan_state != QLA_FCPORT_FOUND) { if (fcport->scan_state != QLA_FCPORT_FOUND) {
fcport->rscn_rcvd = 0; fcport->scan_needed = 0;
if ((qla_dual_mode_enabled(vha) || if ((qla_dual_mode_enabled(vha) ||
qla_ini_mode_enabled(vha)) && qla_ini_mode_enabled(vha)) &&
atomic_read(&fcport->state) == FCS_ONLINE) { atomic_read(&fcport->state) == FCS_ONLINE) {
...@@ -4005,7 +4005,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp) ...@@ -4005,7 +4005,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp)
} }
} }
} else { } else {
if (fcport->rscn_rcvd || if (fcport->scan_needed ||
fcport->disc_state != DSC_LOGIN_COMPLETE) { fcport->disc_state != DSC_LOGIN_COMPLETE) {
if (fcport->login_retry == 0) { if (fcport->login_retry == 0) {
fcport->login_retry = fcport->login_retry =
...@@ -4015,7 +4015,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp) ...@@ -4015,7 +4015,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp)
fcport->port_name, fcport->loop_id, fcport->port_name, fcport->loop_id,
fcport->login_retry); fcport->login_retry);
} }
fcport->rscn_rcvd = 0; fcport->scan_needed = 0;
qla24xx_fcport_handle_login(vha, fcport); qla24xx_fcport_handle_login(vha, fcport);
} }
} }
...@@ -4030,7 +4030,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp) ...@@ -4030,7 +4030,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp)
if (recheck) { if (recheck) {
list_for_each_entry(fcport, &vha->vp_fcports, list) { list_for_each_entry(fcport, &vha->vp_fcports, list) {
if (fcport->rscn_rcvd) { if (fcport->scan_needed) {
set_bit(LOCAL_LOOP_UPDATE, &vha->dpc_flags); set_bit(LOCAL_LOOP_UPDATE, &vha->dpc_flags);
set_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags); set_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags);
break; break;
......
...@@ -1551,7 +1551,7 @@ void qla2x00_fcport_event_handler(scsi_qla_host_t *vha, struct event_arg *ea) ...@@ -1551,7 +1551,7 @@ void qla2x00_fcport_event_handler(scsi_qla_host_t *vha, struct event_arg *ea)
fcport = qla2x00_find_fcport_by_nportid fcport = qla2x00_find_fcport_by_nportid
(vha, &ea->id, 1); (vha, &ea->id, 1);
if (fcport) if (fcport)
fcport->rscn_rcvd = 1; fcport->scan_needed = 1;
spin_lock_irqsave(&vha->work_lock, flags); spin_lock_irqsave(&vha->work_lock, flags);
if (vha->scan.scan_flags == 0) { if (vha->scan.scan_flags == 0) {
......
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