Skip to content

Hacks to allow booting ARM SMP kernel on UP ARMv7

Tony Lindgren linux-arm-kernel linux-omap 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest0 of 4 patches 0 repliesNew

Patches in v1 No applies recorded yet

None of the 4 patches the cover letter announces are in this archive.

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] Hacks to allow booting ARM SMP kernel on UP ARMv7
Quoted 16 lines · Russell King - ARM Linux

arch/arm/kernel/head.S __fixup_smp: · line 352

Quoted 12 lines · Tony Lindgren
arch/arm/kernel/head.S +4 -2
@@ -346,8 +346,10 @@ __fixup_smp:
 	bne	smp_on_up		@ no, assume UP
 	mrc	p15, 0, r0, c0, c0, 5	@ read MIDR
 	movs	r0, r0, lsr #30
-	teqne	r0, #3			@ check top two bits 00 or 11
-	moveq	pc, lr
+	teq	r0, #0			@ check two top bits 00
+	beq	smp_on_up		@ yes, assume UP
+	teq	r0, #3			@ check top two bits 11
+	movne	pc, lr			@ no, running on SMP hw

This should be:

Quoted 5 lines
	movs	r0, r0, lsr #30
	teqne	r0, #3
	movne	pc, lr

so that 0 or 3 avoids the return.

Actually should also handle value of 1:

31 30
0 0 Not using new register, assume not SMP
0 1 Not using new register, assume not SMP
1 0 Using new register, SMP
1 1 Using new register, UP

So we should return early only if it's 2.

Regards,

Tony