diff options
author | Arnd Bergmann <arnd@arndb.de> | 2019-08-09 12:33:19 -0400 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2019-08-14 09:36:22 -0400 |
commit | c7b68049943079550d4e6af0f10aa3aabd64131a (patch) | |
tree | 4d61d56f058775c3c6b55a7f65bb418e7b545547 /arch/arm/mm | |
parent | aad7ad2a01e774f5cd0dde8f0bc6e253ae3f0d35 (diff) |
ARM: xscale: fix multi-cpu compilation
Building a combined ARMv4+XScale kernel produces these
and other build failures:
/tmp/copypage-xscale-3aa821.s: Assembler messages:
/tmp/copypage-xscale-3aa821.s:167: Error: selected processor does not support `pld [r7,#0]' in ARM mode
/tmp/copypage-xscale-3aa821.s:168: Error: selected processor does not support `pld [r7,#32]' in ARM mode
/tmp/copypage-xscale-3aa821.s:169: Error: selected processor does not support `pld [r1,#0]' in ARM mode
/tmp/copypage-xscale-3aa821.s:170: Error: selected processor does not support `pld [r1,#32]' in ARM mode
/tmp/copypage-xscale-3aa821.s:171: Error: selected processor does not support `pld [r7,#64]' in ARM mode
/tmp/copypage-xscale-3aa821.s:176: Error: selected processor does not support `ldrd r4,r5,[r7],#8' in ARM mode
/tmp/copypage-xscale-3aa821.s:180: Error: selected processor does not support `strd r4,r5,[r1],#8' in ARM mode
Add an explict .arch armv5 in the inline assembly to allow the ARMv5
specific instructions regardless of the compiler -march= target.
Link: https://lore.kernel.org/r/20190809163334.489360-5-arnd@arndb.de
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/arm/mm')
-rw-r--r-- | arch/arm/mm/copypage-xscale.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/arm/mm/copypage-xscale.c b/arch/arm/mm/copypage-xscale.c index 61d834157bc0..382e1c2855e8 100644 --- a/arch/arm/mm/copypage-xscale.c +++ b/arch/arm/mm/copypage-xscale.c | |||
@@ -42,6 +42,7 @@ static void mc_copy_user_page(void *from, void *to) | |||
42 | * when prefetching destination as well. (NP) | 42 | * when prefetching destination as well. (NP) |
43 | */ | 43 | */ |
44 | asm volatile ("\ | 44 | asm volatile ("\ |
45 | .arch xscale \n\ | ||
45 | pld [%0, #0] \n\ | 46 | pld [%0, #0] \n\ |
46 | pld [%0, #32] \n\ | 47 | pld [%0, #32] \n\ |
47 | pld [%1, #0] \n\ | 48 | pld [%1, #0] \n\ |
@@ -106,8 +107,9 @@ void | |||
106 | xscale_mc_clear_user_highpage(struct page *page, unsigned long vaddr) | 107 | xscale_mc_clear_user_highpage(struct page *page, unsigned long vaddr) |
107 | { | 108 | { |
108 | void *ptr, *kaddr = kmap_atomic(page); | 109 | void *ptr, *kaddr = kmap_atomic(page); |
109 | asm volatile( | 110 | asm volatile("\ |
110 | "mov r1, %2 \n\ | 111 | .arch xscale \n\ |
112 | mov r1, %2 \n\ | ||
111 | mov r2, #0 \n\ | 113 | mov r2, #0 \n\ |
112 | mov r3, #0 \n\ | 114 | mov r3, #0 \n\ |
113 | 1: mov ip, %0 \n\ | 115 | 1: mov ip, %0 \n\ |