From 09c7513ec86caec1a1c304cf34d512011712f5c4 Mon Sep 17 00:00:00 2001 From: Simon Gaiser Date: Wed, 7 Feb 2018 18:30:53 +0100 Subject: [PATCH 1/2] Revert "x86/smpboot: Do not use smp_num_siblings in __max_logical_packages calculation" This reverts commit 947134d9b00f342415af7eddd42a5fce7262a1b9. --- arch/x86/kernel/smpboot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c index ed556d50d7ed..3dd6a6a5ffbc 100644 --- a/arch/x86/kernel/smpboot.c +++ b/arch/x86/kernel/smpboot.c @@ -106,7 +106,7 @@ EXPORT_SYMBOL(__max_logical_packages); static unsigned int logical_packages __read_mostly; /* Maximum number of SMT threads on any online core */ -int __read_mostly __max_smt_threads = 1; +int __max_smt_threads __read_mostly; /* Flag to indicate if a complete sched domain rebuild is required */ bool x86_topology_update; @@ -1291,7 +1291,7 @@ void __init native_smp_cpus_done(unsigned int max_cpus) * Today neither Intel nor AMD support heterogenous systems so * extrapolate the boot cpu's data to all packages. */ - ncpus = cpu_data(0).booted_cores * topology_max_smt_threads(); + ncpus = cpu_data(0).booted_cores * smp_num_siblings; __max_logical_packages = DIV_ROUND_UP(nr_cpu_ids, ncpus); pr_info("Max logical packages: %u\n", __max_logical_packages); -- 2.15.1