All of lore.kernel.org
 help / color / mirror / Atom feed
From: Varun Prakash <varun@chelsio.com>
To: target-devel@vger.kernel.org, linux-scsi@vger.kernel.org
Cc: nab@linux-iscsi.org, swise@opengridcomputing.com,
	kxie@chelsio.com, indranil@chelsio.com, varun@chelsio.com
Subject: [PATCH v3 11/13] iscsi-target: call complete on conn_logout_comp
Date: Wed, 20 Apr 2016 00:00:18 +0530	[thread overview]
Message-ID: <0dbf515fb0ef72e5ffb350a85e1e8f35ac73b19b.1461088673.git.varun@chelsio.com> (raw)
In-Reply-To: <cover.1461088672.git.varun@chelsio.com>
In-Reply-To: <cover.1461088672.git.varun@chelsio.com>

ISCSI_HW_OFFLOAD transport drivers waits
on conn_logout_comp as ISCSI_TCP driver
so call complete if transport type
is ISCSI_HW_OFFLOAD.

Signed-off-by: Varun Prakash <varun@chelsio.com>
---
 drivers/target/iscsi/iscsi_target.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/target/iscsi/iscsi_target.c b/drivers/target/iscsi/iscsi_target.c
index 29df956..8021223 100644
--- a/drivers/target/iscsi/iscsi_target.c
+++ b/drivers/target/iscsi/iscsi_target.c
@@ -4063,16 +4063,18 @@ int iscsit_close_connection(
 	pr_debug("Closing iSCSI connection CID %hu on SID:"
 		" %u\n", conn->cid, sess->sid);
 	/*
-	 * Always up conn_logout_comp for the traditional TCP case just in case
-	 * the RX Thread in iscsi_target_rx_opcode() is sleeping and the logout
-	 * response never got sent because the connection failed.
+	 * Always up conn_logout_comp for the traditional TCP and HW_OFFLOAD
+	 * case just in case the RX Thread in iscsi_target_rx_opcode() is
+	 * sleeping and the logout response never got sent because the
+	 * connection failed.
 	 *
 	 * However for iser-target, isert_wait4logout() is using conn_logout_comp
 	 * to signal logout response TX interrupt completion.  Go ahead and skip
 	 * this for iser since isert_rx_opcode() does not wait on logout failure,
 	 * and to avoid iscsi_conn pointer dereference in iser-target code.
 	 */
-	if (conn->conn_transport->transport_type == ISCSI_TCP)
+	if ((conn->conn_transport->transport_type == ISCSI_TCP) ||
+	    (conn->conn_transport->transport_type == ISCSI_HW_OFFLOAD))
 		complete(&conn->conn_logout_comp);
 
 	if (!strcmp(current->comm, ISCSI_RX_THREAD_NAME)) {
-- 
2.0.2

  parent reply	other threads:[~2016-04-19 18:30 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-19 18:30 [PATCH v3 00/13] Chelsio iSCSI target offload driver Varun Prakash
2016-04-19 18:30 ` [PATCH v3 01/13] iscsi-target: add int (*iscsit_xmit_pdu)() Varun Prakash
2016-04-19 18:30 ` [PATCH v3 02/13] iscsi-target: add void (*iscsit_release_cmd)() Varun Prakash
2016-04-19 18:30 ` [PATCH v3 03/13] iscsi-target: add void (*iscsit_get_rx_pdu)() Varun Prakash
2016-08-09  3:19   ` Andy Grover
2016-08-13 16:56     ` Varun Prakash
2016-04-19 18:30 ` [PATCH v3 04/13] iscsi-target: split iscsi_target_rx_thread() Varun Prakash
2016-04-19 18:30 ` [PATCH v3 05/13] iscsi-target: add int (*iscsit_validate_params)() Varun Prakash
2016-04-19 18:30 ` [PATCH v3 06/13] iscsi-target: add void (*iscsit_get_r2t_ttt)() Varun Prakash
2016-04-19 18:30 ` [PATCH v3 07/13] iscsi-target: move iscsit_thread_check_cpumask() Varun Prakash
2016-04-19 18:30 ` [PATCH v3 08/13] iscsi-target: use conn_transport->transport_type in text rsp Varun Prakash
2016-04-19 18:30 ` [PATCH v3 09/13] iscsi-target: add new offload transport type Varun Prakash
2016-04-19 18:30 ` [PATCH v3 10/13] iscsi-target: clear tx_thread_active Varun Prakash
2016-04-19 18:30 ` Varun Prakash [this message]
2016-04-19 18:30 ` [PATCH v3 12/13] iscsi-target: export symbols Varun Prakash
2016-04-19 18:30 ` [PATCH v3 13/13] cxgbit: add files for cxgbit.ko Varun Prakash
2016-04-30 15:54   ` Or Gerlitz
2016-05-18 11:45     ` Or Gerlitz
2016-05-24  6:40       ` Nicholas A. Bellinger
2016-05-25 15:04         ` Or Gerlitz
2016-05-25 17:40           ` Steve Wise
2016-05-25 20:41             ` Or Gerlitz
2016-05-26  4:55               ` Nicholas A. Bellinger
2016-05-26 18:58                 ` Varun Prakash
2016-07-05 21:24                   ` Or Gerlitz
2016-07-06 17:17                     ` Varun Prakash
2016-07-07  7:54                       ` Or Gerlitz
2016-07-08 18:03                         ` Varun Prakash
2016-07-08 18:36                           ` Steve Wise
2016-07-12  7:53                             ` Or Gerlitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0dbf515fb0ef72e5ffb350a85e1e8f35ac73b19b.1461088673.git.varun@chelsio.com \
    --to=varun@chelsio.com \
    --cc=indranil@chelsio.com \
    --cc=kxie@chelsio.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=nab@linux-iscsi.org \
    --cc=swise@opengridcomputing.com \
    --cc=target-devel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.