函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Test all pages in the range is free(means isolated) or not.* all pages in [start_pfn...end_pfn) must be in the same zone.* zone->lock must be held before call this.* Returns the last tested pfn.

函数原型:static unsigned long __test_page_isolated_in_pageblock(unsigned long pfn, unsigned long end_pfn, int flags)

返回类型:unsigned long

参数:

类型参数名称
unsigned longpfn
unsigned longend_pfn
intflags
265 pfn小于end_pfn循环
266  如果非pfn_valid_within(pfn)则
267  pfn自加
268  继续下一循环
270  page等于pfn_to_page(pfn)
271  如果PageBuddy() indicates that the page is free and in the buddy system* (see mm/page_alloc.c).pfn加等于1左移page_order(page)位
278  否则如果flags按位与MEMORY_OFFLINEPageHWPoison(page)则pfn自加
281  否则退出
285  返回:pfn
调用者
名称描述
test_pages_isolatedCaller should ensure that requested range is in a single zone