[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230724132047.495400662@linutronix.de>
Date: Mon, 24 Jul 2023 15:35:09 +0200 (CEST)
From: Thomas Gleixner <tglx@...utronix.de>
To: LKML <linux-kernel@...r.kernel.org>
Cc: x86@...nel.org, Andrew Cooper <andrew.cooper3@...rix.com>,
Tom Lendacky <thomas.lendacky@....com>,
Paolo Bonzini <pbonzini@...hat.com>,
Wei Liu <wei.liu@...nel.org>,
Arjan van de Ven <arjan@...ux.intel.com>,
Juergen Gross <jgross@...e.com>,
Michael Kelley <mikelley@...rosoft.com>,
Peter Keresztes Schmidt <peter@...esztesschmidt.de>,
"Peter Zijlstra (Intel)" <peterz@...radead.org>
Subject: [patch V2 49/58] x86/apic: Wrap apic->native_eoi() into a helper
Prepare for converting the hotpath APIC callbacks to static calls.
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Acked-by: Peter Zijlstra (Intel) <peterz@...radead.org>
---
arch/x86/include/asm/apic.h | 6 ++++++
arch/x86/kernel/kvm.c | 2 +-
2 files changed, 7 insertions(+), 1 deletion(-)
--- a/arch/x86/include/asm/apic.h
+++ b/arch/x86/include/asm/apic.h
@@ -359,6 +359,11 @@ static inline void apic_eoi(void)
apic->eoi();
}
+static inline void apic_native_eoi(void)
+{
+ apic->native_eoi();
+}
+
static inline u64 apic_icr_read(void)
{
return apic->icr_read();
@@ -397,6 +402,7 @@ static inline void apic_icr_write(u32 lo
static inline void apic_wait_icr_idle(void) { }
static inline u32 safe_apic_wait_icr_idle(void) { return 0; }
static inline void apic_set_eoi_cb(void (*eoi)(void)) {}
+static inline void apic_native_eoi(void) { WARN_ON_ONCE(1); }
#endif /* CONFIG_X86_LOCAL_APIC */
--- a/arch/x86/kernel/kvm.c
+++ b/arch/x86/kernel/kvm.c
@@ -343,7 +343,7 @@ static notrace void kvm_guest_apic_eoi_w
*/
if (__test_and_clear_bit(KVM_PV_EOI_BIT, this_cpu_ptr(&kvm_apic_eoi)))
return;
- apic->native_eoi();
+ apic_native_eoi();
}
static void kvm_guest_cpu_init(void)
Powered by blists - more mailing lists