dma_iova_destroy(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

dma_iova_destroy(9) πŸ’… β€” Kernel API Manual edition

okay so bestie, welcome to the Finish a DMA mapping transaction era. This is the Kernel API Manual page for dma_iova_destroy(9), and it's lowkey the cleanup main character. 🧹✨

πŸ’– NAME πŸ’–

dma_iova_destroy β€” Finish a DMA mapping transaction. That's it, that's the name, and it's giving "wrap it up, we're done here" energy. πŸŽ€

✨ SYNOPSIS ✨

the signature, no cap:

void dma_iova_destroy (struct device *dev , struct dma_iova_state *state
, size_t mapped_len , enum dma_data_direction dir , unsigned long attrs
);

🫢 ARGUMENTS 🫢

  • dev β€” DMA device. like, the device doing the DMA thing. πŸ’»
  • state β€” IOVA state. this is the state bestie, keep up. 🌸
  • mapped_len β€” number of bytes to unmap. literal bytes, bestie. πŸ”’
  • dir β€” DMA direction. the direction vibe. 🧭
  • attrs β€” attributes of mapping properties. the property-attrs situation. πŸŽ€

🌈 DESCRIPTION 🌈

Okay so here's the actual tea: this function unlinks the IOVA range up to mapped_len and frees the entire IOVA space. πŸ’…πŸ”₯

The range of IOVA from dma_addr to mapped_len must all be linked, and it must be the only linked IOVA in state. Not "mostly linked", not "kinda linked with a side quest" β€” all linked, and the only linked IOVA in state. Periodt. πŸ‘‘βœ¨

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file: ./drivers/iommu/dma-iommu.c β€” go read the source, iykyk. πŸ“–

xoxo bestie πŸ’– β€” source ./drivers/iommu, version dma_iova_destroy(9), dated October 2026. now go slay that cleanup, mwah. πŸŽ€

πŸ“¦ where this page comes from