Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Reclaim/compaction is used for high-order allocation requests. It reclaims* order-0 pages before compacting the zone. should_continue_reclaim() returns* true if more pages should be reclaimed such that when the page allocator

Proto:static inline bool should_continue_reclaim(struct pglist_data *pgdat, unsigned long nr_reclaimed, struct scan_control *sc)

Type:bool

Parameter:

TypeParameterName
struct pglist_data *pgdat
unsigned longnr_reclaimed
struct scan_control *sc
2599  If Not Use reclaim/compaction for costly allocs or under memory pressure Then Return false
2612  If Not nr_reclaimed Then Return false
2616  When z <= The highest zone to isolate pages for reclaim from cycle
2617  zone = node_zones[z]
2618  If Not Returns true if a zone has pages managed by the buddy allocator.* All the reclaim decisions have to use this function rather than* populated_zone(). If the whole zone is reserved then we can easily* end up with populated_zone() && !managed_zone(). Then Continue
2622  Case compaction_suitable(zone, Allocation order , 0, The highest zone to isolate pages for reclaim from ) == COMPACT_SUCCESS
2624  Return false
2625  Default
2635  pages_for_compaction = 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.
2636  inactive_lru_pages = node_page_state(pgdat, NR_INACTIVE_FILE)
2637  If get_nr_swap_pages() > 0 Then inactive_lru_pages += node_page_state(pgdat, NR_INACTIVE_ANON)
2640  Return inactive_lru_pages > pages_for_compaction
Caller
NameDescribe
shrink_node