iommufd_viom..._hwpt_nested(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… iommufd_viom..._hwpt_nested(9) β€” the kernel API manual, but make it make sense

okay so bestie, welcome to the iommufd_viom..._hwpt_nested(9) page ✨ (yes the title got truncated, the kernel is dramatic like that 😭). This is the Kernel API Manual era of your life now, and honestly? You're gonna slay it.


✨ NAME ✨

iommufd_viommu_alloc_hwpt_nested β€” get a hwpt_nested for a vIOMMU πŸŽ€

Like, that's the whole vibe. You got a virtual IOMMU, you want a nested hardware pagetable for it, this is the function. Periodt.


🌸 SYNOPSIS 🌸

struct iommufd_hwpt_nested * iommufd_viommu_alloc_hwpt_nested (struct
iommufd_viommu *viommu , u32 flags , const struct iommu_user_data
*user_data );

Copy it exactly, don't retype it from memory, I'm begging you πŸ™ˆ β€” return type is struct iommufd_hwpt_nested *, and it takes three args, in that order: a struct iommufd_viommu *viommu, a u32 flags, and a const struct iommu_user_data *user_data. No cap.


πŸ¦‹ ARGUMENTS πŸ¦‹

  • viommu β€” the vIOMMU ojbect to associate the hwpt_nested/domain with 🫢 (the original page really does spell it "ojbect" and honestly? iconic. we keep it. it's part of the lore.)
  • flags β€” flags, straight from userspace πŸ’«
  • user_data β€” the user_data pointer. Must be valid. 🚨 Not "probably valid", not "valid-ish", valid. Do not come in here with a garbage pointer, that's not the main character energy we're going for πŸ’€

πŸ”₯ DESCRIPTION πŸ”₯

So what does it actually do? It allocates a brand new IOMMU_DOMAIN_NESTED for a vIOMMU 🌈 and hands it back to you as a NESTED hw_pagetable. That's it, that's the function. Allocate, nest, return, slay. πŸ‘‘


πŸŽ€ SEE ALSO πŸŽ€


Lowkey a flex: this page lives at ./drivers/iommu/iommufd, dated October 2026, in the Kernel API Manual. Bestie, in the Linux kernel, in the future. Obsessed. πŸ¦‹πŸ’œ

okay bye, go allocate your nested hwpt responsibly, mwah πŸ’‹

πŸ“¦ where this page comes from