diff options
Diffstat (limited to 'arch/arm/lib')
-rw-r--r-- | arch/arm/lib/Makefile | 2 | ||||
-rw-r--r-- | arch/arm/lib/backtrace.S | 2 | ||||
-rw-r--r-- | arch/arm/lib/copy_template.S | 2 | ||||
-rw-r--r-- | arch/arm/lib/delay.S | 20 | ||||
-rw-r--r-- | arch/arm/lib/io-acorn.S | 1 |
5 files changed, 15 insertions, 12 deletions
diff --git a/arch/arm/lib/Makefile b/arch/arm/lib/Makefile index 391f3ab3ff32..7b726b627ea5 100644 --- a/arch/arm/lib/Makefile +++ b/arch/arm/lib/Makefile | |||
@@ -18,7 +18,7 @@ lib-y := backtrace.o changebit.o csumipv6.o csumpartial.o \ | |||
18 | 18 | ||
19 | # the code in uaccess.S is not preemption safe and | 19 | # the code in uaccess.S is not preemption safe and |
20 | # probably faster on ARMv3 only | 20 | # probably faster on ARMv3 only |
21 | ifeq ($CONFIG_PREEMPT,y) | 21 | ifeq ($(CONFIG_PREEMPT),y) |
22 | lib-y += copy_from_user.o copy_to_user.o | 22 | lib-y += copy_from_user.o copy_to_user.o |
23 | else | 23 | else |
24 | ifneq ($(CONFIG_CPU_32v3),y) | 24 | ifneq ($(CONFIG_CPU_32v3),y) |
diff --git a/arch/arm/lib/backtrace.S b/arch/arm/lib/backtrace.S index 68a21c0f3f52..3bdc8c6949c5 100644 --- a/arch/arm/lib/backtrace.S +++ b/arch/arm/lib/backtrace.S | |||
@@ -29,7 +29,7 @@ ENTRY(__backtrace) | |||
29 | 29 | ||
30 | ENTRY(c_backtrace) | 30 | ENTRY(c_backtrace) |
31 | 31 | ||
32 | #ifndef CONFIG_FRAME_POINTER | 32 | #if !defined(CONFIG_FRAME_POINTER) || !defined(CONFIG_PRINTK) |
33 | mov pc, lr | 33 | mov pc, lr |
34 | #else | 34 | #else |
35 | 35 | ||
diff --git a/arch/arm/lib/copy_template.S b/arch/arm/lib/copy_template.S index 838e435e4922..cab355c0c1f7 100644 --- a/arch/arm/lib/copy_template.S +++ b/arch/arm/lib/copy_template.S | |||
@@ -236,7 +236,7 @@ | |||
236 | 236 | ||
237 | 237 | ||
238 | /* | 238 | /* |
239 | * Abort preanble and completion macros. | 239 | * Abort preamble and completion macros. |
240 | * If a fixup handler is required then those macros must surround it. | 240 | * If a fixup handler is required then those macros must surround it. |
241 | * It is assumed that the fixup code will handle the private part of | 241 | * It is assumed that the fixup code will handle the private part of |
242 | * the exit macro. | 242 | * the exit macro. |
diff --git a/arch/arm/lib/delay.S b/arch/arm/lib/delay.S index b3fb475b4120..9183b06c0e2f 100644 --- a/arch/arm/lib/delay.S +++ b/arch/arm/lib/delay.S | |||
@@ -9,28 +9,32 @@ | |||
9 | */ | 9 | */ |
10 | #include <linux/linkage.h> | 10 | #include <linux/linkage.h> |
11 | #include <asm/assembler.h> | 11 | #include <asm/assembler.h> |
12 | #include <asm/param.h> | ||
12 | .text | 13 | .text |
13 | 14 | ||
14 | .LC0: .word loops_per_jiffy | 15 | .LC0: .word loops_per_jiffy |
16 | .LC1: .word (2199023*HZ)>>11 | ||
15 | 17 | ||
16 | /* | 18 | /* |
17 | * 0 <= r0 <= 2000 | 19 | * r0 <= 2000 |
20 | * lpj <= 0x01ffffff (max. 3355 bogomips) | ||
21 | * HZ <= 1000 | ||
18 | */ | 22 | */ |
23 | |||
19 | ENTRY(__udelay) | 24 | ENTRY(__udelay) |
20 | mov r2, #0x6800 | 25 | ldr r2, .LC1 |
21 | orr r2, r2, #0x00db | ||
22 | mul r0, r2, r0 | 26 | mul r0, r2, r0 |
23 | ENTRY(__const_udelay) @ 0 <= r0 <= 0x01ffffff | 27 | ENTRY(__const_udelay) @ 0 <= r0 <= 0x7fffff06 |
24 | ldr r2, .LC0 | 28 | ldr r2, .LC0 |
25 | ldr r2, [r2] @ max = 0x0fffffff | 29 | ldr r2, [r2] @ max = 0x01ffffff |
26 | mov r0, r0, lsr #11 @ max = 0x00003fff | 30 | mov r0, r0, lsr #14 @ max = 0x0001ffff |
27 | mov r2, r2, lsr #11 @ max = 0x0003ffff | 31 | mov r2, r2, lsr #10 @ max = 0x00007fff |
28 | mul r0, r2, r0 @ max = 2^32-1 | 32 | mul r0, r2, r0 @ max = 2^32-1 |
29 | movs r0, r0, lsr #6 | 33 | movs r0, r0, lsr #6 |
30 | RETINSTR(moveq,pc,lr) | 34 | RETINSTR(moveq,pc,lr) |
31 | 35 | ||
32 | /* | 36 | /* |
33 | * loops = (r0 * 0x10c6 * 100 * loops_per_jiffy) / 2^32 | 37 | * loops = r0 * HZ * loops_per_jiffy / 1000000 |
34 | * | 38 | * |
35 | * Oh, if only we had a cycle counter... | 39 | * Oh, if only we had a cycle counter... |
36 | */ | 40 | */ |
diff --git a/arch/arm/lib/io-acorn.S b/arch/arm/lib/io-acorn.S index b153523631c3..1b197ea7aab3 100644 --- a/arch/arm/lib/io-acorn.S +++ b/arch/arm/lib/io-acorn.S | |||
@@ -12,7 +12,6 @@ | |||
12 | */ | 12 | */ |
13 | #include <linux/linkage.h> | 13 | #include <linux/linkage.h> |
14 | #include <asm/assembler.h> | 14 | #include <asm/assembler.h> |
15 | #include <asm/hardware.h> | ||
16 | 15 | ||
17 | .text | 16 | .text |
18 | .align | 17 | .align |