From 3913eb8f3766dc3a2f0eeee9fafd4d578bbd6b0a Mon Sep 17 00:00:00 2001 From: Gleb Chesnokov Date: Thu, 2 Mar 2023 14:05:40 +0300 Subject: [PATCH] qla2x00t-32gbit: Fix stalled login If a login failed due to low FW resources, the session can stall and will not be connected. Reset session state to allow relogin logic to redrive the connection. Signed-off-by: Quinn Tran Signed-off-by: Nilesh Javali Reviewed-by: Himanshu Madhani Signed-off-by: Martin K. Petersen [ commit 40f5b1b9a4af upstream ] --- qla2x00t-32gbit/qla_init.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/qla2x00t-32gbit/qla_init.c b/qla2x00t-32gbit/qla_init.c index 848a1c16a..232de8a56 100644 --- a/qla2x00t-32gbit/qla_init.c +++ b/qla2x00t-32gbit/qla_init.c @@ -390,6 +390,12 @@ done_free_sp: fcport->flags &= ~FCF_ASYNC_SENT; done: fcport->flags &= ~FCF_ASYNC_ACTIVE; + + /* + * async login failed. Could be due to iocb/exchange resource + * being low. Set state DELETED for re-login process to start again. + */ + qla2x00_set_fcport_disc_state(fcport, DSC_DELETED); return rval; }