On Tue, Jan 04, 2022 at 11:06:31AM -0600, Bjorn Helgaas wrote: > > The existing vfio framework allows the portdrv driver to be bound > > to the bridge while its downstream devices are assigned to user space. > > I.e., the existing VFIO framework allows a switch to be in the same > IOMMU group as the devices below it, even though the switch has a > kernel driver and the other devices may have userspace drivers? Yes, this patch exists to maintain current VFIO behavior which has this same check. I belive the basis for VFIO doing this is that the these devices cannot do DMA, so don't care about the DMA API or the group->domain, and do not expose MMIO memory so do not care about the P2P attack. A comment in the code to this effect would be good, IMHO. Jason