函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\compaction.c Create Date:2022-07-27 15:55:29
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:solate_freepages_range() - isolate free pages

函数原型:unsigned long isolate_freepages_range(struct compact_control *cc, unsigned long start_pfn, unsigned long end_pfn)

返回类型:unsigned long

参数:

类型参数名称
struct compact_control *cc
unsigned longstart_pfn
unsigned longend_pfn
686  LIST_HEAD(freelist)
688  pfn等于start_pfn
689  block_start_pfn等于pageblock_start_pfn(pfn)
690  如果block_start_pfn小于内存域第一个页帧的索引block_start_pfn等于内存域第一个页帧的索引
692  block_end_pfn等于pageblock_end_pfn(pfn)
694 pfn小于end_pfn循环
698  isolate_start_pfn等于pfn
700  block_end_pfn等于两数取小(block_end_pfn, end_pfn)
707  如果pfn大于等于block_end_pfn
713  如果非pageblock_pfn_to_page(block_start_pfn, block_end_pfn, zone)则退出
717  isolated等于Isolate free pages onto a private freelist. If @strict is true, will abort* returning 0 on any invalid PFNs or non-free pages inside of the pageblock* (even though it may still end up isolating some pages).
725  如果非isolated退出
736  split_map_pages( & freelist)
738  如果pfn小于end_pfn
740  release_freepages( & freelist)
741  返回:0
745  返回:pfn