函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:update_and_free_page

函数原型:static void update_and_free_page(struct hstate *h, struct page *page)

返回类型:void

参数:

类型参数名称
struct hstate *h
struct page *page
1060  如果hstate_is_gigantic(h)且非gigantic_page_runtime_supported()则返回
1063  nr_huge_pages自减
1064  nr_huge_pages_node[page_to_nid(page)]自减
1065 i小于pages_per_huge_page(h)循环
1066  体系结构无关页的属性与等于1左移PG_locked位按位或1左移PG_error位按位或1左移PG_referenced位按位或1左移PG_dirty位按位或1左移PG_active位按位或1左移PG_private位按位或1左移PG_writeback位的值的反
1071  VM_BUG_ON_PAGE(hugetlb_cgroup_from_page(page), page)
1072  set_compound_page_dtor(page, NULL_COMPOUND_DTOR)
1073  Turn a non-refcounted page (->_refcount == 0) into refcounted with* a count of one.
1074  如果hstate_is_gigantic(h)则
1075  destroy_compound_gigantic_page(page, huge_page_order(h))
1076  free_gigantic_page(page, huge_page_order(h))
1077  否则
1078  __free_pages(page, huge_page_order(h))
调用者
名称描述
__free_huge_page
free_pool_huge_pageFree huge page from pool from next node to free.* Attempt to keep persistent huge pages more or less* balanced over allowed nodes.* Called with hugetlb_lock locked.
dissolve_free_huge_pageDissolve a given free hugepage into free buddy pages. This function does* nothing for in-use hugepages and non-hugepages.* This function returns values like below:* -EBUSY: failed to dissolved free hugepages or the hugepage is in-use