x86/cpu/topology: Retrieve cores per package from topology bitmaps
authorThomas Gleixner <tglx@linutronix.de>
Tue, 13 Feb 2024 21:06:10 +0000 (22:06 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 15 Feb 2024 21:07:45 +0000 (22:07 +0100)
commit3205c9833d69b97e8694efe3e193312dea4c571f
tree8d15d470f15dcf272831365b1844c0ad522b8daf
parent380414be78bf8dbe1c3ed98feb75e2579c4a1bae
x86/cpu/topology: Retrieve cores per package from topology bitmaps

Similar to other sizing information the number of cores per package can be
established from the topology bitmap.

Provide a function for retrieving that information and replace the buggy
hack in the CPUID evaluation with it.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Michael Kelley <mhklinux@outlook.com>
Tested-by: Sohil Mehta <sohil.mehta@intel.com>
Link: https://lore.kernel.org/r/20240213210252.956858282@linutronix.de
arch/x86/kernel/cpu/topology.c
arch/x86/kernel/cpu/topology.h
arch/x86/kernel/cpu/topology_common.c