[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 3/3] intel-iommu: build iova tree during IOMMU translation
From: |
Peter Xu |
Subject: |
Re: [PATCH 3/3] intel-iommu: build iova tree during IOMMU translation |
Date: |
Fri, 23 Dec 2022 11:22:24 -0500 |
On Fri, Dec 23, 2022 at 04:02:29PM +0800, Jason Wang wrote:
> On Tue, Dec 6, 2022 at 9:58 PM Peter Xu <peterx@redhat.com> wrote:
> >
> > On Tue, Dec 06, 2022 at 11:18:03AM +0800, Jason Wang wrote:
> > > On Tue, Dec 6, 2022 at 7:19 AM Peter Xu <peterx@redhat.com> wrote:
> > > >
> > > > Jason,
> > > >
> > > > On Mon, Dec 05, 2022 at 12:12:04PM +0800, Jason Wang wrote:
> > > > > I'm fine to go without iova-tree. Would you mind to post patches for
> > > > > fix? I can test and include it in this series then.
> > > >
> > > > One sample patch attached, only compile tested.
> > >
> > > I don't see any direct connection between the attached patch and the
> > > intel-iommu?
> >
> > Sorry! Wrong tree dumped... Trying again.
>
> The HWADDR breaks memory_region_notify_iommu_one():
>
> qemu-system-x86_64: ../softmmu/memory.c:1991:
> memory_region_notify_iommu_one: Assertion `entry->iova >=
> notifier->start && entry_end <= notifier->end' failed.
>
> I wonder if we need either:
>
> 1) remove the assert
I vote for this one. Not only removing the assertion, we should probably
crop the range too just like dev-iotlb unmaps?
Thanks,
>
> or
>
> 2) introduce a new memory_region_notify_unmap_all() to unmap from
> notifier->start to notifier->end.
--
Peter Xu