aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
Diffstat (limited to 'arch')
-rw-r--r--arch/ia64/kernel/kprobes.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/ia64/kernel/kprobes.c b/arch/ia64/kernel/kprobes.c
index fc4d2676264f..b618487cdc85 100644
--- a/arch/ia64/kernel/kprobes.c
+++ b/arch/ia64/kernel/kprobes.c
@@ -381,9 +381,10 @@ static void __kprobes save_previous_kprobe(struct kprobe_ctlblk *kcb)
381static void __kprobes restore_previous_kprobe(struct kprobe_ctlblk *kcb) 381static void __kprobes restore_previous_kprobe(struct kprobe_ctlblk *kcb)
382{ 382{
383 unsigned int i; 383 unsigned int i;
384 i = atomic_sub_return(1, &kcb->prev_kprobe_index); 384 i = atomic_read(&kcb->prev_kprobe_index);
385 __get_cpu_var(current_kprobe) = kcb->prev_kprobe[i].kp; 385 __get_cpu_var(current_kprobe) = kcb->prev_kprobe[i-1].kp;
386 kcb->kprobe_status = kcb->prev_kprobe[i].status; 386 kcb->kprobe_status = kcb->prev_kprobe[i-1].status;
387 atomic_sub(1, &kcb->prev_kprobe_index);
387} 388}
388 389
389static void __kprobes set_current_kprobe(struct kprobe *p, 390static void __kprobes set_current_kprobe(struct kprobe *p,