pfnmap_setup_cachemode_pfn(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– pfnmap_setup_cachemode_pfn(9) πŸ’–

okay so bestie, welcome to section 9 of the Kernel API Manual β€” yes we're in kernel-land, bring your ✨serious✨ hat but keep the sparkle. This one's all about pfnmap_setup_cachemode_pfn, and it's honestly shorter than my attention span on a good day, so let's go 🫢


✨ NAME ✨

pfnmap_setup_cachemode_pfn β€” sets up the cachemode in the pgprot for a pfn. that's it. that's the whole job. iconic minimalism πŸ’…


🌸 SYNOPSIS 🌸

void pfnmap_setup_cachemode_pfn (unsigned long pfn , pgprot_t *prot );

like, you hand it a pfn and a pointer to a pgprot, and it does its little cachemode thing. no return value, no drama, no notes πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • pfn β€” the pfn. that's literally the whole description lmao, the pfn is the pfn, we love a self-explanatory king πŸ™ˆ
  • prot β€” the pgprot to modify. this is the glow-up target, bestie, it's getting modified ✨

πŸ¦‹ DESCRIPTION πŸ¦‹

so what actually happens: it looks up the cachemode for pfn and stores it in prot β€” and here's the key part, it leaves all the other data in prot unchanged. not me being respectful of your existing bits 😌 it only touches what it needs to touch, no cap.

for the full tea, go read pfnmap_setup_cachemode β€” that's the big sibling page, this one's like the lil' cousin that just points you there iykyk.


πŸ”₯ SEE ALSO πŸ”₯

Kernel file ./include/linux/pgtable.h β€” and like, an entire friend group of related pages, we're going to list every single one because we don't do half-finished lists here:

lazy_mmu_mode_enable(9), lazy_mmu_mode_disable(9), __task_lazy_mmu_mode_pause(9), lazy_mmu_mode_pause(9), __task_lazy_mmu_mode_resume(9), lazy_mmu_mode_resume(9), pte_batch_hint(9), set_ptes(9), clear_young_dirty_ptes(9), get_and_clear_full_ptes(9), get_and_clear_ptes(9), clear_full_ptes(9), clear_ptes(9), clear_nonpresent_ptes(9), ptep_try_set(9), flush_tlb_before_set(9), wrprotect_ptes(9), clear_flush_young_ptes(9), test_and_clear_young_ptes(9), modify_prot_start_ptes(9), modify_prot_commit_ptes(9), pfnmap_setup_cachemode(9), pfnmap_track(9), pfnmap_untrack(9)

like I said. whole friend group. go say hi 🫢


ok and that's the page!! short, sweet, does exactly one thing and does it well β€” main character energy fr fr πŸ’œ

and that's a wrap bestie!! this lil' beauty comes from ./include/linux, dated October 2026, living its best life in section 9 of the Kernel API Manual. slay, bye πŸ‘‘πŸ’…πŸŽ€

πŸ“¦ where this page comes from