diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-11-26 05:28:11 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-11-26 05:28:11 -0500 |
commit | 83cf1eecfe9afee99d6b86f963187acd414c019d (patch) | |
tree | 4381bdcc45d81c8c3713630cae9660d770885d96 /arch/arm/include/asm | |
parent | f1690d17d2c7afa2a2079e3c91eb2bca8c1c5ecd (diff) | |
parent | 0e341af835fdf553820a1fa98341b93ab32ce466 (diff) |
Merge branch 'ftrace' of git://github.com/rabinv/linux-2.6 into devel-stable
Diffstat (limited to 'arch/arm/include/asm')
-rw-r--r-- | arch/arm/include/asm/system.h | 5 | ||||
-rw-r--r-- | arch/arm/include/asm/traps.h | 23 |
2 files changed, 26 insertions, 2 deletions
diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h index 1120f18a6b17..ec4327a4653d 100644 --- a/arch/arm/include/asm/system.h +++ b/arch/arm/include/asm/system.h | |||
@@ -63,6 +63,11 @@ | |||
63 | #include <asm/outercache.h> | 63 | #include <asm/outercache.h> |
64 | 64 | ||
65 | #define __exception __attribute__((section(".exception.text"))) | 65 | #define __exception __attribute__((section(".exception.text"))) |
66 | #ifdef CONFIG_FUNCTION_GRAPH_TRACER | ||
67 | #define __exception_irq_entry __irq_entry | ||
68 | #else | ||
69 | #define __exception_irq_entry __exception | ||
70 | #endif | ||
66 | 71 | ||
67 | struct thread_info; | 72 | struct thread_info; |
68 | struct task_struct; | 73 | struct task_struct; |
diff --git a/arch/arm/include/asm/traps.h b/arch/arm/include/asm/traps.h index 491960bf4260..124475afb007 100644 --- a/arch/arm/include/asm/traps.h +++ b/arch/arm/include/asm/traps.h | |||
@@ -15,13 +15,32 @@ struct undef_hook { | |||
15 | void register_undef_hook(struct undef_hook *hook); | 15 | void register_undef_hook(struct undef_hook *hook); |
16 | void unregister_undef_hook(struct undef_hook *hook); | 16 | void unregister_undef_hook(struct undef_hook *hook); |
17 | 17 | ||
18 | #ifdef CONFIG_FUNCTION_GRAPH_TRACER | ||
19 | static inline int __in_irqentry_text(unsigned long ptr) | ||
20 | { | ||
21 | extern char __irqentry_text_start[]; | ||
22 | extern char __irqentry_text_end[]; | ||
23 | |||
24 | return ptr >= (unsigned long)&__irqentry_text_start && | ||
25 | ptr < (unsigned long)&__irqentry_text_end; | ||
26 | } | ||
27 | #else | ||
28 | static inline int __in_irqentry_text(unsigned long ptr) | ||
29 | { | ||
30 | return 0; | ||
31 | } | ||
32 | #endif | ||
33 | |||
18 | static inline int in_exception_text(unsigned long ptr) | 34 | static inline int in_exception_text(unsigned long ptr) |
19 | { | 35 | { |
20 | extern char __exception_text_start[]; | 36 | extern char __exception_text_start[]; |
21 | extern char __exception_text_end[]; | 37 | extern char __exception_text_end[]; |
38 | int in; | ||
39 | |||
40 | in = ptr >= (unsigned long)&__exception_text_start && | ||
41 | ptr < (unsigned long)&__exception_text_end; | ||
22 | 42 | ||
23 | return ptr >= (unsigned long)&__exception_text_start && | 43 | return in ? : __in_irqentry_text(ptr); |
24 | ptr < (unsigned long)&__exception_text_end; | ||
25 | } | 44 | } |
26 | 45 | ||
27 | extern void __init early_trap_init(void); | 46 | extern void __init early_trap_init(void); |