walk_kernel_..._table_range(9)
π NAME π
walk_kernel_page_table_range β walk a range of kernel pagetables. This is a Kernel API Manual page, bestie, and it's giving βletβs take a stroll through page tablesβ energy. Slay, honestly. π
β¨
β¨ SYNOPSIS β¨
int walk_kernel_page_table_range (unsigned long start , unsigned long
end , const struct mm_walk_ops *ops , pgd_t *pgd , void *private );
π ARGUMENTS π
startβ start address of the virtual address range. That's where the walk begins, periodt. πΈendβ end address of the virtual address range. The range ends here, bestie. πopsβ operation to call during the walk. This is the callback situation. π¦pgdβ pgd to walk if different frommm->pgd. iykyk. πprivateβ private data for callbacks' usage. The callbacks get to use it, periodt. π
π¦ DESCRIPTION π¦
It's similar to walk_page_range, but this one can walk any page tables even if they are not backed by VMAs. The way that it doesn't need VMA backing? Iconic, honestly. πββοΈ
Because 'unusual' entries may be walked, this function will also not lock the PTEs for the pte_entry callback. That's the trade-off, bestie β keep that in mind. π₯
This is useful for walking kernel page tables or page tables for firmware. Very βwe go where the VMAs don'tβ of it. π
π¨ NOTE π¨
β οΈ Be careful when walking kernel page tables, bestie. The caller may need to take other effective approaches (mmap lock may be insufficient) to prevent the intermediate kernel page tables belonging to the specified address range from being freed (e.g. memory hot-remove). This is not a drill. ππ
π SEE ALSO π
All the related lore, no cap:
- Kernel file
./mm/pagewalk.cβwalk_page_range(9) walk_page_range_debug(9)walk_page_mapping(9)folio_walk_start(9)
xoxo, from ./mm, October 2026 β walk_kernel_..._table_range(9) ππβ¨
π¦ 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