Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\mlock.c Create Date:2022-07-28 14:45:26
Last Modify:2022-05-23 14:12:58 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Prepare page for fast batched LRU putback via putback_lru_evictable_pagevec()* The fast path is available only for evictable pages with single mapping.* Then we can bypass the per-cpu pvec and get better performance.

Proto:static bool __putback_lru_fast_prepare(struct page *page, struct pagevec *pvec, int *pgrescued)

Type:bool

Parameter:

TypeParameterName
struct page *page
struct pagevec *pvec
int *pgrescued
249  VM_BUG_ON_PAGE(PageLRU(page), page)
250  VM_BUG_ON_PAGE(!PageLocked(page), page)
252  If page_mapcount(page) <= 1 && page_evictable - test whether a page is evictable*@page: the page to test* Test whether page is evictable--i Then
253  Add a page to a pagevec. Returns the number of slots still available.
254  If TestClearPageUnevictable(page) Then pgrescued++
256  lock_page - unlock a locked page*@page: the page* Unlocks the page and wakes up sleepers in ___wait_on_page_locked().* Also wakes sleepers in wait_on_page_writeback() because the wakeup* mechanism between PageLocked pages and PageWriteback pages is shared.
257  Return true
260  Return false
Caller
NameDescribe
__munlock_pagevecMunlock a batch of pages from the same zone* The work is split to two main phases