Function report |
Source Code:mm\mempolicy.c |
Create Date:2022-07-28 15:33:04 |
Last Modify:2020-03-17 22:28:11 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:alloc_pages_vma - Allocate a page for a VMA.*@gfp:* %GFP_USER user allocation.* %GFP_KERNEL kernel allocations,* %GFP_HIGHMEM highmem/user allocations,* %GFP_FS allocation should not call back into a file system.* %GFP_ATOMIC don't sleep.
Proto:struct page *alloc_pages_vma(gfp_t gfp, int order, struct vm_area_struct *vma, unsigned long addr, int node, bool hugepage)
Type:struct page
Parameter:
Type | Parameter | Name |
---|---|---|
gfp_t | gfp | |
int | order | |
struct vm_area_struct * | vma | |
unsigned long | addr | |
int | node | |
bool | hugepage |
2121 | pol = get_vma_policy(@vma, @addr)*@vma: virtual memory area whose policy is sought*@addr: address in @vma for shared policy lookup* Returns effective policy for a VMA at specified address |
2123 | If See MPOL_* above == MPOL_INTERLEAVE Then |
2127 | mpol_cond_put(pol) |
2128 | page = Allocate a page in interleaved policy.Own path because it needs to do special accounting. |
2129 | Go to out |
2133 | hpage_node = node |
2145 | If See MPOL_* above == MPOL_PREFERRED && Not (See set_mempolicy() MPOL_F_* above & preferred local allocation ) Then hpage_node = preferred |
2149 | If Not nmask || No static inline type checking - see Subtlety (1) above. (hpage_node, * nmask) Then |
2150 | mpol_cond_put(pol) |
2155 | page = Allocate pages, preferring the node given as nid. The node must be valid and* online. For more general interface, see alloc_pages_node(). |
2164 | If Not page && gfp & Caller can reclaim Then page = Allocate pages, preferring the node given as nid. The node must be valid and* online. For more general interface, see alloc_pages_node(). |
2168 | Go to out |
2175 | mpol_cond_put(pol) |
2176 | out : |
2177 | Return page |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |