函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Do not allocate memory (or fail in any way) in machine_kexec().* We are past the point of no return, committed to rebooting now.

函数原型:void machine_kexec(struct kimage *image)

返回类型:void

参数:

类型参数名称
struct kimage *image
178  asmlinkage unsigned long( * relocate_kernel_ptr)(unsigned long indirection_page, unsigned long control_page, unsigned long start_address, unsigned int has_pae, unsigned int preserve_context)
190  save_ftrace_enabled等于Ftrace disable/restore without lock. Some synchronization mechanism* must be used to prevent ftrace_enabled to be changed between* disable/restore.
193  禁止中断()
194  hw_breakpoint_disable()
196  如果preserve_contextcontrol_page等于page_address(control_code_page)
210  memcpy(control_page, relocate_kernel, KEXEC_CONTROL_CODE_MAX_SIZE)
212  relocate_kernel_ptr等于control_page
213  page_list[PA_CONTROL_PAGE]等于__pa(control_page)
214  page_list[VA_CONTROL_PAGE]等于control_page
215  page_list[PA_PGD]等于__pa(pgd)
217  如果 Flags to indicate special processing 恒等于KEXEC_TYPE_DEFAULTpage_list[PA_SWAP_PAGE]等于page_to_pfn(swap_page)左移PAGE_SHIFT determines the page size
231  load_segments()
236  dt_invalidate - Invalidate interrupt descriptor table*@addr: The virtual address of the 'invalid' IDT
237  set_gdt(phys_to_virt - map physical address to virtual*@address: address to remap* The returned virtual address is a current CPU mapping for* the memory address given. It is only valid to use this function on* addresses that have a kernel mapping, 0)
240  start等于relocate_kernel_ptr((unsignedlong)head, (unsignedlong)page_list, start, boot_cpu_has(Physical Address Extensions ), preserve_context)
251  __ftrace_enabled_restore(save_ftrace_enabled)
调用者
名称描述
kernel_kexecMove into place and start executing a preloaded standalone* executable. If nothing was preloaded return an error.
__crash_kexecNo panic_cpu check version of crash_kexec(). This function is called* only when panic_cpu holds the current CPU number; this is the only CPU* which processes crash_kexec routines.