Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:include\linux\hugetlb_cgroup.h Create Date:2022-07-28 15:24:56
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:hugetlb_cgroup_from_page

Proto:static inline struct hugetlb_cgroup *hugetlb_cgroup_from_page(struct page *page)

Type:struct hugetlb_cgroup

Parameter:

TypeParameterName
struct page *page
31  VM_BUG_ON_PAGE(!PageHuge(page), page)
33  If compound_order(page) < Minimum page order trackable by hugetlb cgroup.* At least 3 pages are necessary for all the tracking information. Then Return NULL
35  Return *@private: Mapping-private opaque data. * Usually used for buffer_heads if PagePrivate. * Used for swp_entry_t if PageSwapCache. * Indicates order in the buddy system if PageBuddy.
Caller
NameDescribe
update_and_free_page
hugetlb_cgroup_move_parentShould be called with hugetlb_lock held.* Since we are holding hugetlb_lock, pages cannot get moved from* active list or uncharged from the cgroup, So no need to get* page reference and test for page active here. This function* cannot fail.
hugetlb_cgroup_uncharge_pageShould be called with hugetlb_lock held
hugetlb_cgroup_migratehugetlb_lock will make sure a parallel cgroup rmdir won't happen* when we migrate hugepages