mshv_chunk_stride(9)
π mshv_chunk_stride(9) β like, the whole kernel API manual vibe β¨
okay so bestie, we're in the Kernel API Manual today and the star of the show is mshv_chunk_stride(9). this is a section 9 page, iykyk π
πΈ NAME πΈ
mshv_chunk_stride β literally just computes the stride for mapping guest memory π«Ά
β¨ SYNOPSIS β¨
unsigned int mshv_chunk_stride (struct page *page , u64 gfn , u64
page_count );
that's the whole signature, no cap, copy it exactly the way it is π
π ARGUMENTS π
pageβ the page to check for huge page backing π like, is this thing huge-page-backed or not, that's the questiongfnβ the guest frame number for the mapping, iconic little coordinate fr frpage_countβ total number of pages in the mapping π« the whole squad
π¦ DESCRIPTION π¦
so what does it actually do. it determines the appropriate stride (in pages) for mapping guest memory. main character energy honestly π
the way it works: it uses the huge page stride if the backing page is huge and the guest mapping is properly aligned. otherwise? it falls back to single page stride. no drama, just vibes π
bestie note: both conditions matter β huge backing page and proper alignment. miss one and you're on the single-page path, periodt π
π₯ RETURN π₯
Stride in pages. that's it. that's the return value π
π SEE ALSO π
- Kernel file
./drivers/hv/mshv_regions.cπ mshv_region_process_chunk(9)mshv_region_process_range(9)mshv_region_range_fault(9)mshv_region_interval_invalidate(9)
go read the whole friend group, they're all linked together π§π
and that's the page!! π this one lives in ./drivers/hv, dated October 2026, so like, mark your calendars bestie π
β¨ mwah π
π¦ 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