函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:__isolate_free_page

函数原型:int __isolate_free_page(struct page *page, unsigned int order)

返回类型:int

参数:

类型参数名称
struct page *page
unsigned intorder
3129  area等于伙伴系统空闲内存页[order]
3134  BUG_ON(!PageBuddy() indicates that the page is free and in the buddy system* (see mm/page_alloc.c).)
3136  zone等于page_zone(page)
3137  mt等于get_pageblock_migratetype(page)
3139  如果非is_migrate_isolate(mt)则
3146  watermark等于 zone watermarks, access with *_wmark_pages(zone) macros [WMARK_MIN]加1UL左移order位的值
3147  如果非zone_watermark_ok(zone, 0, watermark, 0, allow allocations from CMA areas )则返回:0
3150  __mod_zone_freepage_state(zone, - (1UL << order), mt)
3155  del_page_from_free_area(page, area)
3161  如果order大于等于Huge pages are a constant size 减1则
3162  endpage等于page加1左移order位的值减1
3163 page小于endpage循环
3173  返回:1UL左移order
调用者
名称描述
unset_migratetype_isolate
isolate_freepages_blockIsolate 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).