Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\vmscan.c Create Date:2022-07-28 14:19:19
Last Modify:2022-05-23 13:41:30 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Returns true if compaction should go ahead for a costly-order request, or* the allocation would already succeed without compaction. Return false if we* should reclaim first.

Proto:static inline bool compaction_ready(struct zone *zone, struct scan_control *sc)

Type:bool

Parameter:

TypeParameterName
struct zone *zone
struct scan_control *sc
2894  suitable = compaction_suitable(zone, Allocation order , 0, The highest zone to isolate pages for reclaim from )
2895  If suitable == COMPACT_SUCCESS Then Return true
2898  If suitable == COMPACT_SKIPPED Then Return false
2911  watermark = high_wmark_pages(zone) + Number of free order-0 pages that should be available above given watermark* to make sure compaction has reasonable chance of not running out of free* pages that it needs to isolate as migration target during its work.
2913  Return zone_watermark_ok_safe(zone, 0, watermark, The highest zone to isolate pages for reclaim from )
Caller
NameDescribe
shrink_zonesThis is the direct reclaim path, for page-allocating processes. We only* try to reclaim pages from zones which will satisfy the caller's allocation* request.* If a zone is deemed to be full of pinned pages then just give it a light