free_mem_extents(9)
π free_mem_extents(9) β a kernel API manual moment π
okay so bestie, welcome to the section 9 girlies β this is kernel API manual territory, where we talk about functions the kernel calls on itself, not the stuff you type into a shell. and today's main character is free_mem_extents, which is exactly what it says on the tin: it frees a list of memory extents. that's it. that's the whole vibe. π
β¨ NAME β¨
free_mem_extents β free a list of memory extents, no cap π
πΈ SYNOPSIS πΈ
void free_mem_extents (struct list_head *list );
literally that's the whole signature. void β she returns nothing, she's done when she's done, periodt. π«Ά
π¦ ARGUMENTS π¦
listβ the list of extents to free. that's the list. the extents in it? they get freed. iconic behaviour, honestly.
π SEE ALSO π
okay this is the part where the manpage just goes full group-chat roster and tags everyone in the kernel file ./kernel/power/snapshot.c. not me listing all 26 of them, but here we are, and honestly every single one ate:
get_image_page(9)free_image_page(9)alloc_rtree_node(9)create_mem_extents(9)memory_bm_next_pfn(9)mark_nosave_pages(9)create_basic_memory_bitmaps(9)free_basic_memory_bitmaps(9)snapshot_additional_pages(9)count_free_highmem_pages(9)count_highmem_pages(9)count_data_pages(9)swsusp_free(9)preallocate_image_pages(9)free_unnecessary_pages(9)minimum_image_size(9)hibernate_preallocate_memory(9)pack_pfns(9)snapshot_read_next(9)unpack_orig_pfns(9)count_highmem_image_pages(9)prepare_highmem_image(9)copy_last_highmem_page(9)prepare_image(9)snapshot_write_next(9)restore_highmem(9)
likeβ¦ the whole hibernation/snapshot friend group showed up to the function. iykyk π
and yeah, they're all in ./kernel/power/snapshot.c β go say hi, they don't bite π§
and that's the page, bestie! π this lil kernel API manual entry lives in ./kernel/power and it's dated October 2026 β so when you're reading it, know that future-you said hi. slay, bye! πβ¨π
π¦ 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