Function report |
Source Code:arch\x86\kernel\kprobes\opt.c |
Create Date:2022-07-28 08:39:17 |
Last Modify:2022-05-22 07:44:06 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Decode whole function to ensure any instructions don't jump into target
Proto:static int can_optimize(unsigned long paddr)
Type:int
Parameter:
Type | Parameter | Name |
---|---|---|
unsigned long | paddr |
260 | If Not kallsyms_lookup_size_offset(paddr, & size, & offset) Then Return 0 |
267 | If paddr >= __entry_text_start && paddr < __entry_text_end || paddr >= __irqentry_text_start && paddr < __irqentry_text_end Then Return 0 |
274 | If size - offset < RELATIVEJUMP_SIZE Then Return 0 |
281 | If Given an address, look for it in the exception tables Then Return 0 |
288 | If Not recovered_insn Then Return 0 |
293 | If bytes[0] == BREAKPOINT_INSTRUCTION Then Return 0 |
299 | If insn_is_indirect_jump( & insn) || Check whether insn jumps into specified address range Then Return 0 |
306 | Return 1 |
Name | Describe |
---|---|
arch_prepare_optimized_kprobe | Copy replacing target instructions* Target instructions MUST be relocatable (checked inside)* This is called when new aggr(opt)probe is allocated or reused. |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |