diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-06-09 20:15:56 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-06-09 20:15:56 -0400 |
commit | 0b52a3c89c8f44d7a936da8b374789dc0f43b188 (patch) | |
tree | e43d677f78037bbf063f9c07de7b32dfa0bf87f6 | |
parent | 6dbda5bfe16bbb18af3ab249974daab9143be77f (diff) | |
parent | 509eb76ebf9771abc9fe51859382df2571f11447 (diff) |
Merge branch 'fixes' of git://git.linaro.org/people/rmk/linux-arm
Pull ARM fixes from Russell King:
"The biggest two fixes are fixing a compilation error with the
decompressor, and a problem with our __my_cpu_offset implementation.
Other changes are very trivial and small, which seems to be the way
for most -rc stuff."
* 'fixes' of git://git.linaro.org/people/rmk/linux-arm:
ARM: 7747/1: pcpu: ensure __my_cpu_offset cannot be re-ordered across barrier()
ARM: 7750/1: update legacy CPU ID in decompressor cache support jump table
ARM: 7743/1: compressed/head.S: work around new binutils warning
ARM: 7742/1: topology: export cpu_topology
ARM: 7737/1: fix kernel decompressor compilation error with CONFIG_DEBUG_SEMIHOSTING
-rw-r--r-- | arch/arm/boot/compressed/Makefile | 2 | ||||
-rw-r--r-- | arch/arm/boot/compressed/debug.S | 28 | ||||
-rw-r--r-- | arch/arm/boot/compressed/head-sa1100.S | 1 | ||||
-rw-r--r-- | arch/arm/boot/compressed/head-shark.S | 1 | ||||
-rw-r--r-- | arch/arm/boot/compressed/head.S | 5 | ||||
-rw-r--r-- | arch/arm/include/asm/percpu.h | 11 | ||||
-rw-r--r-- | arch/arm/kernel/topology.c | 2 |
7 files changed, 45 insertions, 5 deletions
diff --git a/arch/arm/boot/compressed/Makefile b/arch/arm/boot/compressed/Makefile index 3580d57ea218..79e9bdbfc491 100644 --- a/arch/arm/boot/compressed/Makefile +++ b/arch/arm/boot/compressed/Makefile | |||
@@ -124,7 +124,7 @@ KBUILD_CFLAGS = $(subst -pg, , $(ORIG_CFLAGS)) | |||
124 | endif | 124 | endif |
125 | 125 | ||
126 | ccflags-y := -fpic -mno-single-pic-base -fno-builtin -I$(obj) | 126 | ccflags-y := -fpic -mno-single-pic-base -fno-builtin -I$(obj) |
127 | asflags-y := -Wa,-march=all -DZIMAGE | 127 | asflags-y := -DZIMAGE |
128 | 128 | ||
129 | # Supply kernel BSS size to the decompressor via a linker symbol. | 129 | # Supply kernel BSS size to the decompressor via a linker symbol. |
130 | KBSS_SZ = $(shell $(CROSS_COMPILE)size $(obj)/../../../../vmlinux | \ | 130 | KBSS_SZ = $(shell $(CROSS_COMPILE)size $(obj)/../../../../vmlinux | \ |
diff --git a/arch/arm/boot/compressed/debug.S b/arch/arm/boot/compressed/debug.S index 6e8382d5b7a4..5392ee63338f 100644 --- a/arch/arm/boot/compressed/debug.S +++ b/arch/arm/boot/compressed/debug.S | |||
@@ -1,6 +1,8 @@ | |||
1 | #include <linux/linkage.h> | 1 | #include <linux/linkage.h> |
2 | #include <asm/assembler.h> | 2 | #include <asm/assembler.h> |
3 | 3 | ||
4 | #ifndef CONFIG_DEBUG_SEMIHOSTING | ||
5 | |||
4 | #include CONFIG_DEBUG_LL_INCLUDE | 6 | #include CONFIG_DEBUG_LL_INCLUDE |
5 | 7 | ||
6 | ENTRY(putc) | 8 | ENTRY(putc) |
@@ -10,3 +12,29 @@ ENTRY(putc) | |||
10 | busyuart r3, r1 | 12 | busyuart r3, r1 |
11 | mov pc, lr | 13 | mov pc, lr |
12 | ENDPROC(putc) | 14 | ENDPROC(putc) |
15 | |||
16 | #else | ||
17 | |||
18 | ENTRY(putc) | ||
19 | adr r1, 1f | ||
20 | ldmia r1, {r2, r3} | ||
21 | add r2, r2, r1 | ||
22 | ldr r1, [r2, r3] | ||
23 | strb r0, [r1] | ||
24 | mov r0, #0x03 @ SYS_WRITEC | ||
25 | ARM( svc #0x123456 ) | ||
26 | THUMB( svc #0xab ) | ||
27 | mov pc, lr | ||
28 | .align 2 | ||
29 | 1: .word _GLOBAL_OFFSET_TABLE_ - . | ||
30 | .word semi_writec_buf(GOT) | ||
31 | ENDPROC(putc) | ||
32 | |||
33 | .bss | ||
34 | .global semi_writec_buf | ||
35 | .type semi_writec_buf, %object | ||
36 | semi_writec_buf: | ||
37 | .space 4 | ||
38 | .size semi_writec_buf, 4 | ||
39 | |||
40 | #endif | ||
diff --git a/arch/arm/boot/compressed/head-sa1100.S b/arch/arm/boot/compressed/head-sa1100.S index 6179d94dd5c6..3115e313d9f6 100644 --- a/arch/arm/boot/compressed/head-sa1100.S +++ b/arch/arm/boot/compressed/head-sa1100.S | |||
@@ -11,6 +11,7 @@ | |||
11 | #include <asm/mach-types.h> | 11 | #include <asm/mach-types.h> |
12 | 12 | ||
13 | .section ".start", "ax" | 13 | .section ".start", "ax" |
14 | .arch armv4 | ||
14 | 15 | ||
15 | __SA1100_start: | 16 | __SA1100_start: |
16 | 17 | ||
diff --git a/arch/arm/boot/compressed/head-shark.S b/arch/arm/boot/compressed/head-shark.S index 089c560e07f1..92b56897ed64 100644 --- a/arch/arm/boot/compressed/head-shark.S +++ b/arch/arm/boot/compressed/head-shark.S | |||
@@ -18,6 +18,7 @@ | |||
18 | 18 | ||
19 | .section ".start", "ax" | 19 | .section ".start", "ax" |
20 | 20 | ||
21 | .arch armv4 | ||
21 | b __beginning | 22 | b __beginning |
22 | 23 | ||
23 | __ofw_data: .long 0 @ the number of memory blocks | 24 | __ofw_data: .long 0 @ the number of memory blocks |
diff --git a/arch/arm/boot/compressed/head.S b/arch/arm/boot/compressed/head.S index fe4d9c3ad761..032a8d987148 100644 --- a/arch/arm/boot/compressed/head.S +++ b/arch/arm/boot/compressed/head.S | |||
@@ -11,6 +11,7 @@ | |||
11 | #include <linux/linkage.h> | 11 | #include <linux/linkage.h> |
12 | #include <asm/assembler.h> | 12 | #include <asm/assembler.h> |
13 | 13 | ||
14 | .arch armv7-a | ||
14 | /* | 15 | /* |
15 | * Debugging stuff | 16 | * Debugging stuff |
16 | * | 17 | * |
@@ -805,8 +806,8 @@ call_cache_fn: adr r12, proc_types | |||
805 | .align 2 | 806 | .align 2 |
806 | .type proc_types,#object | 807 | .type proc_types,#object |
807 | proc_types: | 808 | proc_types: |
808 | .word 0x00000000 @ old ARM ID | 809 | .word 0x41000000 @ old ARM ID |
809 | .word 0x0000f000 | 810 | .word 0xff00f000 |
810 | mov pc, lr | 811 | mov pc, lr |
811 | THUMB( nop ) | 812 | THUMB( nop ) |
812 | mov pc, lr | 813 | mov pc, lr |
diff --git a/arch/arm/include/asm/percpu.h b/arch/arm/include/asm/percpu.h index 968c0a14e0a3..209e6504922e 100644 --- a/arch/arm/include/asm/percpu.h +++ b/arch/arm/include/asm/percpu.h | |||
@@ -30,8 +30,15 @@ static inline void set_my_cpu_offset(unsigned long off) | |||
30 | static inline unsigned long __my_cpu_offset(void) | 30 | static inline unsigned long __my_cpu_offset(void) |
31 | { | 31 | { |
32 | unsigned long off; | 32 | unsigned long off; |
33 | /* Read TPIDRPRW */ | 33 | register unsigned long *sp asm ("sp"); |
34 | asm("mrc p15, 0, %0, c13, c0, 4" : "=r" (off) : : "memory"); | 34 | |
35 | /* | ||
36 | * Read TPIDRPRW. | ||
37 | * We want to allow caching the value, so avoid using volatile and | ||
38 | * instead use a fake stack read to hazard against barrier(). | ||
39 | */ | ||
40 | asm("mrc p15, 0, %0, c13, c0, 4" : "=r" (off) : "Q" (*sp)); | ||
41 | |||
35 | return off; | 42 | return off; |
36 | } | 43 | } |
37 | #define __my_cpu_offset __my_cpu_offset() | 44 | #define __my_cpu_offset __my_cpu_offset() |
diff --git a/arch/arm/kernel/topology.c b/arch/arm/kernel/topology.c index f10316b4ecdc..c5a59546a256 100644 --- a/arch/arm/kernel/topology.c +++ b/arch/arm/kernel/topology.c | |||
@@ -13,6 +13,7 @@ | |||
13 | 13 | ||
14 | #include <linux/cpu.h> | 14 | #include <linux/cpu.h> |
15 | #include <linux/cpumask.h> | 15 | #include <linux/cpumask.h> |
16 | #include <linux/export.h> | ||
16 | #include <linux/init.h> | 17 | #include <linux/init.h> |
17 | #include <linux/percpu.h> | 18 | #include <linux/percpu.h> |
18 | #include <linux/node.h> | 19 | #include <linux/node.h> |
@@ -200,6 +201,7 @@ static inline void update_cpu_power(unsigned int cpuid, unsigned int mpidr) {} | |||
200 | * cpu topology table | 201 | * cpu topology table |
201 | */ | 202 | */ |
202 | struct cputopo_arm cpu_topology[NR_CPUS]; | 203 | struct cputopo_arm cpu_topology[NR_CPUS]; |
204 | EXPORT_SYMBOL_GPL(cpu_topology); | ||
203 | 205 | ||
204 | const struct cpumask *cpu_coregroup_mask(int cpu) | 206 | const struct cpumask *cpu_coregroup_mask(int cpu) |
205 | { | 207 | { |