qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v4 RESEND 0/3] IOMMU: intel_iommu support map an


From: Peter Xu
Subject: Re: [Qemu-devel] [PATCH v4 RESEND 0/3] IOMMU: intel_iommu support map and unmap notifications
Date: Mon, 31 Oct 2016 14:47:19 +0800
User-agent: Mutt/1.5.24 (2015-08-30)

On Fri, Oct 21, 2016 at 08:43:05AM -0600, Alex Williamson wrote:

[...]

> > > Well, I think that would work.  But I think it would be better to fix
> > > it from the other side:
> > > 
> > > We add the range to be notified into the IOMMUNotifier structure and
> > > filter based on that range in memory_region_notify_iommu.
> > > 
> > > It means a little more list searching and filtering on notify, but it
> > > avoids having to have another list and search on the VFIO side.  I
> > > think it will also better deal with cases where part of an IOMMU
> > > mapped region is inaccessible due to an intermediate bridge.  
> > 
> > IIUC, this will still need to keep several VFIOGuestIOMMUs which
> > contains exactly the same content?
> 
> The contain different offsets since this is based on the section rather
> than the MemoryRegion.  Thanks,

Though vfio_listener_region_add() is per memory region section,
VFIOGuestIOMMU looks like to be for memory region? See in
vfio_listener_region_add():

        giommu->iommu_offset = section->offset_within_address_space -
                               section->offset_within_region;

Here VFIOGuestIOMMU.iommu_offset should be the offset of memory
region (rather than memory region section offset), right?

Thanks,

-- peterx



reply via email to

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