mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-23 13:41:27 +00:00
isert: Make sure we cleanup all states if resource allocation fails
Signed-off-by: Yan Burman <yanb@mellanox.com> git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/iser@5343 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -243,6 +243,7 @@ int isert_conn_alloc(struct iscsi_session *session,
|
||||
|
||||
conn->rd_state = 1;
|
||||
isert_dev_release(dev);
|
||||
isert_set_priv(conn, NULL);
|
||||
|
||||
res = isert_login_rsp_tx(cmnd, true, false);
|
||||
vunmap(dev->sg_virt);
|
||||
@@ -262,6 +263,7 @@ int isert_conn_alloc(struct iscsi_session *session,
|
||||
goto out;
|
||||
|
||||
cleanup_iscsi_conn:
|
||||
conn->rd_state = 0;
|
||||
if (conn->nop_in_interval > 0)
|
||||
cancel_delayed_work_sync(&conn->nop_in_delayed_work);
|
||||
cleanup_conn:
|
||||
|
||||
Reference in New Issue
Block a user