> From: K R <[email protected]>
> Date: Thu, 25 Dec 2025 14:45:54 -0300
> 
> On Thu, Dec 25, 2025 at 2:11 PM Mark Kettenis <[email protected]> wrote:
> >
> > > From: K R <[email protected]>
> > > Date: Wed, 24 Dec 2025 10:43:34 -0300
> > >
> > > On Tue, Dec 23, 2025 at 6:07 PM Miod Vallat <[email protected]> wrote:
> > > >
> > > > > Hi, thanks for the diff -- I've just applied it.  According to
> > > > > KASSERT(9), DIAGNOSTIC must be enabled in the kernel.  Could you
> > > > > confirm that?
> > > >
> > > > DIAGNOSTIC is enabled in GENERIC and GENERIC.MP kernels.
> > >
> > > You're right, of course.  I've applied your patch  -- the machine hung
> > > building lang/rust, but I got a protection fault again.  The ddb
> > > session is still on, in case you need symbols examined.
> >
> > Can you send us the dmesg for this machine?
> 
> Sure.

Thanks.  Can you try the diff below?


Index: arch/amd64/amd64/lapic.c
===================================================================
RCS file: /cvs/src/sys/arch/amd64/amd64/lapic.c,v
diff -u -p -r1.76 lapic.c
--- arch/amd64/amd64/lapic.c    12 Nov 2025 09:48:52 -0000      1.76
+++ arch/amd64/amd64/lapic.c    26 Dec 2025 09:37:33 -0000
@@ -691,6 +691,7 @@ x2apic_ipi(int vec, int target, int dl)
 
        lo = (target & LAPIC_DEST_MASK) | vec | dl | LAPIC_LVL_ASSERT;
 
+       __asm volatile("mfence; lfence" ::: "memory");
        x2apic_writeicr(hi, lo);
 }
 

Reply via email to