Subject: Re: kern/25285: i386 MP panic: TLB IPI rendezvous failed (mask 1)
To: None <dokas@cs.umn.edu>
From: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
List: current-users
Date: 06/09/2004 23:46:08
--NextPart-20040609234350-0184200
Content-Type: Text/Plain; charset=us-ascii

hi,

> > The quad Xeon that I put this patch onto panic'd sometime on Friday night.
> > I'll put the detail here tomorrow after I've had a change to visit the
> > computer (I don't have a serial console on it yet).
> 
> I've looked over the machine and here's what I found.

it seems that Xspllower and Xdoreti also have a race window.
can you try the attached diff in addition to the previous intr.h one?

YAMAMOTO Takashi

--NextPart-20040609234350-0184200
Content-Type: Text/Plain; charset=us-ascii
Content-Disposition: attachment; filename="a.diff"

Index: spl.S
===================================================================
--- spl.S	(revision 708)
+++ spl.S	(working copy)
@@ -109,10 +109,8 @@ IDTVEC(spllower)
 	cli
 	andl	CPUVAR(IPENDING),%eax		# any non-masked bits left?
 	jz	2f
-	sti
 	bsrl	%eax,%eax
 	btrl	%eax,CPUVAR(IPENDING)
-	jnc	1b
 	movl	CPUVAR(ISOURCES)(,%eax,4),%eax
 	jmp	*IS_RECURSE(%eax)
 2:
@@ -143,10 +141,8 @@ IDTVEC(doreti)
 	cli
 	andl	CPUVAR(IPENDING),%eax
 	jz	2f
-	sti
 	bsrl    %eax,%eax               # slow, but not worth optimizing
 	btrl    %eax,CPUVAR(IPENDING)
-	jnc     1b			# some intr cleared the in-memory bit
 	movl	CPUVAR(ISOURCES)(,%eax, 4),%eax
 	jmp	*IS_RESUME(%eax)
 2:	/* Check for ASTs on exit to user mode. */
Index: vector.S
===================================================================
--- vector.S	(revision 671)
+++ vector.S	(working copy)
@@ -614,6 +614,7 @@ _C_LABEL(eintrcnt):
 
 IDTVEC(softserial)
 	movl	$IPL_SOFTSERIAL, CPUVAR(ILEVEL)
+	sti
 	incl	CPUVAR(IDEPTH)
 #ifdef MULTIPROCESSOR
 	call	_C_LABEL(x86_softintlock)
@@ -632,6 +633,7 @@ IDTVEC(softserial)
 
 IDTVEC(softnet)
 	movl	$IPL_SOFTNET, CPUVAR(ILEVEL)
+	sti
 	incl	CPUVAR(IDEPTH)
 #ifdef MULTIPROCESSOR	
 	call	_C_LABEL(x86_softintlock)
@@ -663,6 +665,7 @@ IDTVEC(softnet)
 
 IDTVEC(softclock)
 	movl	$IPL_SOFTCLOCK, CPUVAR(ILEVEL)
+	sti
 	incl	CPUVAR(IDEPTH)
 #ifdef MULTIPROCESSOR	
 	call	_C_LABEL(x86_softintlock)

--NextPart-20040609234350-0184200--