Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Common helper to allocate a fresh hugetlb page. All specific allocators* should use this function to get new hugetlb pages

Proto:static struct page *alloc_fresh_huge_page(struct hstate *h, gfp_t gfp_mask, int nid, nodemask_t *nmask, nodemask_t *node_alloc_noretry)

Type:struct page

Parameter:

TypeParameterName
struct hstate *h
gfp_tgfp_mask
intnid
nodemask_t *nmask
nodemask_t *node_alloc_noretry
1393  If hstate_is_gigantic(h) Then page = alloc_gigantic_page(h, gfp_mask, nid, nmask)
1395  Else page = alloc_buddy_huge_page(h, gfp_mask, nid, nmask, node_alloc_noretry)
1398  If Not page Then Return NULL
1401  If hstate_is_gigantic(h) Then prep_compound_gigantic_page(page, huge_page_order(h))
1403  prep_new_huge_page(h, page, page_to_nid(page))
1405  Return page
Caller
NameDescribe
alloc_pool_huge_pageAllocates a fresh page to the hugetlb allocator pool in the node interleaved* manner.
alloc_surplus_huge_pageAllocates a fresh surplus page from the page allocator.
alloc_migrate_huge_page