On Wed, May 28, 2025 at 02:09:41PM -0600, Alex Williamson wrote: > To be fair to libvirt, we'd really like libvirt to make use of iommufd > whenever it's available, but without feature parity this would break > users. If people ask there should be no issue with making API functionality discoverable with a query command of some kind. Alot of new stuff is already discoverable by invoking an ioctl with bogus arguments and checking for EOPNOTSUPP/ENOTTY. But most likely P2P will use the same ioctl as memfd so it will not work that way. So for now libvirt could assume no P2P support in iommufd. A simple algorithm would be to look for more than 1 VFIO device. Or add an xml "disable P2P" which is a useful thing anyhow. > Zhe, so if you have no dependencies on P2P DMA within your device > assignment VMs, the options above may be useful or at least a data > point for comparison of type1 vs IOMMUFD performance. Thanks, Even if Zhe does have P2P DMA I have a feeling the OOT P2P patch may be workable <shrug> Jason