perf: Fix unexported generic perf_arch_fetch_caller_regs
authorFrederic Weisbecker <fweisbec@gmail.com>
Tue, 16 Mar 2010 00:05:02 +0000 (01:05 +0100)
committerIngo Molnar <mingo@elte.hu>
Wed, 17 Mar 2010 09:44:42 +0000 (10:44 +0100)
commita6b84574eed7e4fd8cb8dac2d0926fe2cf34b941
tree98020cdcfbff562b3c9a0571b9f6350d2e9a41a0
parent00909e955125e90a6ebb34671c56c4c851e62951
perf: Fix unexported generic perf_arch_fetch_caller_regs

perf_arch_fetch_caller_regs() is exported for the overriden x86
version, but not for the generic weak version.

As a general rule, weak functions should not have their symbol
exported in the same file they are defined.

So let's export it on trace_event_perf.c as it is used by trace
events only.

This fixes:

ERROR: ".perf_arch_fetch_caller_regs" [fs/xfs/xfs.ko] undefined!
ERROR: ".perf_arch_fetch_caller_regs" [arch/powerpc/platforms/cell/spufs/spufs.ko] undefined!

-v2: And also only build it if trace events are enabled.
-v3: Fix changelog mistake

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Xiao Guangrong <xiaoguangrong@cn.fujitsu.com>
Cc: Paul Mackerras <paulus@samba.org>
LKML-Reference: <1268697902-9518-1-git-send-regression-fweisbec@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/cpu/perf_event.c
kernel/perf_event.c
kernel/trace/trace_event_perf.c