[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: |
David Gibson |
Subject: |
Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started" |
Date: |
Fri, 2 Sep 2016 16:10:14 +1000 |
On Fri, 2 Sep 2016 13:37:33 +0800
Peter Xu <address@hidden> wrote:
> On Fri, Sep 02, 2016 at 02:15:04PM +1000, David Gibson wrote:
> > What!? I see no reason you need a different notifier, just fix the
> > implementation of the current one. As a bonus this will also give you
> > working VFIO passthrough with vIOMMU on x86, something which should
> > work already, but doesn't.
>
> Hi, David,
>
> Do you mean that we can enhance the interface to suite the two needs?
> E.g., adding a "IOTLB notification type" definition:
>
> - "full": for those who is listening on all mapping changes including
> additions (VFIO use case)
>
> - "cache_only": for those who only cares about cache invalidations
> (device IOTLB, aka, vhost use case)
>
> We can:
>
> - add notify type when we register the notifiers (e.g., when VFIO
> registers IOMMU notifier, it should specify the type as "full", so
> it won't receive notification if it's device IOTLB invalidations).
>
> - pass this type when trigger the notification, so for each IOMMU
> notify handler, it can selectively disgard the notification.
>
> Not sure whether above makes sense.
No, implement the full notifier, and a listener which only wants the
invalidates can just ignore callbacks which add new mappings.
As I said, you'll need this to get VFIO working with vIOMMU which
someone is bound to want soon enough anyway.
--
David Gibson <address@hidden>
Senior Software Engineer, Virtualization, Red Hat
pgpuKd8tHuJ7W.pgp
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", David Gibson, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", Peter Xu, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started",
David Gibson <=
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", Peter Xu, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", Peter Xu, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", David Gibson, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", Peter Xu, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", Alex Williamson, 2016/09/02
- Re: [Qemu-devel] [PATCH for 2.8 10/11] Revert "intel_iommu: Throw hw_error on notify_started", Peter Xu, 2016/09/05