kernel-fxtec-pro1x/arch/s390/kernel
Steven Rostedt 71e308a239 function-graph: add stack frame test
In case gcc does something funny with the stack frames, or the return
from function code, we would like to detect that.

An arch may implement passing of a variable that is unique to the
function and can be saved on entering a function and can be tested
when exiting the function. Usually the frame pointer can be used for
this purpose.

This patch also implements this for x86. Where it passes in the stack
frame of the parent function, and will test that frame on exit.

There was a case in x86_32 with optimize for size (-Os) where, for a
few functions, gcc would align the stack frame and place a copy of the
return address into it. The function graph tracer modified the copy and
not the actual return address. On return from the funtion, it did not go
to the tracer hook, but returned to the parent. This broke the function
graph tracer, because the return of the parent (where gcc did not do
this funky manipulation) returned to the location that the child function
was suppose to. This caused strange kernel crashes.

This test detected the problem and pointed out where the issue was.

This modifies the parameters of one of the functions that the arch
specific code calls, so it includes changes to arch code to accommodate
the new prototype.

Note, I notice that the parsic arch implements its own push_return_trace.
This is now a generic function and the ftrace_push_return_trace should be
used instead. This patch does not touch that code.

Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Helge Deller <deller@gmx.de>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2009-06-18 18:40:18 -04:00
..
vdso32 [S390] gettimeofday.S: removed duplicated #includes 2009-01-09 12:15:04 +01:00
vdso64 [PATCH] fast vdso implementation for CLOCK_THREAD_CPUTIME_ID 2008-12-31 15:11:49 +01:00
asm-offsets.c [S390] cpu hotplug and accounting values 2009-04-14 15:37:27 +02:00
audit.c
audit.h
base.S
bitmap.c [S390] move EXPORT_SYMBOLs to definitions 2009-03-26 15:24:11 +01:00
compat_audit.c
compat_exec_domain.c
compat_linux.c Separate out common fstatat code into vfs_fstatat 2009-04-20 23:02:51 -04:00
compat_linux.h compat: generic compat get/settimeofday 2008-10-16 11:21:33 -07:00
compat_ptrace.h [S390] Expose a constant for the number of words representing the CRs 2009-03-26 15:24:25 +01:00
compat_signal.c [S390] fix system call parameter functions. 2008-11-27 11:06:56 +01:00
compat_wrapper.S [S390] wire up sys_perf_counter_open 2009-06-12 10:27:40 +02:00
cpcmd.c [S390] convert cpcmd printks to pr_xxx macros. 2008-12-25 13:39:19 +01:00
crash.c
debug.c [S390] s390dbf: Remove needless check for NULL pointer. 2009-03-26 15:24:29 +01:00
diag.c
dis.c
early.c [S390] ftrace: add dynamic ftrace support 2009-06-12 10:27:38 +02:00
ebcdic.c
entry.h [CVE-2009-0029] s390 specific system call wrappers 2009-01-14 14:15:32 +01:00
entry.S [S390] ftrace: add system call tracer support 2009-06-12 10:27:39 +02:00
entry64.S [S390] ftrace: add system call tracer support 2009-06-12 10:27:39 +02:00
ftrace.c function-graph: add stack frame test 2009-06-18 18:40:18 -04:00
head.S Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-06-14 13:46:25 -07:00
head31.S [S390] eliminate ipl_device from lowcore 2009-03-26 15:24:27 +01:00
head64.S [S390] eliminate ipl_device from lowcore 2009-03-26 15:24:27 +01:00
init_task.c take init_fs to saner place 2008-12-31 18:07:42 -05:00
ipl.c [S390] ipl: fix compile breakage 2009-04-23 13:58:16 +02:00
irq.c [S390] Fix init irq proc build break. 2009-02-11 10:37:39 +01:00
kprobes.c [S390] kprobes: use probe_kernel_write 2009-06-12 10:27:37 +02:00
machine_kexec.c
Makefile [S390] ftrace: add function graph tracer support 2009-06-12 10:27:39 +02:00
mcount.S [S390] ftrace: add function graph tracer support 2009-06-12 10:27:39 +02:00
mem_detect.c [S390] Remove diag 0x260 call from memory detection. 2008-08-01 16:39:34 +02:00
module.c module: cleanup FIXME comments about trimming exception table entries. 2009-06-12 21:47:05 +09:30
nmi.c [S390] merge cpu.h into cputime.h 2009-06-12 10:27:29 +02:00
process.c [S390] implement is_compat_task 2009-06-12 10:27:30 +02:00
processor.c [S390] Add hwcap flag for the etf3 enhancement facility 2009-03-26 15:24:32 +01:00
ptrace.c [S390] ftrace: add system call tracer support 2009-06-12 10:27:39 +02:00
reipl.S
reipl64.S [S390] fix clock comparator save area usage 2009-03-26 15:24:32 +01:00
relocate_kernel.S
relocate_kernel64.S
s390_ext.c [S390] ftrace: add function graph tracer support 2009-06-12 10:27:39 +02:00
s390_ksyms.c [S390] move EXPORT_SYMBOLs to definitions 2009-03-26 15:24:11 +01:00
sclp.S [S390] add mini sclp driver 2009-06-12 10:27:30 +02:00
setup.c [S390] ftrace: add dynamic ftrace support 2009-06-12 10:27:38 +02:00
signal.c [S390] implement is_compat_task 2009-06-12 10:27:30 +02:00
smp.c [S390] ftrace: add dynamic ftrace support 2009-06-12 10:27:38 +02:00
stacktrace.c [S390] Fix stacktrace compile bug. 2008-07-17 17:22:09 +02:00
sys_s390.c [CVE-2009-0029] s390 specific system call wrappers 2009-01-14 14:15:32 +01:00
syscalls.S [S390] wire up sys_perf_counter_open 2009-06-12 10:27:40 +02:00
sysinfo.c [S390] move sysinfo.c from drivers/s390 to arch/s390/kernel 2009-03-26 15:24:06 +01:00
time.c [S390] ftrace: add function graph tracer support 2009-06-12 10:27:39 +02:00
topology.c [S390] cpumask: remove cpu_coregroup_map 2009-03-26 15:24:32 +01:00
traps.c [S390] fix dump_stack vs. %p and (null) 2009-03-26 15:24:02 +01:00
vdso.c [S390] implement is_compat_task 2009-06-12 10:27:30 +02:00
vmlinux.lds.S [S390] ftrace: add function graph tracer support 2009-06-12 10:27:39 +02:00
vtime.c [S390] merge cpu.h into cputime.h 2009-06-12 10:27:29 +02:00