函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:unset_migratetype_isolate

函数原型:static void unset_migratetype_isolate(struct page *page, unsigned migratetype)

返回类型:void

参数:

类型参数名称
struct page *page
unsignedmigratetype
94  bool isolated_page = false
99  zone等于page_zone(page)
100  spin_lock_irqsave( & 自旋锁, flags)
101  如果非is_migrate_isolate_page(page)则转到:out
112  如果PageBuddy() indicates that the page is free and in the buddy system* (see mm/page_alloc.c).
113  order等于page_order(page)
114  如果order大于等于Huge pages are a constant size
115  pfn等于page_to_pfn(page)
117  buddy等于pagebuddy_pfnpfn
132  如果非isolated_page
133  nr_pages等于move_freepages_block(zone, page, migratetype, NULL)
134  __mod_zone_freepage_state(zone, nr_pages, migratetype)
136  set_pageblock_migratetype(page, migratetype)
137  * Number of isolated pageblock. It is used to solve incorrect * freepage counting problem due to racy retrieving migratetype * of pageblock. Protected by zone->lock.自减
138  out :
139  spin_unlock_irqrestore( & 自旋锁, flags)
140  如果isolated_page
141  post_alloc_hook(page, order, ZONE_MOVABLE allowed )
142  __free_pages(page, order)
调用者
名称描述
start_isolate_page_rangestart_isolate_page_range() - make page-allocation-type of range of pages to* be MIGRATE_ISOLATE.*@start_pfn: The lower PFN of the range to be isolated.*@end_pfn: The upper PFN of the range to be isolated.
undo_isolate_page_rangeMake isolated pages available again.