Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Free up memory used by kernel, initrd, and command line. This is temporary* memory allocation which is not needed any more after these buffers have* been loaded into separate segments and have been copied elsewhere.

Proto:void kimage_file_post_load_cleanup(struct kimage *image)

Type:void

Parameter:

TypeParameterName
struct kimage *image
151  pi = Information for loading purgatory
153  vfree( Additional fields for file based kexec syscall )
154  Additional fields for file based kexec syscall = NULL
156  vfree(initrd_buf)
157  initrd_buf = NULL
159  kfree(cmdline_buf)
160  cmdline_buf = NULL
162  vfree(* Temporary, modifiable buffer for stripped purgatory used for * relocation. This memory can be freed post image load.)
163  * Temporary, modifiable buffer for stripped purgatory used for * relocation. This memory can be freed post image load. = NULL
165  vfree(* Temporary, modifiable buffer for sechdrs used for relocation. * This memory can be freed post image load.)
166  * Temporary, modifiable buffer for sechdrs used for relocation. * This memory can be freed post image load. = NULL
169  arch_kimage_file_post_load_cleanup(image)
176  kfree( Image loader handling the kernel can store a pointer here )
177  Image loader handling the kernel can store a pointer here = NULL
Caller
NameDescribe
kimage_file_prepare_segmentsIn file mode list of segments is prepared by kernel. Copy relevant* data from user space, do error checking, prepare segment list
kimage_file_alloc_init
SYSCALL_DEFINE5