Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:reserve_crashkernel_low

Proto:static int __init reserve_crashkernel_low(void)

Type:int

Parameter:Nothing

492  low_base = 0 , low_size = 0
496  total_low_mem = memblock_mem_size(1UL << (32 - PAGE_SHIFT determines the page size ))
499  ret = parse_crashkernel_low(boot_command_line, total_low_mem, & low_size, & base)
500  If ret Then
510  low_size = max - return maximum of two values of the same or compatible types*@x: first value*@y: second value(swiotlb_size_or_default() + (8UL << 20), 256UL << 20)
511  Else
513  If Not low_size Then Return 0
517  low_base = memblock_find_in_range(0, 1ULL << 32, low_size, 16M alignment for crash kernel regions )
518  If Not low_base Then
519  pr_err("Cannot reserve %ldMB crashkernel low memory, please try smaller size.\n", (unsignedlong)(low_size >> 20))
521  Return -ENOMEM
524  ret = memblock_reserve(low_base, low_size)
525  If ret Then
526  pr_err("%s: Error reserving crashkernel low memblock.\n", __func__)
527  Return ret
530  pr_info("Reserving %ldMB of low memory at %ldMB for crashkernel (System low RAM: %ldMB)\n", (unsignedlong)(low_size >> 20), (unsignedlong)(low_base >> 20), (unsignedlong)(total_low_mem >> 20))
535  start = low_base
536  end = low_base + low_size - 1
537  insert_resource( & iomem_resource, & crashk_low_res)
539  Return 0
Caller
NameDescribe
reserve_crashkernel