summaryrefslogtreecommitdiffstats
path: root/include/linux/ftrace.h
diff options
context:
space:
mode:
authorSteven Rostedt (Red Hat)2014-10-24 20:48:35 +0200
committerSteven Rostedt2014-10-24 22:53:11 +0200
commit4fc409048d5afb1ad853f294b4262ecf2c980a49 (patch)
tree238860c1dbc3a58e034dde0c7b299a3773347660 /include/linux/ftrace.h
parentftrace: Set ops->old_hash on modifying what an ops hooks to (diff)
downloadkernel-qcow2-linux-4fc409048d5afb1ad853f294b4262ecf2c980a49.tar.gz
kernel-qcow2-linux-4fc409048d5afb1ad853f294b4262ecf2c980a49.tar.xz
kernel-qcow2-linux-4fc409048d5afb1ad853f294b4262ecf2c980a49.zip
ftrace: Fix checking of trampoline ftrace_ops in finding trampoline
When modifying code, ftrace has several checks to make sure things are being done correctly. One of them is to make sure any code it modifies is exactly what it expects it to be before it modifies it. In order to do so with the new trampoline logic, it must be able to find out what trampoline a function is hooked to in order to see if the code that hooks to it is what's expected. The logic to find the trampoline from a record (accounting descriptor for a function that is hooked) needs to only look at the "old_hash" of an ops that is being modified. The old_hash is the list of function an ops is hooked to before its update. Since a record would only be pointing to an ops that is being modified if it was already hooked before. Currently, it can pick a modified ops based on its new functions it will be hooked to, and this picks the wrong trampoline and causes the check to fail, disabling ftrace. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> ftrace: squash into ordering of ops for modification
Diffstat (limited to 'include/linux/ftrace.h')
0 files changed, 0 insertions, 0 deletions