From: Greg Kroah-Hartman Date: Sat, 15 Jun 2024 11:08:39 +0000 (+0200) Subject: 6.1-stable patches X-Git-Tag: v4.19.316~18 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=41cb80bada86ea0713ba796b6b9e077a53981bb8;p=thirdparty%2Fkernel%2Fstable-queue.git 6.1-stable patches added patches: smp-provide-setup_max_cpus-definition-on-up-too.patch --- diff --git a/queue-6.1/series b/queue-6.1/series index deda3fc9f1a..e93200a7b46 100644 --- a/queue-6.1/series +++ b/queue-6.1/series @@ -83,3 +83,4 @@ nfs-fix-read_plus-when-server-doesn-t-support-op_read_plus.patch btrfs-fix-crash-on-racing-fsync-and-size-extending-write-into-prealloc.patch powerpc-bpf-enforce-full-ordering-for-atomic-operations-with-bpf_fetch.patch smb-client-fix-deadlock-in-smb2_find_smb_tcon.patch +smp-provide-setup_max_cpus-definition-on-up-too.patch diff --git a/queue-6.1/smp-provide-setup_max_cpus-definition-on-up-too.patch b/queue-6.1/smp-provide-setup_max_cpus-definition-on-up-too.patch new file mode 100644 index 00000000000..43134ad8e62 --- /dev/null +++ b/queue-6.1/smp-provide-setup_max_cpus-definition-on-up-too.patch @@ -0,0 +1,44 @@ +From 3c2f8859ae1ce53f2a89c8e4ca4092101afbff67 Mon Sep 17 00:00:00 2001 +From: Ingo Molnar +Date: Mon, 26 Feb 2024 12:07:31 +0100 +Subject: smp: Provide 'setup_max_cpus' definition on UP too + +From: Ingo Molnar + +commit 3c2f8859ae1ce53f2a89c8e4ca4092101afbff67 upstream. + +This was already defined locally by init/main.c, but let's make +it generic, as arch/x86/kernel/cpu/topology.c is going to make +use of it to have more uniform code. + +Reviewed-by: Thomas Gleixner +Cc: linux-kernel@vger.kernel.org +Signed-off-by: Ingo Molnar +Cc: Guenter Roeck +Signed-off-by: Greg Kroah-Hartman +--- + include/linux/smp.h | 2 ++ + init/main.c | 1 - + 2 files changed, 2 insertions(+), 1 deletion(-) + +--- a/include/linux/smp.h ++++ b/include/linux/smp.h +@@ -211,6 +211,8 @@ smp_call_function_any(const struct cpuma + static inline void kick_all_cpus_sync(void) { } + static inline void wake_up_all_idle_cpus(void) { } + ++#define setup_max_cpus 0 ++ + #ifdef CONFIG_UP_LATE_INIT + extern void __init up_late_init(void); + static inline void smp_init(void) { up_late_init(); } +--- a/init/main.c ++++ b/init/main.c +@@ -607,7 +607,6 @@ static int __init rdinit_setup(char *str + __setup("rdinit=", rdinit_setup); + + #ifndef CONFIG_SMP +-static const unsigned int setup_max_cpus = NR_CPUS; + static inline void setup_nr_cpu_ids(void) { } + static inline void smp_prepare_cpus(unsigned int maxcpus) { } + #endif