函数逻辑报告 |
Source Code:mm\memblock.c |
Create Date:2022-07-27 16:40:53 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:memblock_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
函数原型:static phys_addr_t __init memblock_alloc_range_nid(phys_addr_t size, phys_addr_t align, phys_addr_t start, phys_addr_t end, int nid, bool exact_nid)
返回类型:phys_addr_t
参数:
类型 | 参数 | 名称 |
---|---|---|
phys_addr_t | size | |
phys_addr_t | align | |
phys_addr_t | start | |
phys_addr_t | end | |
int | nid | |
bool | exact_nid |
1345 | flags等于choose_memblock_flags() |
1348 | 如果WARN_ONCE(nid == MAX_NUMNODES, "Usage of MAX_NUMNODES is deprecated. Use NUMA_NO_NODE instead\n")则nid等于NUMA_NO_NODE |
1351 | 如果非align则 |
1353 | dump_stack() |
1354 | align等于SMP_CACHE_BYTES |
1357 | again : |
1360 | 如果found且非memblock_reserve(found, size)则转到:done |
1363 | 如果nid不等于NUMA_NO_NODE且非exact_nid则 |
1364 | found等于memblock_find_in_range_node(size, align, start, end, NUMA_NO_NODE, flags) |
1367 | 如果found且非memblock_reserve(found, size)则转到:done |
1371 | 如果flags按位与mirrored region 则 |
1372 | flags与等于mirrored region 的反 |
1375 | 转到:again |
1378 | 返回:0 |
1380 | done : |
1382 | 如果end不等于MEMBLOCK_ALLOC_KASAN则kmemleak_alloc_phys(found, size, 0, 0) |
1391 | 返回:found |
名称 | 描述 |
---|---|
memblock_phys_alloc_range | memblock_phys_alloc_range - allocate a memory block inside specified range*@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 (physical |
memblock_phys_alloc_try_nid | memblock_phys_alloc_try_nid - allocate a memory block from specified MUMA node*@size: size of memory block to be allocated in bytes*@align: alignment of the region and block's size*@nid: nid of the free area to find, %NUMA_NO_NODE for any node |
memblock_alloc_internal | memblock_alloc_internal - allocate boot memory block*@size: size of memory block to be allocated in bytes*@align: alignment of the region and block's size*@min_addr: the lower bound of the memory region to allocate (phys address)*@max_addr: the upper |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |