Lines Matching refs:kcb

224 static void enable_singlestep(struct kprobe_ctlblk *kcb,  in enable_singlestep()  argument
236 __ctl_store(kcb->kprobe_saved_ctl, 9, 11); in enable_singlestep()
237 kcb->kprobe_saved_imask = regs->psw.mask & in enable_singlestep()
248 static void disable_singlestep(struct kprobe_ctlblk *kcb, in disable_singlestep() argument
253 __ctl_load(kcb->kprobe_saved_ctl, 9, 11); in disable_singlestep()
255 regs->psw.mask |= kcb->kprobe_saved_imask; in disable_singlestep()
265 static void push_kprobe(struct kprobe_ctlblk *kcb, struct kprobe *p) in push_kprobe() argument
267 kcb->prev_kprobe.kp = __this_cpu_read(current_kprobe); in push_kprobe()
268 kcb->prev_kprobe.status = kcb->kprobe_status; in push_kprobe()
278 static void pop_kprobe(struct kprobe_ctlblk *kcb) in pop_kprobe() argument
280 __this_cpu_write(current_kprobe, kcb->prev_kprobe.kp); in pop_kprobe()
281 kcb->kprobe_status = kcb->prev_kprobe.status; in pop_kprobe()
295 static void kprobe_reenter_check(struct kprobe_ctlblk *kcb, struct kprobe *p) in kprobe_reenter_check() argument
297 switch (kcb->kprobe_status) { in kprobe_reenter_check()
319 struct kprobe_ctlblk *kcb; in kprobe_handler() local
328 kcb = get_kprobe_ctlblk(); in kprobe_handler()
342 kprobe_reenter_check(kcb, p); in kprobe_handler()
343 push_kprobe(kcb, p); in kprobe_handler()
344 kcb->kprobe_status = KPROBE_REENTER; in kprobe_handler()
353 push_kprobe(kcb, p); in kprobe_handler()
354 kcb->kprobe_status = KPROBE_HIT_ACTIVE; in kprobe_handler()
356 pop_kprobe(kcb); in kprobe_handler()
360 kcb->kprobe_status = KPROBE_HIT_SS; in kprobe_handler()
362 enable_singlestep(kcb, regs, (unsigned long) p->ainsn.insn); in kprobe_handler()
412 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); in resume_execution() local
431 disable_singlestep(kcb, regs, ip); in resume_execution()
437 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); in post_kprobe_handler() local
443 if (kcb->kprobe_status != KPROBE_REENTER && p->post_handler) { in post_kprobe_handler()
444 kcb->kprobe_status = KPROBE_HIT_SSDONE; in post_kprobe_handler()
449 pop_kprobe(kcb); in post_kprobe_handler()
466 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); in kprobe_trap_handler() local
470 switch(kcb->kprobe_status) { in kprobe_trap_handler()
480 disable_singlestep(kcb, regs, (unsigned long) p->addr); in kprobe_trap_handler()
481 pop_kprobe(kcb); in kprobe_trap_handler()