aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kprobes.h
diff options
context:
space:
mode:
authorAbhishek Sagar <sagar.abhishek@gmail.com>2008-02-06 01:38:22 -0800
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-06 10:41:11 -0800
commitf47cd9b553aaada602449204513b5a5b29cba263 (patch)
tree079ddd399b1aa00a8c413ef51f3b8681a19a6e7e /include/linux/kprobes.h
parent5beec4aa2ac261b0b4992fb41df40a7ab91e4fad (diff)
downloadkernel_samsung_smdk4412-f47cd9b553aaada602449204513b5a5b29cba263.zip
kernel_samsung_smdk4412-f47cd9b553aaada602449204513b5a5b29cba263.tar.gz
kernel_samsung_smdk4412-f47cd9b553aaada602449204513b5a5b29cba263.tar.bz2
kprobes: kretprobe user entry-handler
Provide support to add an optional user defined callback to be run at function entry of a kretprobe'd function. Also modify the kprobe smoke tests to include an entry-handler during the kretprobe sanity test. Signed-off-by: Abhishek Sagar <sagar.abhishek@gmail.com> Cc: Prasanna S Panchamukhi <prasanna@in.ibm.com> Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com> Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com> Acked-by: Jim Keniston <jkenisto@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/kprobes.h')
-rw-r--r--include/linux/kprobes.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/kprobes.h b/include/linux/kprobes.h
index 6168c0a..4a6ce82 100644
--- a/include/linux/kprobes.h
+++ b/include/linux/kprobes.h
@@ -152,8 +152,10 @@ static inline int arch_trampoline_kprobe(struct kprobe *p)
struct kretprobe {
struct kprobe kp;
kretprobe_handler_t handler;
+ kretprobe_handler_t entry_handler;
int maxactive;
int nmissed;
+ size_t data_size;
struct hlist_head free_instances;
struct hlist_head used_instances;
};
@@ -164,6 +166,7 @@ struct kretprobe_instance {
struct kretprobe *rp;
kprobe_opcode_t *ret_addr;
struct task_struct *task;
+ char data[0];
};
struct kretprobe_blackpoint {