Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\memcontrol.c Create Date:2022-07-28 16:14:21
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:uncharge_page

Proto:static void uncharge_page(struct page *page, struct uncharge_gather *ug)

Type:void

Parameter:

TypeParameterName
struct page *page
struct uncharge_gather *ug
6515  VM_BUG_ON_PAGE(PageLRU(page), page)
6516  VM_BUG_ON_PAGE(page_count(page) && !is_zone_device_page(page) && !PageHWPoison(page), page)
6519  If Not mem_cgroup Then Return
6528  If memcg != mem_cgroup Then
6529  If memcg Then
6530  uncharge_batch(ug)
6533  memcg = mem_cgroup
6536  If Not If kmemcg is enabled, the buddy allocator will set PageKmemcg() on* pages allocated with __GFP_ACCOUNT. It gets cleared on page free. Then
6537  nr_pages = 1
6541  nr_huge += nr_pages
6543  If PageAnon(page) Then nr_anon += nr_pages
6545  Else
6546  nr_file += nr_pages
6547  If PageSwapBacked(page) Then nr_shmem += nr_pages
6550  pgpgout++
6551  Else
6552  nr_kmem += Returns the number of pages in this potentially compound page.
6553  If kmemcg is enabled, the buddy allocator will set PageKmemcg() on* pages allocated with __GFP_ACCOUNT. It gets cleared on page free.
6556  dummy_page = page
6557  mem_cgroup = NULL
Caller
NameDescribe
uncharge_list
mem_cgroup_unchargemem_cgroup_uncharge - uncharge a page*@page: page to uncharge* Uncharge a page previously charged with mem_cgroup_try_charge() and* mem_cgroup_commit_charge().