Module Name:    src
Committed By:   maya
Date:           Sat Mar 11 12:08:57 UTC 2017

Modified Files:
        src/sys/dev/ic: isp.c

Log Message:
Don't loop infinitely if the output pointer was changed
Untested, but the change done seems to match the comment above it

CID 980321


To generate a diff of this commit:
cvs rdiff -u -r1.125 -r1.126 src/sys/dev/ic/isp.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/ic/isp.c
diff -u src/sys/dev/ic/isp.c:1.125 src/sys/dev/ic/isp.c:1.126
--- src/sys/dev/ic/isp.c:1.125	Sat Sep 14 13:09:55 2013
+++ src/sys/dev/ic/isp.c	Sat Mar 11 12:08:57 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: isp.c,v 1.125 2013/09/14 13:09:55 joerg Exp $ */
+/* $NetBSD: isp.c,v 1.126 2017/03/11 12:08:57 maya Exp $ */
 /*
  * Machine and OS Independent (well, as best as possible)
  * code for the Qlogic ISP SCSI adapters.
@@ -43,7 +43,7 @@
  */
 #ifdef	__NetBSD__
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: isp.c,v 1.125 2013/09/14 13:09:55 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: isp.c,v 1.126 2017/03/11 12:08:57 maya Exp $");
 #include <dev/ic/isp_netbsd.h>
 #endif
 #ifdef	__FreeBSD__
@@ -5114,7 +5114,7 @@ again:
 			 * If somebody updated the output pointer, then reset
 			 * optr to be one more than the updated amount.
 			 */
-			while (tsto != oop) {
+			if (tsto != oop) {
 				optr = ISP_NXT_QENTRY(tsto,
 				    RESULT_QUEUE_LEN(isp));
 			}

Reply via email to