remap_vmalloc_range(9)
π remap_vmalloc_range(9) π
okay bestie, welcome to the Kernel API Manual page for remap_vmalloc_range(9) β it's giving βmap vmalloc pages to userspaceβ and it's lowkey iconic. no cap, let's get into it π«Άβ¨
π NAME π
remap_vmalloc_range β map vmalloc pages to userspace π
β¨ SYNOPSIS β¨
int remap_vmalloc_range (struct vm_area_struct *vma , void *addr ,
unsigned long pgoff );
π ARGUMENTS π
vmaβ the vma to cover, bestie: map the full range of vma. πaddrβ vmalloc memory. literally the memory in question.pgoffβ number of pages intoaddrbefore the first page to map. yes, that's the offset vibe.
πΈ RETURN πΈ
0 for success, -Exxx on failure. that's it, that's the whole return section π
π¦ DESCRIPTION π¦
okay so this function checks that addr is a valid vmalloc'ed area, and that it is big enough to cover the vma. Will return failure if that criteria isn't met. periodt.
Similar to remap_pfn_range (see mm/memory.c). π
π₯ SEE ALSO π₯
Kernel file ./mm/vmalloc.c β and here's the whole friend group, bestie:
vunmap_range(9)vmap_pages_range(9)vm_area_map_pages(9)vm_area_unmap_pages(9)new_vmap_block(9)vm_unmap_aliases(9)vm_unmap_ram(9)vm_map_ram(9)vm_area_add_early(9)vm_area_register_early(9)get_vm_area(9)find_vm_area(9)remove_vm_area(9)vfree_atomic(9)vfree(9)vunmap(9)vmap(9)vmap_pfn(9)__vmalloc_node_range(9)__vmalloc_node(9)vmalloc(9)vmalloc_huge_node(9)vzalloc(9)vmalloc_user(9)vmalloc_node(9)vzalloc_node(9)vrealloc_node_align(9)vmalloc_32(9)vmalloc_32_user(9)vread_iter(9)remap_vmalloc_range_partial(9)pvm_find_va_enclose_addr(9)pvm_determine_end_from_reverse(9)pcpu_get_vm_areas(9)pcpu_free_vm_areas(9)
xoxo, bestie β this page's source/version is ./mm, dated October 2026 π
β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms