[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <172260875222.2215.17271320395978189545.tip-bot2@tip-bot2>
Date: Fri, 02 Aug 2024 14:25:52 -0000
From: "tip-bot2 for Jiaxun Yang" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Jiaxun Yang <jiaxun.yang@...goat.com>,
Thomas Gleixner <tglx@...utronix.de>, x86@...nel.org,
linux-kernel@...r.kernel.org
Subject:
[tip: smp/core] cpu/hotplug: Make HOTPLUG_PARALLEL independent of HOTPLUG_SMT
The following commit has been merged into the smp/core branch of tip:
Commit-ID: c0e81a455e23f77683178b8ae32651df5841f065
Gitweb: https://git.kernel.org/tip/c0e81a455e23f77683178b8ae32651df5841f065
Author: Jiaxun Yang <jiaxun.yang@...goat.com>
AuthorDate: Tue, 16 Jul 2024 22:14:58 +08:00
Committer: Thomas Gleixner <tglx@...utronix.de>
CommitterDate: Fri, 02 Aug 2024 16:06:36 +02:00
cpu/hotplug: Make HOTPLUG_PARALLEL independent of HOTPLUG_SMT
Provide stub functions for SMT related parallel bring up functions so that
HOTPLUG_PARALLEL can work without HOTPLUG_SMT.
Signed-off-by: Jiaxun Yang <jiaxun.yang@...goat.com>
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Link: https://lore.kernel.org/all/20240716-loongarch-hotplug-v3-1-af59b3bb35c8@flygoat.com
---
kernel/cpu.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/kernel/cpu.c b/kernel/cpu.c
index 1209dda..c89e0e9 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -1808,6 +1808,7 @@ static int __init parallel_bringup_parse_param(char *arg)
}
early_param("cpuhp.parallel", parallel_bringup_parse_param);
+#ifdef CONFIG_HOTPLUG_SMT
static inline bool cpuhp_smt_aware(void)
{
return cpu_smt_max_threads > 1;
@@ -1817,6 +1818,16 @@ static inline const struct cpumask *cpuhp_get_primary_thread_mask(void)
{
return cpu_primary_thread_mask;
}
+#else
+static inline bool cpuhp_smt_aware(void)
+{
+ return false;
+}
+static inline const struct cpumask *cpuhp_get_primary_thread_mask(void)
+{
+ return cpu_none_mask;
+}
+#endif
/*
* On architectures which have enabled parallel bringup this invokes all BP
Powered by blists - more mailing lists