iommu_unmap(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… iommu_unmap β€” bestie's guide to tearing down IOVA mappings πŸ’…

okay so this page is from the Kernel API Manual (yes, the iommu_unmap(9) one, the icon herself ✨). Sit down, grab a strawberry drink πŸ“, and let's get into it.


✨ NAME ✨

iommu_unmap β€” literally removes mappings from a range of IOVA. that's it, that's the vibe 🌸


πŸ¦‹ SYNOPSIS πŸ¦‹

size_t iommu_unmap (struct iommu_domain *domain , unsigned long iova ,
       size_t size );

look at her. three arguments, returns a size_t, no notes πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • domain β€” the domain you're manipulating. your little playground 🫢
  • iova β€” the IO virtual address where you're starting. the starting line, the main character's entrance ✨
  • size β€” the length of the range, counting from iova. how far the vibe extends πŸ’œ

πŸ”₯ DESCRIPTION πŸ”₯

so iommu_unmap will remove a translation that was created by iommu_map. like, undoing what the other girl did πŸ™ˆ. it's giving cleanup era.

IMPORTANT bestie: it cannot subdivide a mapping created by iommu_map. so like, you gotta call it with IOVA ranges that match what was passed to iommu_map β€” no cap, no splitting, no "close enough" energy πŸ’€.

the range can aggregate contiguous iommu_map calls though β€” so long as no individual range is split. so you CAN group them, you just can't slice one in half. periodt. πŸ‘‘


⭐ RETURN ⭐

returns the number of bytes of IOVA unmapped. and heads up: iova + res will be the point where unmapping stopped. that's how you know where she got to before she clocked out πŸ’…


🌈 SEE ALSO 🌈

Kernel file ./drivers/iommu/iommu.c β€” and honestly the whole group chat showed up, so here they all are, every single one, iykyk:


and that's the page, bestie πŸ§šπŸ’– keep it in this directory: ./drivers/iommu, dated October 2026, and go unmap something responsibly. slay πŸŽ€βœ¨

πŸ“¦ where this page comes from