函数逻辑报告 |
Source Code:mm\mmap.c |
Create Date:2022-07-27 16:17:01 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:unmapped_area
函数原型:unsigned long unmapped_area(struct vm_unmapped_area_info *info)
返回类型:unsigned long
参数:
类型 | 参数 | 名称 |
---|---|---|
struct vm_unmapped_area_info * | info |
1870 | length等于length加align_mask |
1875 | 如果high_limit小于length则返回:负ENOMEM |
1877 | high_limit等于high_limit减length |
1879 | 如果low_limit大于high_limit则返回:负ENOMEM |
1884 | 如果RB_EMPTY_ROOT( & mm_rb)则转到:check_highest |
1886 | vma等于rb_entry(rb_node, structvm_area_struct, vm_rb) |
1890 | 当(true)循环 |
1892 | gap_end等于vm_start_gap(vma) |
1894 | left等于rb_entry(rb_left, structvm_area_struct, vm_rb) |
1903 | gap_start等于如果linked list of VM areas per task, sorted by address 则vm_end_gap(linked list of VM areas per task, sorted by address )否则0 |
1904 | check_current : |
1906 | 如果gap_start大于high_limit则返回:负ENOMEM |
1913 | 如果rb_right则 |
1914 | right等于rb_entry(rb_right, structvm_area_struct, vm_rb) |
1924 | 当(true)循环 |
1926 | 如果非rb_parent(prev)则转到:check_highest |
1932 | gap_end等于vm_start_gap(vma) |
1933 | 转到:check_current |
1938 | check_highest : |
1940 | gap_start等于 highest vma end address |
1942 | 如果gap_start大于high_limit则返回:负ENOMEM |
1945 | found : |
1951 | gap_start加等于align_offset减gap_start按位与align_mask |
1953 | VM_BUG_ON(gap_start + length > high_limit) |
1955 | 返回:gap_start |
名称 | 描述 |
---|---|
vm_unmapped_area | Search for an unmapped address range |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |