]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
qla2xxx: Set relogin flag when we fail to queue login requests.
authorChad Dupuis <chad.dupuis@qlogic.com>
Wed, 27 Jan 2016 17:03:37 +0000 (12:03 -0500)
committerChuck Anderson <chuck.anderson@oracle.com>
Wed, 16 Mar 2016 11:39:13 +0000 (04:39 -0700)
Orabug: 22863553

If we fail to queue an srb for an async login we should set the
relogin flag so it will be retried as the reason for the queuing
failure was most likely transient.  Failure to do this can lead to
failed paths as login is never retried if the relogin flag is not
set.

Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
Signed-off-by: Himanshu Madhani <himanshu.madhani@qlogic.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Dan Duval <dan.duval@oracle.com>
drivers/scsi/qla2xxx/qla_init.c

index 92547bb41e173cf3ad859c09247f78a32c3121d1..c15d33d2ea11b07c05b7209da5afbfc3f31d0b4c 100644 (file)
@@ -155,8 +155,12 @@ qla2x00_async_login(struct scsi_qla_host *vha, fc_port_t *fcport,
        if (data[1] & QLA_LOGIO_LOGIN_RETRIED)
                lio->u.logio.flags |= SRB_LOGIN_RETRIED;
        rval = qla2x00_start_sp(sp);
-       if (rval != QLA_SUCCESS)
+       if (rval != QLA_SUCCESS) {
+               fcport->flags &= ~FCF_ASYNC_SENT;
+               fcport->flags |= FCF_LOGIN_NEEDED;
+               set_bit(RELOGIN_NEEDED, &vha->dpc_flags);
                goto done_free_sp;
+       }
 
        ql_dbg(ql_dbg_disc, vha, 0x2072,
            "Async-login - hdl=%x, loopid=%x portid=%02x%02x%02x "