aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel
diff options
context:
space:
mode:
authorRussell King <rmk@dyn-67.arm.linux.org.uk>2009-08-15 11:51:48 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2009-08-15 11:51:48 -0400
commit9b2616c2e8cc98ca98bbb40cad83a8d3d859e840 (patch)
tree5a971fa57298d58529d3ae82b68cbfc7139bde7b /arch/arm/kernel
parent590a94d93475fa6cca257f161ae268ed3a2395b5 (diff)
parentac25150f2c55ea26447af0fa1d4e2bb07f97384d (diff)
Merge branch 'for-rmk-2.6.32' of git://git.pengutronix.de/git/ukl/linux-2.6 into devel-stable
Diffstat (limited to 'arch/arm/kernel')
-rw-r--r--arch/arm/kernel/armksyms.c1
-rw-r--r--arch/arm/kernel/entry-armv.S10
-rw-r--r--arch/arm/kernel/entry-common.S19
3 files changed, 24 insertions, 6 deletions
diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c
index 531e1860e546..0e627705f746 100644
--- a/arch/arm/kernel/armksyms.c
+++ b/arch/arm/kernel/armksyms.c
@@ -186,4 +186,5 @@ EXPORT_SYMBOL(_find_next_bit_be);
186 186
187#ifdef CONFIG_FUNCTION_TRACER 187#ifdef CONFIG_FUNCTION_TRACER
188EXPORT_SYMBOL(mcount); 188EXPORT_SYMBOL(mcount);
189EXPORT_SYMBOL(__gnu_mcount_nc);
189#endif 190#endif
diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S
index 468425f937dd..3d727a8a23bc 100644
--- a/arch/arm/kernel/entry-armv.S
+++ b/arch/arm/kernel/entry-armv.S
@@ -161,6 +161,8 @@ ENDPROC(__und_invalid)
161 @ r4 - orig_r0 (see pt_regs definition in ptrace.h) 161 @ r4 - orig_r0 (see pt_regs definition in ptrace.h)
162 @ 162 @
163 stmia r5, {r0 - r4} 163 stmia r5, {r0 - r4}
164
165 asm_trace_hardirqs_off
164 .endm 166 .endm
165 167
166 .align 5 168 .align 5
@@ -215,9 +217,6 @@ ENDPROC(__dabt_svc)
215__irq_svc: 217__irq_svc:
216 svc_entry 218 svc_entry
217 219
218#ifdef CONFIG_TRACE_IRQFLAGS
219 bl trace_hardirqs_off
220#endif
221#ifdef CONFIG_PREEMPT 220#ifdef CONFIG_PREEMPT
222 get_thread_info tsk 221 get_thread_info tsk
223 ldr r8, [tsk, #TI_PREEMPT] @ get preempt count 222 ldr r8, [tsk, #TI_PREEMPT] @ get preempt count
@@ -391,6 +390,8 @@ ENDPROC(__pabt_svc)
391 @ Clear FP to mark the first stack frame 390 @ Clear FP to mark the first stack frame
392 @ 391 @
393 zero_fp 392 zero_fp
393
394 asm_trace_hardirqs_off
394 .endm 395 .endm
395 396
396 .macro kuser_cmpxchg_check 397 .macro kuser_cmpxchg_check
@@ -445,9 +446,6 @@ __irq_usr:
445 usr_entry 446 usr_entry
446 kuser_cmpxchg_check 447 kuser_cmpxchg_check
447 448
448#ifdef CONFIG_TRACE_IRQFLAGS
449 bl trace_hardirqs_off
450#endif
451 get_thread_info tsk 449 get_thread_info tsk
452#ifdef CONFIG_PREEMPT 450#ifdef CONFIG_PREEMPT
453 ldr r8, [tsk, #TI_PREEMPT] @ get preempt count 451 ldr r8, [tsk, #TI_PREEMPT] @ get preempt count
diff --git a/arch/arm/kernel/entry-common.S b/arch/arm/kernel/entry-common.S
index a0540c9f1f0c..df19e8bf2e4a 100644
--- a/arch/arm/kernel/entry-common.S
+++ b/arch/arm/kernel/entry-common.S
@@ -118,6 +118,25 @@ ftrace_call:
118 118
119#else 119#else
120 120
121ENTRY(__gnu_mcount_nc)
122 stmdb sp!, {r0-r3, lr}
123 ldr r0, =ftrace_trace_function
124 ldr r2, [r0]
125 adr r0, ftrace_stub
126 cmp r0, r2
127 bne gnu_trace
128 ldmia sp!, {r0-r3, ip, lr}
129 bx ip
130
131gnu_trace:
132 ldr r1, [sp, #20] @ lr of instrumented routine
133 mov r0, lr
134 sub r0, r0, #MCOUNT_INSN_SIZE
135 mov lr, pc
136 mov pc, r2
137 ldmia sp!, {r0-r3, ip, lr}
138 bx ip
139
121ENTRY(mcount) 140ENTRY(mcount)
122 stmdb sp!, {r0-r3, lr} 141 stmdb sp!, {r0-r3, lr}
123 ldr r0, =ftrace_trace_function 142 ldr r0, =ftrace_trace_function