From d92e5e7cf580ac59678fa40fd99aa8eb00f1ff52 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Tue, 8 Aug 2023 15:04:10 -0700 Subject: x86/apic: Add max_apic_id member There is really no point to have a callback which compares numbers. Add a field which allows each APIC to store the maximum APIC ID supported and fill it in for all APIC incarnations. The next step will remove the callback. Signed-off-by: Thomas Gleixner Signed-off-by: Dave Hansen Acked-by: Peter Zijlstra (Intel) Tested-by: Michael Kelley Tested-by: Sohil Mehta Tested-by: Juergen Gross # Xen PV (dom0 and unpriv. guest) --- arch/x86/kernel/apic/apic_flat_64.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'arch/x86/kernel/apic/apic_flat_64.c') diff --git a/arch/x86/kernel/apic/apic_flat_64.c b/arch/x86/kernel/apic/apic_flat_64.c index 1da865f9c657..b5e85bb021a1 100644 --- a/arch/x86/kernel/apic/apic_flat_64.c +++ b/arch/x86/kernel/apic/apic_flat_64.c @@ -94,6 +94,7 @@ static struct apic apic_flat __ro_after_init = { .cpu_present_to_apicid = default_cpu_present_to_apicid, .phys_pkg_id = flat_phys_pkg_id, + .max_apic_id = 0xFE, .get_apic_id = flat_get_apic_id, .set_apic_id = set_apic_id, @@ -170,6 +171,7 @@ static struct apic apic_physflat __ro_after_init = { .cpu_present_to_apicid = default_cpu_present_to_apicid, .phys_pkg_id = flat_phys_pkg_id, + .max_apic_id = 0xFE, .get_apic_id = flat_get_apic_id, .set_apic_id = set_apic_id, -- cgit v1.2.3