Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\traps.c Create Date:2022-07-28 07:31:58
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Runs on an IST stack for x86_64 and on a special task stack for x86_32.* On x86_64, this is more or less a normal kernel entry. Notwithstanding the* SDM's warnings about double faults being unrecoverable, returning works as* expected

Proto:__attribute__((__externally_visible__)) void do_double_fault(struct pt_regs *regs, long error_code, unsigned long cr2)

Type:void

Parameter:

TypeParameterName
struct pt_regs *regs
longerror_code
unsigned longcr2
328  str[] = "double fault"
329  tsk = current process
381  In IST context, we explicitly disable preemption. This serves two* purposes: it makes it much less likely that we would accidentally* schedule in IST context and it will force a warning if we somehow* manage to schedule by accident.
382  notify_die(DIE_TRAP, str, regs, error_code, X86_TRAP_DF, SIGSEGV)
384  error_code = error_code
385  trap_nr = X86_TRAP_DF
429  These can be used to print at the various log levels.* All of these will print unconditionally, although note that pr_debug()* and other debug macros are compiled out unless either DEBUG is defined* or CONFIG_DYNAMIC_DEBUG is set.("PANIC: double fault, error_code: 0x%lx\n", error_code)
430  die("double fault", regs, error_code)
431  panic - halt the system*@fmt: The text string to print* Display a message, then perform cleanups.* This function never returns.
Caller
NameDescribe
doublefault_shimCalled by double_fault with CR0.TS and EFLAGS.NT cleared. The CPU thinks* we're running the doublefault task. Cannot return.