aboutsummaryrefslogtreecommitdiffstats
path: root/arch/xtensa
diff options
context:
space:
mode:
authorMax Filippov <jcmvbkbc@gmail.com>2013-02-25 10:01:33 -0500
committerChris Zankel <chris@zankel.net>2013-05-09 04:07:09 -0400
commit74f5bf029ee052e3d845672728e80b7240d14f09 (patch)
tree72255cba6a63fcf4aae89c5c3b1b3a4c3ec39e30 /arch/xtensa
parentc1be5a5b1b355d40e6cf79cc979eb66dafa24ad1 (diff)
xtensa: fix oprofile building as module
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
Diffstat (limited to 'arch/xtensa')
-rw-r--r--arch/xtensa/kernel/xtensa_ksyms.c5
-rw-r--r--arch/xtensa/oprofile/backtrace.c4
2 files changed, 6 insertions, 3 deletions
diff --git a/arch/xtensa/kernel/xtensa_ksyms.c b/arch/xtensa/kernel/xtensa_ksyms.c
index afe058b24e6e..42c53c87c204 100644
--- a/arch/xtensa/kernel/xtensa_ksyms.c
+++ b/arch/xtensa/kernel/xtensa_ksyms.c
@@ -119,3 +119,8 @@ EXPORT_SYMBOL(outsl);
119EXPORT_SYMBOL(insb); 119EXPORT_SYMBOL(insb);
120EXPORT_SYMBOL(insw); 120EXPORT_SYMBOL(insw);
121EXPORT_SYMBOL(insl); 121EXPORT_SYMBOL(insl);
122
123extern long common_exception_return;
124extern long _spill_registers;
125EXPORT_SYMBOL(common_exception_return);
126EXPORT_SYMBOL(_spill_registers);
diff --git a/arch/xtensa/oprofile/backtrace.c b/arch/xtensa/oprofile/backtrace.c
index 66f32ee2c982..5f03a593d84f 100644
--- a/arch/xtensa/oprofile/backtrace.c
+++ b/arch/xtensa/oprofile/backtrace.c
@@ -132,9 +132,7 @@ static void xtensa_backtrace_kernel(struct pt_regs *regs, unsigned int depth)
132 pc = MAKE_PC_FROM_RA(a0, pc); 132 pc = MAKE_PC_FROM_RA(a0, pc);
133 133
134 /* Add the PC to the trace. */ 134 /* Add the PC to the trace. */
135 if (kernel_text_address(pc)) 135 oprofile_add_trace(pc);
136 oprofile_add_trace(pc);
137
138 if (pc == (unsigned long) &common_exception_return) { 136 if (pc == (unsigned long) &common_exception_return) {
139 regs = (struct pt_regs *)a1; 137 regs = (struct pt_regs *)a1;
140 if (user_mode(regs)) { 138 if (user_mode(regs)) {