linux_dsm_epyc7002/arch/x86/kernel/apic
David Woodhouse b8ab21e017 x86/apic: Fix x2apic enablement without interrupt remapping
[ Upstream commit 26573a97746c7a99f394f9d398ce91a8853b3b89 ]

Currently, Linux as a hypervisor guest will enable x2apic only if there are
no CPUs present at boot time with an APIC ID above 255.

Hotplugging a CPU later with a higher APIC ID would result in a CPU which
cannot be targeted by external interrupts.

Add a filter in x2apic_apic_id_valid() which can be used to prevent such
CPUs from coming online, and allow x2apic to be enabled even if they are
present at boot time.

Fixes: ce69a78450 ("x86/apic: Enable x2APIC without interrupt remapping under KVM")
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/20201024213535.443185-2-dwmw2@infradead.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-12-30 11:52:59 +01:00
..
apic_common.c x86/apic: Fix signedness bug in APIC ID validity checks 2018-04-10 16:46:39 +02:00
apic_flat_64.c x86/apic/flat64: Remove the IPI shorthand decision logic 2019-07-25 16:12:02 +02:00
apic_noop.c locking/seqlock, headers: Untangle the spaghetti monster 2020-08-06 16:13:13 +02:00
apic_numachip.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
apic.c x86/apic: Fix x2apic enablement without interrupt remapping 2020-12-30 11:52:59 +01:00
bigsmp_32.c x86/headers: Remove APIC headers from <asm/smp.h> 2020-08-06 16:13:09 +02:00
hw_nmi.c locking/seqlock, headers: Untangle the spaghetti monster 2020-08-06 16:13:13 +02:00
io_apic.c Surgery of the MSI interrupt handling to prepare the support of upcoming 2020-10-12 11:40:41 -07:00
ipi.c x86/headers: Remove APIC headers from <asm/smp.h> 2020-08-06 16:13:09 +02:00
local.h x86/headers: Remove APIC headers from <asm/smp.h> 2020-08-06 16:13:09 +02:00
Makefile x86/PCI: Remove unused HyperTransport interrupt support 2017-11-23 20:18:18 +01:00
msi.c x86/apic/msi: Unbreak DMAR and HPET MSI 2020-09-27 21:53:41 +02:00
probe_32.c x86/irq: Move apic_post_init() invocation to one place 2020-09-16 16:52:35 +02:00
probe_64.c x86/irq: Move apic_post_init() invocation to one place 2020-09-16 16:52:35 +02:00
vector.c x86/apic/vector: Fix ordering in vector assignment 2020-12-10 23:00:54 +01:00
x2apic_cluster.c x86/apic/x2apic: Fix a NULL pointer deref when handling a dying cpu 2019-10-15 10:57:09 +02:00
x2apic_phys.c x86/apic: Fix x2apic enablement without interrupt remapping 2020-12-30 11:52:59 +01:00
x2apic_uv_x.c x86/platform/uv: Fix UV4 hub revision adjustment 2020-12-03 18:09:18 +01:00