bvec_virt(9)
π bvec_virt(9) β from the Kernel API Manual, bestie β¨
okay so picture this: you're deep in kernel land, you've got a struct bio_vec in your hot little hands, and you just want the virtual address for it. That's the whole gig. This is bvec_virt(9), straight out of the Kernel API Manual, and honestly? iconic. π
β¨ NAME β¨
bvec_virt β returns the virtual address for a bvec. that's it. that's the function. π«Ά
πΈ SYNOPSIS πΈ
void * bvec_virt (struct bio_vec *bvec );
like, verbatim, no cap. one pointer in, one pointer out. π
π¦ ARGUMENTS π¦
bvecβ the bvec you want the virtual address for. that's the one. hand it over, bestie. π
β NOTE β
β οΈ listen up because this part is important: the caller must ensure that bvec->bv_page is not a highmem page. not me stressing about this on your behalf π β that check is your job, not the function's. do not skip it. periodt.
π₯ SEE ALSO π₯
so there's a whole little friend group here, and you should absolutely meet all of them:
- Kernel file
./include/linux/bvec.h struct bio_vec(9)bvec_set_page(9)bvec_set_folio(9)bvec_set_virt(9)bvec_folio(9)bvec_kmap_local(9)memcpy_from_bvec(9)memcpy_to_bvec(9)memzero_bvec(9)bvec_phys(9)
all in the same clique, all doing their own cute little thing. go read them. iykyk. π
mwah π that's the whole page! this lil gem lives in ./include/linux, it's dated October 2026, and it answers to the name bvec_virt(9) β take care of it, she's iconic. πβ¨
π¦ 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