> From: Jason Gunthorpe <j...@nvidia.com> > Sent: Friday, June 4, 2021 8:34 PM > > On Fri, Jun 04, 2021 at 06:08:28AM +0000, Tian, Kevin wrote: > > > In Qemu case the problem is that it doesn't know the list of devices > > that will be attached to an IOASID when it's created. This is a guest- > > side knowledge which is conveyed one device at a time to Qemu > > though vIOMMU. > > At least for the guest side it is alot simpler because the vIOMMU > being emulated will define nearly everything. > > qemu will just have to ask the kernel for whatever it is the guest is > doing. If the kernel can't do it then qemu has to SW emulate. > > The no-snoop block may be the only thing that is under qemu's control > because it is transparent to the guest. > > This will probably become clearer as people start to define what the > get_info should return. >
Sure. Just to clarify my comment that it is for " Perhaps creating an IOASID should pass in a list of the device labels that the IOASID will be used with". My point is that Qemu doesn't know this fact before the guest completes binding page table to all relevant devices, while IOASID must be created when the table is bound to first device. So Qemu just needs to create IOASID with format that is required for the current device. Incompatibility will be detected when attaching other devices later. Thanks Kevin _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu