]> git.karo-electronics.de Git - linux-beck.git/blobdiff - include/asm-ia64/kprobes.h
[ACPI] merge 3549 4320 4485 4588 4980 5483 5651 acpica asus fops pnpacpi branches...
[linux-beck.git] / include / asm-ia64 / kprobes.h
index bf36a32e37e4661dd4abaa944f55e7776c16ee65..8c0fc227f0fb6934c4f3f7573456d5d21150c6e0 100644 (file)
@@ -26,6 +26,7 @@
  */
 #include <linux/types.h>
 #include <linux/ptrace.h>
+#include <linux/percpu.h>
 #include <asm/break.h>
 
 #define MAX_INSN_SIZE   16
@@ -62,6 +63,22 @@ typedef struct _bundle {
        } quad1;
 } __attribute__((__aligned__(16)))  bundle_t;
 
+struct prev_kprobe {
+       struct kprobe *kp;
+       unsigned long status;
+};
+
+#define        MAX_PARAM_RSE_SIZE      (0x60+0x60/0x3f)
+/* per-cpu kprobe control block */
+struct kprobe_ctlblk {
+       unsigned long kprobe_status;
+       struct pt_regs jprobe_saved_regs;
+       unsigned long jprobes_saved_stacked_regs[MAX_PARAM_RSE_SIZE];
+       unsigned long *bsp;
+       unsigned long cfm;
+       struct prev_kprobe prev_kprobe;
+};
+
 #define JPROBE_ENTRY(pentry)   (kprobe_opcode_t *)pentry
 
 #define ARCH_SUPPORTS_KRETPROBES
@@ -76,6 +93,7 @@ typedef struct _bundle {
 #define IP_RELATIVE_PREDICT_OPCODE     (7)
 #define LONG_BRANCH_OPCODE             (0xC)
 #define LONG_CALL_OPCODE               (0xD)
+#define arch_remove_kprobe(p)          do {} while (0)
 
 typedef struct kprobe_opcode {
        bundle_t bundle;
@@ -92,16 +110,11 @@ struct arch_specific_insn {
        kprobe_opcode_t insn;
  #define INST_FLAG_FIX_RELATIVE_IP_ADDR                1
  #define INST_FLAG_FIX_BRANCH_REG              2
+ #define INST_FLAG_BREAK_INST                  4
        unsigned long inst_flag;
        unsigned short target_br_reg;
 };
 
-/* ia64 does not need this */
-static inline void arch_copy_kprobe(struct kprobe *p)
-{
-}
-
-#ifdef CONFIG_KPROBES
 extern int kprobe_exceptions_notify(struct notifier_block *self,
                                    unsigned long val, void *data);
 
@@ -109,12 +122,7 @@ extern int kprobe_exceptions_notify(struct notifier_block *self,
 static inline void jprobe_return(void)
 {
 }
+extern void invalidate_stacked_regs(void);
+extern void flush_register_stack(void);
 
-#else                          /* !CONFIG_KPROBES */
-static inline int kprobe_exceptions_notify(struct notifier_block *self,
-                                          unsigned long val, void *data)
-{
-       return 0;
-}
-#endif
 #endif                         /* _ASM_KPROBES_H */