diff options
author | Ananth N Mavinakayanahalli <ananth@in.ibm.com> | 2005-11-07 04:00:11 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-07 10:53:46 -0500 |
commit | f215d985e936cf493959b365a10593b6d5f80447 (patch) | |
tree | 90d187826b5364f364ca6ada71da3e24372db981 /include/asm-sparc64/kprobes.h | |
parent | 0dc036c91ac11b2b76bb91b59d8c7af919aa4a8d (diff) |
[PATCH] Kprobes: Track kprobe on a per_cpu basis - sparc64 changes
Sparc64 changes to track kprobe execution on a per-cpu basis. We now track
the kprobe state machine independently on each cpu using an arch specific
kprobe control block.
Signed-off-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Signed-off-by: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/asm-sparc64/kprobes.h')
-rw-r--r-- | include/asm-sparc64/kprobes.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/include/asm-sparc64/kprobes.h b/include/asm-sparc64/kprobes.h index a8d326a598f0..7ba845320f5c 100644 --- a/include/asm-sparc64/kprobes.h +++ b/include/asm-sparc64/kprobes.h | |||
@@ -3,6 +3,7 @@ | |||
3 | 3 | ||
4 | #include <linux/config.h> | 4 | #include <linux/config.h> |
5 | #include <linux/types.h> | 5 | #include <linux/types.h> |
6 | #include <linux/percpu.h> | ||
6 | 7 | ||
7 | typedef u32 kprobe_opcode_t; | 8 | typedef u32 kprobe_opcode_t; |
8 | 9 | ||
@@ -18,6 +19,25 @@ struct arch_specific_insn { | |||
18 | kprobe_opcode_t insn[MAX_INSN_SIZE]; | 19 | kprobe_opcode_t insn[MAX_INSN_SIZE]; |
19 | }; | 20 | }; |
20 | 21 | ||
22 | struct prev_kprobe { | ||
23 | struct kprobe *kp; | ||
24 | unsigned int status; | ||
25 | unsigned long orig_tnpc; | ||
26 | unsigned long orig_tstate_pil; | ||
27 | }; | ||
28 | |||
29 | /* per-cpu kprobe control block */ | ||
30 | struct kprobe_ctlblk { | ||
31 | unsigned long kprobe_status; | ||
32 | unsigned long kprobe_orig_tnpc; | ||
33 | unsigned long kprobe_orig_tstate_pil; | ||
34 | long *jprobe_saved_esp; | ||
35 | struct pt_regs jprobe_saved_regs; | ||
36 | struct pt_regs *jprobe_saved_regs_location; | ||
37 | struct sparc_stackf jprobe_saved_stack; | ||
38 | struct prev_kprobe prev_kprobe; | ||
39 | }; | ||
40 | |||
21 | #ifdef CONFIG_KPROBES | 41 | #ifdef CONFIG_KPROBES |
22 | extern int kprobe_exceptions_notify(struct notifier_block *self, | 42 | extern int kprobe_exceptions_notify(struct notifier_block *self, |
23 | unsigned long val, void *data); | 43 | unsigned long val, void *data); |