Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:vmap - map an array of pages into virtually contiguous space*@pages: array of page pointers*@count: number of pages to map*@flags: vm_area->flags*@prot: page protection for the mapping* Maps @count pages from @pages into contiguous kernel virtual* space

Proto:void *vmap(struct page **pages, unsigned int count, unsigned long flags, pgprot_t prot)

Type:void

Parameter:

TypeParameterName
struct page **pages
unsigned intcount
unsigned longflags
pgprot_tprot
2425  might_sleep()
2427  If count > totalram_pages() Then Return NULL
2430  size = count << PAGE_SHIFT determines the page size
2431  area = get_vm_area_caller(size, flags, __builtin_return_address(0))
2432  If Not area Then Return NULL
2435  If map_vm_area(area, prot, pages) Then
2436  vunmap - release virtual mapping obtained by vmap()*@addr: memory base address* Free the virtually contiguous memory area starting at @addr,* which was created from the page array passed to vmap().* Must not be called in interrupt context.
2437  Return NULL
2440  Return addr
Caller
NameDescribe
relay_alloc_buflay_alloc_buf - allocate a channel buffer*@buf: the buffer struct*@size: total size of the buffer* Returns a pointer to the resulting buffer, %NULL if unsuccessful. The* passed in size will get page aligned, if it isn't already.