pub enum DmaPassthrough<'a> {
Allowed,
SoftwareBlocked,
HardwareNestable(&'a (dyn Any + Send + Sync)),
}Expand description
How a device’s DMA relates to host passthrough (VFIO assignment).
This is the only IOMMU-related view exposed to consumers of
DmaTarget. It deliberately says nothing about how guest memory is
translated (that is the underlying DmaTargetIommu factory); it only
answers “can this device be handed to the host for passthrough, and if
so, how does the assignment backend attach to the IOMMU?”.
Variants§
Allowed
No IOMMU, or none relevant to passthrough — host assignment allowed.
SoftwareBlocked
Behind a software/emulated IOMMU that cannot program the host IOMMU for passthrough DMA — host assignment rejected.
HardwareNestable(&'a (dyn Any + Send + Sync))
Behind a hardware-nestable IOMMU — host assignment allowed. The opaque handle lets the assignment backend (which knows the concrete IOMMU type) downcast and attach to the emulated IOMMU for nested stage-1 translation.