svn commit: r300212 - head/usr.sbin/iscsid
Edward Tomasz Napierala
trasz at FreeBSD.org
Thu May 19 14:59:23 UTC 2016
Author: trasz
Date: Thu May 19 14:59:21 2016
New Revision: 300212
URL: https://svnweb.freebsd.org/changeset/base/300212
Log:
When iscsid(8) is running in ICL proxy mode, don't try to send Logout PDUs.
The kernel already does this for us when we ask it to terminate the session.
MFC after: 1 month
Sponsored by: The FreeBSD Foundation
Modified:
head/usr.sbin/iscsid/discovery.c
Modified: head/usr.sbin/iscsid/discovery.c
==============================================================================
--- head/usr.sbin/iscsid/discovery.c Thu May 19 14:57:37 2016 (r300211)
+++ head/usr.sbin/iscsid/discovery.c Thu May 19 14:59:21 2016 (r300212)
@@ -206,6 +206,18 @@ discovery(struct connection *conn)
log_debugx("removing temporary discovery session");
kernel_remove(conn);
+#ifdef ICL_KERNEL_PROXY
+ if (conn->conn_conf.isc_iser == 1) {
+ /*
+ * If we're going through the proxy, the kernel already
+ * sent Logout PDU for us and destroyed the session,
+ * so we can't send anything anymore.
+ */
+ log_debugx("discovery session done");
+ return;
+ }
+#endif
+
log_debugx("discovery done; logging out");
request = logout_new_request(conn);
pdu_send(request);
More information about the svn-src-all
mailing list