函数逻辑报告 |
Source Code:mm\swapfile.c |
Create Date:2022-07-27 16:49:10 |
Last Modify:2020-03-17 22:19:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:Add a block range (and the corresponding page range) into this swapdev's* extent tree.* This function rather assumes that it is called in ascending page order.
函数原型:int add_swap_extent(struct swap_info_struct *sis, unsigned long start_page, unsigned long nr_pages, sector_t start_block)
返回类型:int
参数:
类型 | 参数 | 名称 |
---|---|---|
struct swap_info_struct * | sis | |
unsigned long | start_page | |
unsigned long | nr_pages | |
sector_t | start_block |
2327 | 如果parent则 |
2328 | se等于rb_entry(parent, structswap_extent, rb_node) |
2329 | BUG_ON(start_page + nr_pages != start_page) |
2330 | 如果start_block加nr_pages恒等于start_block则 |
2338 | new_se等于kmalloc(se的长度, GFP_KERNEL) |
2341 | start_page等于start_page |
2343 | start_block等于start_block |
2345 | rb_link_node( & rb_node, parent, link) |
2346 | rb_insert_color( & rb_node, & of the swap extent rbtree ) |
2347 | 返回:1 |
名称 | 描述 |
---|---|
generic_swapfile_activate | |
setup_swap_extents | A `swap extent' is a simple thing which maps a contiguous range of pages* onto a contiguous range of disk blocks. An ordered list of swap extents* is built at swapon time and is then used at swap_writepage/swap_readpage |
iomap_swapfile_add_extent | Collect physical extents for this swap file. Physical extents reported to* the swap code must be trimmed to align to a page boundary. The logical* offset within the file is irrelevant since the swapfile code maps logical |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |