PERFORCE change 65337 for review

John Baldwin jhb at FreeBSD.org
Wed Nov 17 07:57:34 PST 2004


http://perforce.freebsd.org/chv.cgi?CH=65337

Change 65337 by jhb at jhb_slimer on 2004/11/17 15:57:30

	Get rid of the 'storming' variable altogether.

Affected files ...

.. //depot/projects/smpng/sys/kern/kern_intr.c#62 edit

Differences ...

==== //depot/projects/smpng/sys/kern/kern_intr.c#62 (text+ko) ====

@@ -485,7 +485,7 @@
 	struct intrhand *ih;		/* and our interrupt handler chain */
 	struct thread *td;
 	struct proc *p;
-	int count, warned, storming;
+	int count, warned;
 	
 	td = curthread;
 	p = td->td_proc;
@@ -494,7 +494,6 @@
 	    ("%s: ithread and proc linkage out of sync", __func__));
 	count = 0;
 	warned = 0;
-	storming = 0;
 
 	/*
 	 * As long as we have interrupts outstanding, go through the
@@ -561,7 +560,7 @@
 			 * interrupts exceeds the storm threshold, then
 			 * enter storming mode.
 			 */
-			if (!storming && intr_storm_threshold != 0 &&
+			if (intr_storm_threshold != 0 &&
 			    count >= intr_storm_threshold) {
 				if (!warned) {
 					printf(
@@ -569,9 +568,6 @@
 					    p->p_comm);
 					warned = 1;
 				}
-				storming = 1;
-			}
-			if (storming)
 				tsleep(&count, td->td_priority, "istorm", 1);
 			else
 				count++;
@@ -591,7 +587,6 @@
 		if (!ithd->it_need) {
 			TD_SET_IWAIT(td);
 			count = 0;
-			storming = 0;
 			CTR2(KTR_INTR, "%s: pid %d: done", __func__, p->p_pid);
 			mi_switch(SW_VOL, NULL);
 			CTR2(KTR_INTR, "%s: pid %d: resumed", __func__, p->p_pid);


More information about the p4-projects mailing list