函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:include\linux\hugetlb_cgroup.h Create Date:2022-07-27 16:55:37
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:hugetlb_cgroup_from_page

函数原型:static inline struct hugetlb_cgroup *hugetlb_cgroup_from_page(struct page *page)

返回类型:struct hugetlb_cgroup

参数:

类型参数名称
struct page *page
31  VM_BUG_ON_PAGE(!PageHuge(page), page)
33  如果compound_order(page)小于Minimum page order trackable by hugetlb cgroup.* At least 3 pages are necessary for all the tracking information.则返回:NULL
35  返回:私有数据指针
调用者
名称描述
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