pcpu_depopulate_chunk(9)
π pcpu_depopulate_chunk β a.k.a. the Kernel API Manual glow-up π¦
okay so bestie, welcome to the pcpu_depopulate_chunk(9) page β yes that's the function name and the manual name, we love a multitasking icon π
β¨ NAME β¨
pcpu_depopulate_chunk β depopulate and unmap an area of a pcpu_chunk. two jobs, one function, main character energy fr fr π
π SYNOPSIS π
void pcpu_depopulate_chunk (struct pcpu_chunk *chunk , int page_start ,
int page_end );
like, that's the whole vibe. void return, no notes. π«Ά
πΈ ARGUMENTS πΈ
chunkβ the chunk to depopulate. this is the girl we're clearing out β¨page_startβ the start page. where the chaos begins πpage_endβ the end page. where the chaos stops π
π DESCRIPTION π
so for each cpu (like, every single one, no skipping π€), it depopulates and unmaps the pages in [page_start,page_end) from chunk. inclusive start, exclusive end, the way that bracket notation literally always is, iykyk π§
β οΈ heads up bestie β the caller is required to callpcpu_post_unmap_tlb_flushif it's not returning the region back tovmalloc, which will lazily flush the tlb. not optional, not a suggestion, this is the rule π
π CONTEXT π
pcpu_alloc_mutex. that's it. that's the whole section. lock in (literally) π₯
π SEE ALSO π
kernel file ./mm/percpu-vm.c plus the whole friend group:
pcpu_get_pages(9)pcpu_free_pages(9)pcpu_alloc_pages(9)pcpu_pre_unmap_flush(9)pcpu_unmap_pages(9)pcpu_post_unmap_tlb_flush(9)pcpu_map_pages(9)pcpu_post_map_flush(9)pcpu_populate_chunk(9)pcpu_should_reclaim_chunk(9)
and that's the page, bestie π sign-off szn: this one lives in ./mm, it's the October 2026 edition, and it's filed under pcpu_depopulate_chunk(9) β no cap, go slay your percpu cleanup πβ¨
π¦ 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