Flag EOI on TLB shootdown IPIs after the shootdown has been processed.

This commit is contained in:
ad 2020-05-17 14:15:55 +00:00
parent 972d99cea6
commit 5351e0b6c5
2 changed files with 10 additions and 10 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: vector.S,v 1.76 2020/05/01 07:03:02 maxv Exp $ */ /* $NetBSD: vector.S,v 1.77 2020/05/17 14:15:55 ad Exp $ */
/* /*
* Copyright (c) 1998, 2007, 2008 The NetBSD Foundation, Inc. * Copyright (c) 1998, 2007, 2008 The NetBSD Foundation, Inc.
@ -314,21 +314,21 @@ IDTVEC_END(intr_hyperv_hypercall)
* TLB shootdown handler. * TLB shootdown handler.
*/ */
IDTVEC(handle_lapic_tlb) IDTVEC(handle_lapic_tlb)
movq _C_LABEL(local_apic_va),%rax
movl $0,LAPIC_EOI(%rax)
KCOV_DISABLE KCOV_DISABLE
callq _C_LABEL(pmap_tlb_intr) callq _C_LABEL(pmap_tlb_intr)
KCOV_ENABLE KCOV_ENABLE
movq _C_LABEL(local_apic_va),%rax
movl $0,LAPIC_EOI(%rax)
INTRFASTEXIT INTRFASTEXIT
IDTVEC_END(handle_lapic_tlb) IDTVEC_END(handle_lapic_tlb)
IDTVEC(handle_x2apic_tlb) IDTVEC(handle_x2apic_tlb)
KCOV_DISABLE
callq _C_LABEL(pmap_tlb_intr)
KCOV_ENABLE
movl $(MSR_X2APIC_BASE + MSR_X2APIC_EOI),%ecx movl $(MSR_X2APIC_BASE + MSR_X2APIC_EOI),%ecx
xorl %eax,%eax xorl %eax,%eax
xorl %edx,%edx xorl %edx,%edx
wrmsr wrmsr
KCOV_DISABLE
callq _C_LABEL(pmap_tlb_intr)
KCOV_ENABLE
INTRFASTEXIT INTRFASTEXIT
IDTVEC_END(handle_x2apic_tlb) IDTVEC_END(handle_x2apic_tlb)

View File

@ -1,4 +1,4 @@
/* $NetBSD: vector.S,v 1.86 2020/04/25 15:26:17 bouyer Exp $ */ /* $NetBSD: vector.S,v 1.87 2020/05/17 14:15:55 ad Exp $ */
/* /*
* Copyright 2002 (c) Wasabi Systems, Inc. * Copyright 2002 (c) Wasabi Systems, Inc.
@ -65,7 +65,7 @@
*/ */
#include <machine/asm.h> #include <machine/asm.h>
__KERNEL_RCSID(0, "$NetBSD: vector.S,v 1.86 2020/04/25 15:26:17 bouyer Exp $"); __KERNEL_RCSID(0, "$NetBSD: vector.S,v 1.87 2020/05/17 14:15:55 ad Exp $");
#include "opt_ddb.h" #include "opt_ddb.h"
#include "opt_multiprocessor.h" #include "opt_multiprocessor.h"
@ -201,9 +201,9 @@ IDTVEC(intr_lapic_tlb)
pushl $0 pushl $0
pushl $T_ASTFLT pushl $T_ASTFLT
INTRENTRY INTRENTRY
call _C_LABEL(pmap_tlb_intr)
movl _C_LABEL(local_apic_va),%eax movl _C_LABEL(local_apic_va),%eax
movl $0,LAPIC_EOI(%eax) movl $0,LAPIC_EOI(%eax)
call _C_LABEL(pmap_tlb_intr)
INTRFASTEXIT INTRFASTEXIT
IDTVEC_END(intr_lapic_tlb) IDTVEC_END(intr_lapic_tlb)
@ -211,11 +211,11 @@ IDTVEC(intr_x2apic_tlb)
pushl $0 pushl $0
pushl $T_ASTFLT pushl $T_ASTFLT
INTRENTRY INTRENTRY
call _C_LABEL(pmap_tlb_intr)
movl $(MSR_X2APIC_BASE + MSR_X2APIC_EOI),%ecx movl $(MSR_X2APIC_BASE + MSR_X2APIC_EOI),%ecx
xorl %eax,%eax xorl %eax,%eax
xorl %edx,%edx xorl %edx,%edx
wrmsr wrmsr
call _C_LABEL(pmap_tlb_intr)
INTRFASTEXIT INTRFASTEXIT
IDTVEC_END(intr_x2apic_tlb) IDTVEC_END(intr_x2apic_tlb)