Skip to content

Commit 1146b60

Browse files
committed
ARM: sunxi: fix build for THUMB2_KERNEL
Building an SMP kernel for the sunxi platform with THUMB2 instructions fails with this error at the moment: headsmp.S:7: Error: Thumb encoding does not support an immediate here -- `msr cpsr_fsxc,#0xd3' Since the generic secondary_startup function already does the same thing in a safe way, we can just drop the private sunxi implementation and jump straight to secondary_startup. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Maxime Ripard <maxime.ripard@free-electrons.com>
1 parent 96c3a25 commit 1146b60

4 files changed

Lines changed: 3 additions & 11 deletions

File tree

‎arch/arm/include/asm/smp.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ struct secondary_data {
7474
};
7575
extern struct secondary_data secondary_data;
7676
extern volatile int pen_release;
77+
extern void secondary_startup(void);
7778

7879
extern int __cpu_disable(void);
7980

‎arch/arm/mach-sunxi/Makefile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
obj-$(CONFIG_ARCH_SUNXI) += sunxi.o
2-
obj-$(CONFIG_SMP) += platsmp.o headsmp.o
2+
obj-$(CONFIG_SMP) += platsmp.o

‎arch/arm/mach-sunxi/headsmp.S‎

Lines changed: 0 additions & 9 deletions
This file was deleted.

‎arch/arm/mach-sunxi/platsmp.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ static int sun6i_smp_boot_secondary(unsigned int cpu,
8282
spin_lock(&cpu_lock);
8383

8484
/* Set CPU boot address */
85-
writel(virt_to_phys(sun6i_secondary_startup),
85+
writel(virt_to_phys(secondary_startup),
8686
cpucfg_membase + CPUCFG_PRIVATE0_REG);
8787

8888
/* Assert the CPU core in reset */

0 commit comments

Comments
 (0)