Fix IOMMU unassign bug and add translate opcode

unassign_device: clear DTE and submit hardware INVALIDATE_DEVTAB_ENTRY
and INVALIDATE_INTERRUPT_TABLE commands with completion wait (was
previously only clearing the software HashMap).

TRANSLATE opcode (0x0012): walk IOMMU page tables for IOVA-to-physical
address resolution.

fstat: return proper MODE_DIR/MODE_FILE and sizes for all handle kinds
(Root, Control, Domain, Device).

Remove #TODO from recipe.toml.
This commit is contained in:
2026-04-25 18:07:58 +01:00
parent 530eb841db
commit 02ff2f554f
4 changed files with 82 additions and 11 deletions
@@ -628,6 +628,10 @@ impl DomainPageTables {
pub fn mapping_count(&self) -> usize {
self.mappings.len()
}
pub fn translate(&self, iova: u64) -> Option<u64> {
self.page_table.translate(iova)
}
}
fn align_up(value: u64, align: u64) -> Option<u64> {