ALLOC_PAGE_VMA

Section: (9)
Updated: 09 October 2005
Index Return to Main Contents

 

NAME

alloc_page_vma - Allocate a page for a VMA.  

SYNOPSIS

"SYNOPSIS"

struct page * alloc_page_vma (unsigned int __nocast gfp, struct vm_area_struct * vma, unsigned long addr);  

ARGUMENTS

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.
vma
Pointer to VMA or NULL if not available.
addr
Virtual Address of the allocation. Must be inside the VMA.
 

DESCRIPTION

This function allocates a page from the kernel page pool and applies a NUMA policy associated with the VMA or the current process. When VMA is not NULL caller must hold down_read on the mmap_sem of the mm_struct of the VMA to prevent it from going away. Should be used for all allocations for pages that will be mapped into user space. Returns NULL when no page can be allocated.

Should be called with the mm_sem of the vma hold.  

DESCRIPTION

This function allocates a page from the kernel page pool and applies a NUMA policy associated with the VMA or the current process. When VMA is not NULL caller must hold down_read on the mmap_sem of the mm_struct of the VMA to prevent it from going away. Should be used for all allocations for pages that will be mapped into user space. Returns NULL when no page can be allocated.

Should be called with the mm_sem of the vma hold.


 

Index

NAME
SYNOPSIS
ARGUMENTS
DESCRIPTION
DESCRIPTION

This document was created by man2html, using the manual pages.
Time: 00:01:55 GMT, October 09, 2005