Function report |
Source Code:arch\x86\kernel\traps.c |
Create Date:2022-07-28 07:32:05 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Our handling of the processor debug registers is non-trivial.* We do not clear them on entry and exit from the kernel. Therefore* it is possible to get a watchpoint trap here from inside the kernel.* However, the code in
Proto:__attribute__((__externally_visible__)) void do_debug(struct pt_regs *regs, long error_code)
Type:void
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct pt_regs * | regs | |
| long | error_code |
| 715 | tsk = current process |
| 716 | user_icebp = 0 |
| 734 | set_debugreg(0, 6) |
| 748 | dr6 &= ~single-step |
| 763 | If Not dr6 && ser_mode(regs) determines whether a register set came from user* mode Then user_icebp = 1 |
| 770 | If kprobe_debug_handler(regs) Then Go to exit |
| 774 | If notify_die(DIE_DEBUG, "debug", regs, (long) & dr6, error_code, SIGTRAP) == Clean way to return from the notifier and stop further calls. Then Go to exit |
| 782 | debug_stack_usage_inc() |
| 787 | If v8086_mode(regs) Then |
| 788 | handle_vm86_trap((structkernel_vm86_regs * )regs, error_code, X86_TRAP_DB) |
| 791 | debug_stack_usage_dec() |
| 792 | Go to exit |
| 795 | If WARN_ON_ONCE((dr6 & single-step ) && !ser_mode(regs) determines whether a register set came from user* mode) Then |
| 803 | Set thread flags in other task's structures.* See asm/thread_info.h for TIF_xxxx flags available: |
| 804 | flags &= ~X86_EFLAGS_TF |
| 807 | If Debug status used for traps, single steps, etc... & (single-step | DR_TRAP_BITS) || user_icebp Then send_sigtrap(regs, error_code, si_code) |
| 810 | debug_stack_usage_dec() |
| 812 | exit : |
| 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 |