From 177e13513644b4d3de2529468e827ebfcadbda02 Mon Sep 17 00:00:00 2001 From: Arthur Heymans Date: Fri, 4 Nov 2022 13:03:23 +0100 Subject: cpu/x86/topology: Add code to fill in topology on struct path This is needed to generate MADT and SRAT where lapicid for threads need to be added last. When CPUID leaf '0xB' is not present assume some defaults that would result in identical ACPI code generation. Change-Id: I2210eb9b663dd90941a64132aa7154440dc7e5a9 Signed-off-by: Arthur Heymans Reviewed-on: https://review.coreboot.org/c/coreboot/+/69222 Reviewed-by: Maximilian Brune Reviewed-by: Patrick Rudolph Tested-by: build bot (Jenkins) --- src/include/cpu/x86/topology.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 src/include/cpu/x86/topology.h (limited to 'src/include/cpu/x86/topology.h') diff --git a/src/include/cpu/x86/topology.h b/src/include/cpu/x86/topology.h new file mode 100644 index 0000000000..db29d09f5b --- /dev/null +++ b/src/include/cpu/x86/topology.h @@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ + +#ifndef CPU_X86_TOPOLOGY_H +#define CPU_X86_TOPOLOGY_H + +#include + +/* Fill in the topology in struct path APIC based CPUID EAX=0xb. + * If leaf 0xb is not supported or is not implemented then no topology + * will be filled in. + */ +void set_cpu_topology_from_leaf_b(struct device *cpu); + +#endif -- cgit v1.2.3