qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_err


From: Peter Xu
Subject: Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started"
Date: Mon, 5 Sep 2016 14:28:32 +0800
User-agent: Mutt/1.5.24 (2015-08-30)

On Fri, Sep 02, 2016 at 09:13:01AM -0600, Alex Williamson wrote:
> Maybe memory_region_register_iommu_notifier() could take an
> IOMMUAccessFlags argument (filter) that is passed to the notify_started
> callback.  If a notifier client only cares about IOMMU_NONE
> (invalidations), intel-iommu could allow it, regardless of the CM
> setting (though I'm dubious whether this is complete in the generic
> case or really only for device iotlbs).  If a client requires IOMMU_RW
> then intel-iommu would currently bomb-out like it does now, or once
> that gets fixed it would bomb if CM=0.  Ideally intel-iommu would
> be fully functional, but somehow it was allowed into the tree
> with this massive gap in support for QEMU iommu interfaces.  Thanks,

Yes, this idea should solve the issue, and looks simple.

This should be based on the assumption that we will have only one
notify register for each IOMMU memory region. However I think that
does suit our use cases (no mix use for the two types).

Meanwhile, I think we can cache this "notifier type" (or
IOMMUAccessFlags) inside that memory region, and we can further verify
the type any time we want (e.g., we can skip the notification if the
type is not matched).

I'll try to post a patch based on your suggestion, and see whether we
like it.

Thanks!

-- peterx



reply via email to

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