Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\kprobes\opt.c Create Date:2022-07-28 08:39:23
Last Modify:2022-05-22 07:44:06 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Replace a relative jump with a breakpoint (int3).

Proto:void arch_unoptimize_kprobe(struct optimized_kprobe *op)

Type:void

Parameter:

TypeParameterName
struct optimized_kprobe *op
453  insn_buff[0] = BREAKPOINT_INSTRUCTION
454  memcpy(insn_buff + 1, copy of the original instructions , RELATIVE_ADDR_SIZE)
456  emulate_buff[0] = RELATIVEJUMP_OPCODE
457  *emulate_buff[1] = detour code buffer - location of the probe point + RELATIVEJUMP_SIZE
460  xt_poke_bp() -- update instructions on live kernel on SMP*@addr: address to patch*@opcode: opcode of new instruction*@len: length to copy*@handler: address to jump to when the temporary breakpoint is hit* Update a single instruction with the vector in the
Caller
NameDescribe
arch_unoptimize_kprobesRecover original instructions and breakpoints from relative jumps.* Caller must call with locking kprobe_mutex.