函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Used when an allocation is about to fail under memory pressure

函数原型:static bool unreserve_highatomic_pageblock(const struct alloc_context *ac, bool force)

返回类型:bool

参数:

类型参数名称
const struct alloc_context *ac
boolforce
2547  zonelist等于zonelist
2561  如果非forcenr_reserved_highatomic小于等于pageblock_nr_pages则继续下一循环
2565  spin_lock_irqsave( & 自旋锁, flags)
2566 order小于Free memory management - zoned buddy allocator. 循环
2567  area等于伙伴系统空闲内存页[order]的地址
2569  page等于get_page_from_free_area(area, MIGRATE_HIGHATOMIC)
2570  如果非page则继续下一循环
2580  如果is_migrate_highatomic_page(page)则
2602  set_pageblock_migratetype(page, migratetype)
2603  ret等于move_freepages_block(zone, page, migratetype, NULL)
2605  如果ret
2607  返回:ret
2610  spin_unlock_irqrestore( & 自旋锁, flags)
2613  返回:false
调用者
名称描述
__alloc_pages_direct_reclaimThe really slow allocator path where we enter direct reclaim
should_reclaim_retryChecks whether it makes sense to retry the reclaim to make a forward progress* for the given allocation request.* We give up when we either have tried MAX_RECLAIM_RETRIES in a row* without success, or when we couldn't even meet the watermark if we