Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:memblock_find_in_range_node

Proto:static phys_addr_t __attribute__((__section__(".meminit.text"))) __attribute__((__cold__)) __attribute__((__no_instrument_function__))memblock_find_in_range_node(phys_addr_t size, phys_addr_t align, phys_addr_t start, phys_addr_t end, int nid, enum memblock_flags flags)

Type:phys_addr_t

Parameter:

TypeParameterName
phys_addr_tsize
phys_addr_talign
phys_addr_tstart
phys_addr_tend
intnid
enum memblock_flagsflags
275  If end == MEMBLOCK_ALLOC_ACCESSIBLE || end == MEMBLOCK_ALLOC_KASAN Then end = current_limit
280  start = max_t - return maximum of two values, using the specified type*@type: data type to use*@x: first value*@y: second value(phys_addr_t, start, PAGE_SIZE)
281  end = max - return maximum of two values of the same or compatible types*@x: first value*@y: second value(start, end)
282  kernel_end = We need __phys_reloc_hide() here because gcc may assume that there is no* overflow during __pa() calculation and can optimize it unexpectedly.* Newer versions of gcc provide -fno-strict-overflow switch to handle this* case properly(_end)
288  If Check if the allocation direction is bottom-up or not.* if this is true, that said, memblock will allocate memory* in bottom-up direction. && end > kernel_end Then
292  bottom_up_start = max - return maximum of two values of the same or compatible types*@x: first value*@y: second value(start, kernel_end)
295  ret = __memblock_find_range_bottom_up(bottom_up_start, end, size, align, nid, flags)
297  If ret Then Return ret
310  WARN_ONCE(IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_MEMORY_HOTREMOVE), "memblock: bottom-up allocation failed, memory hotremove may be affected\n")
314  Return __memblock_find_range_top_down(start, end, size, align, nid, flags)
Caller
NameDescribe
memblock_find_in_range
memblock_alloc_range_nidmemblock_alloc_range_nid - allocate boot memory block*@size: size of memory block to be allocated in bytes*@align: alignment of the region and block's size*@start: the lower bound of the memory region to allocate (phys address)*@end: the upper bound of