Skip to contentSkip to conversation

MIPS: lantiq: register smp_ops on non-smp platforms

PATCH Applied Aleksander Jan Bajkowski 2 participants 2 messages Jan 22, 2024 – Jan 26, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 MIPS: lantiq: register smp_ops on non-smp platforms

Lantiq uses a common kernel config for devices with 24Kc and 34Kc cores. The changes made previously to add support for interrupts on all cores work on 24Kc platforms with SMP disabled and 34Kc platforms with SMP enabled. This patch fixes boot issues on Danube (single core 24Kc) with SMP enabled.

Fixes 730320fd770d ("MIPS: lantiq: enable all hardware interrupts on second VPE")
---
 arch/mips/lantiq/prom.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
arch/mips/lantiq/prom.c +3 -4
index a3cf29365858..0c45767eacf6 100644
@@ -108,10 +108,9 @@ void __init prom_init(void)
 	prom_init_cmdline();
 
 #if defined(CONFIG_MIPS_MT_SMP)
-	if (cpu_has_mipsmt) {
-		lantiq_smp_ops = vsmp_smp_ops;
+	lantiq_smp_ops = vsmp_smp_ops;
+	if (cpu_has_mipsmt)
 		lantiq_smp_ops.init_secondary = lantiq_init_secondary;
-		register_smp_ops(&lantiq_smp_ops);
-	}
+	register_smp_ops(&lantiq_smp_ops);
 #endif
 }
Signature · 1 line
2.39.2
maintainer Applied
#1 lore raw
Quoted 32 lines · Aleksander Jan Bajkowski

Lantiq uses a common kernel config for devices with 24Kc and 34Kc cores. The changes made previously to add support for interrupts on all cores work on 24Kc platforms with SMP disabled and 34Kc platforms with SMP enabled. This patch fixes boot issues on Danube (single core 24Kc) with SMP enabled.

Fixes 730320fd770d ("MIPS: lantiq: enable all hardware interrupts on second VPE")
---
 arch/mips/lantiq/prom.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
arch/mips/lantiq/prom.c +3 -4
index a3cf29365858..0c45767eacf6 100644
@@ -108,10 +108,9 @@ void __init prom_init(void)
 	prom_init_cmdline();
 
 #if defined(CONFIG_MIPS_MT_SMP)
-	if (cpu_has_mipsmt) {
-		lantiq_smp_ops = vsmp_smp_ops;
+	lantiq_smp_ops = vsmp_smp_ops;
+	if (cpu_has_mipsmt)
 		lantiq_smp_ops.init_secondary = lantiq_init_secondary;
-		register_smp_ops(&lantiq_smp_ops);
-	}
+	register_smp_ops(&lantiq_smp_ops);
 #endif
 }
Signature · 1 line
2.39.2

applied to mips-fixes.

Thomas.

Signature · 2 lines
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]