Module Name:    src
Committed By:   mlelstv
Date:           Sun Jun  6 10:39:10 UTC 2021

Modified Files:
        src/sys/dev/iscsi: iscsi_send.c

Log Message:
Schedule command timeout without connection lock being held to prevent
a deadlock.


To generate a diff of this commit:
cvs rdiff -u -r1.37 -r1.38 src/sys/dev/iscsi/iscsi_send.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/iscsi/iscsi_send.c
diff -u src/sys/dev/iscsi/iscsi_send.c:1.37 src/sys/dev/iscsi/iscsi_send.c:1.38
--- src/sys/dev/iscsi/iscsi_send.c:1.37	Sun Mar  4 07:39:45 2018
+++ src/sys/dev/iscsi/iscsi_send.c	Sun Jun  6 10:39:10 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: iscsi_send.c,v 1.37 2018/03/04 07:39:45 mlelstv Exp $	*/
+/*	$NetBSD: iscsi_send.c,v 1.38 2021/06/06 10:39:10 mlelstv Exp $	*/
 
 /*-
  * Copyright (c) 2004,2005,2006,2011 The NetBSD Foundation, Inc.
@@ -548,9 +548,10 @@ resend_pdu(ccb_t *ccb)
 	} else {
 		TAILQ_INSERT_TAIL(&conn->c_pdus_to_send, pdu, pdu_send_chain);
 	}
-	ccb_timeout_start(ccb, COMMAND_TIMEOUT);
 	cv_broadcast(&conn->c_conn_cv);
 	mutex_exit(&conn->c_lock);
+
+	ccb_timeout_start(ccb, COMMAND_TIMEOUT);
 }
 
 

Reply via email to