Skip to content

Commit

Permalink
scsi: qla2xxx: do not check login_state if no loop id is assigned
Browse files Browse the repository at this point in the history
When no loop id is assigned in qla24xx_fcport_handle_login() the login
state needs to be ignored; it will get set later on in
qla_chk_n2n_b4_login().

Cc: Quinn Tran <[email protected]>
Cc: Himanshu Madhani <[email protected]>
Fixes: 040036b ("scsi: qla2xxx: Delay loop id allocation at login")
Signed-off-by: Hannes Reinecke <[email protected]>
Acked-by: Himanshu Madhani <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
  • Loading branch information
hreinecke authored and martinkpetersen committed Mar 2, 2018
1 parent 1c6cacf commit 07ea4b6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions drivers/scsi/qla2xxx/qla_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -1157,8 +1157,9 @@ int qla24xx_fcport_handle_login(struct scsi_qla_host *vha, fc_port_t *fcport)
if (fcport->scan_state != QLA_FCPORT_FOUND)
return 0;

if ((fcport->fw_login_state == DSC_LS_PLOGI_PEND) ||
(fcport->fw_login_state == DSC_LS_PRLI_PEND))
if ((fcport->loop_id != FC_NO_LOOP_ID) &&
((fcport->fw_login_state == DSC_LS_PLOGI_PEND) ||
(fcport->fw_login_state == DSC_LS_PRLI_PEND)))
return 0;

if (fcport->fw_login_state == DSC_LS_PLOGI_COMP) {
Expand Down

0 comments on commit 07ea4b6

Please sign in to comment.