函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\events\uprobes.c Create Date:2022-07-27 15:08:16
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Perform required fix-ups and disable singlestep.* Allow pending signals to take effect.

函数原型:static void handle_singlestep(struct uprobe_task *utask, struct pt_regs *regs)

返回类型:void

参数:

类型参数名称
struct uprobe_task *utask
struct pt_regs *regs
2262  err等于0
2264  uprobe等于active_uprobe
2265  如果state恒等于UTASK_SSTEP_ACKerr等于Called after single-stepping. To avoid the SMP problems that can* occur when we temporarily put back the original opcode to* single-step, we single-stepped a copy of the instruction.* This function prepares to resume execution after the single-step.
2267  否则如果state恒等于UTASK_SSTEP_TRAPPEDThis function gets called when XOL instruction either gets trapped or* the thread has a fatal signal. Reset the instruction pointer to its* probed address for the potential restart or for post mortem analysis.
2269  否则WARN_ON_ONCE(1)
2272  put_uprobe(uprobe)
2273  active_uprobe = NULL
2274  state等于UTASK_RUNNING
2275  xol_free_insn_slot - If slot was earlier allocated by*@xol_get_insn_slot(), make the slot available for* subsequent requests.
2277  spin_lock_irq( & siglock)
2278  确定进程等待信号
2279  spin_unlock_irq( & siglock)
2281  如果此条件成立可能性小(为编译器优化)(err)则
2282  uprobe_warn(当前进程, "execute the probed insn, sending SIGILL.")
2283  force_sig(SIGILL)
调用者
名称描述
uprobe_notify_resumeOn breakpoint hit, breakpoint notifier sets the TIF_UPROBE flag and* allows the thread to return from interrupt. After that handle_swbp()* sets utask->active_uprobe.* On singlestep exception, singlestep notifier sets the TIF_UPROBE flag