diff options
author | Sagi Grimberg <sagig@mellanox.com> | 2014-07-02 16:19:25 +0300 |
---|---|---|
committer | Jiri Slaby <jslaby@suse.cz> | 2014-10-13 15:41:16 +0200 |
commit | f0d84efb3fdcf10a7181cd64fa5fdfb9e7fed3d2 (patch) | |
tree | 764a947343c7735346f578754e3eeacb1d9cb5bc /drivers/infiniband | |
parent | f6dd2a9321825e8f90a11306cab39000f3809659 (diff) | |
download | lwn-f0d84efb3fdcf10a7181cd64fa5fdfb9e7fed3d2.tar.gz lwn-f0d84efb3fdcf10a7181cd64fa5fdfb9e7fed3d2.zip |
Target/iser: Don't put isert_conn inside disconnected handler
commit 0fc4ea701fcf5bc51ace4e288af5be741465f776 upstream.
disconnected_handler is invoked on several CM events (such
as DISCONNECTED, DEVICE_REMOVAL, TIMEWAIT_EXIT...). Since
multiple events can occur while before isert_free_conn is
invoked, we might put all isert_conn references and free
the connection too early.
Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/ulp/isert/ib_isert.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/ulp/isert/ib_isert.c b/drivers/infiniband/ulp/isert/ib_isert.c index a9f2b965c546..4c2b42bf6cde 100644 --- a/drivers/infiniband/ulp/isert/ib_isert.c +++ b/drivers/infiniband/ulp/isert/ib_isert.c @@ -699,7 +699,6 @@ isert_disconnect_work(struct work_struct *work) wake_up: complete(&isert_conn->conn_wait); - isert_put_conn(isert_conn); } static void @@ -2709,6 +2708,7 @@ static void isert_wait_conn(struct iscsi_conn *conn) wait_for_completion(&isert_conn->conn_wait_comp_err); wait_for_completion(&isert_conn->conn_wait); + isert_put_conn(isert_conn); } static void isert_free_conn(struct iscsi_conn *conn) |