qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v7 0/5] IOMMU: intel_iommu support map and unmap


From: Alex Williamson
Subject: Re: [Qemu-devel] [PATCH v7 0/5] IOMMU: intel_iommu support map and unmap notifications
Date: Tue, 6 Dec 2016 09:58:46 -0700

On Tue, 6 Dec 2016 18:59:14 +0800
Peter Xu <address@hidden> wrote:

> On Tue, Dec 06, 2016 at 04:27:39PM +0800, Lan Tianyu wrote:
> 
> [...]
> 
> > >   
> > >> User space driver(E.G DPDK) also can enable/disable
> > >> IOVA for device dynamically.  
> > > 
> > > Could you provide more detailed (or any pointer) on how to do that? I
> > > did try to find it myself, I see an VFIO_IOMMU_ENABLE ioctl, but looks
> > > like it is for ppc only.  
> > 
> > No, I just give an example that user space may do that but no more
> > research. But since Qemu already can enable device's IOVA, other user
> > application also should can do that with the same VFIO interface, right?  
> 
> AFAIU we can't do that at least on x86. We can use vfio interface to
> bind group into container, but we should not be able to dynamically
> disable IOMMU protection. IIUC That needs to taint the kernel.
> 
> The only way I know is that we probe vfio-pci with no-iommu mode, in
> that case, we disabled IOMMU, but we can never dynamically enable it
> as well.
> 
> Please correct me if I am wrong.

A vfio user such as QEMU enabling or disabling translation in the
vIOMMU is "simply" assigning the vfio container to the system
AddressSpace (as we do w/o vIOMMU) or the device specific, IOMMU domain,
AddressSpace.  The device must be protected by the pIOMMU domain
(container) at all times.  Thanks,

Alex



reply via email to

[Prev in Thread] Current Thread [Next in Thread]