[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Unshared IOMMU issues
>>> On 15.02.17 at 18:43, <olekstysh@xxxxxxxxx> wrote: > 1. > I need: > Allow P2M core on ARM to update IOMMU mapping from the first "p2m_set_entry". > I do: > I explicitly set need_iommu flag for *every* guest domain during > iommu_domain_init() on ARM in case if page table is not shared. > At that moment I have no knowledge about will any device be assigned > to this domain or not. I am just want to receive all mapping updates > from P2M code. The P2M will update IOMMU mapping only when need_iommu > is set and page table is not shared. > I have doubts: > Is it correct to just force need_iommu flag? No, I don't think so. This is a waste of a measurable amount of resources when page tables aren't shared. > Or maybe another flag should be introduced? Not sure what you think of here. Where's the problem with building IOMMU page tables at the time the first device gets assigned, just like x86 does? > Or we don't need to check for need_iommu flag before updating IOMMU > mapping in P2M code, maybe iommu_enabled would be enough? No, afaict that would again mean maintaining IOMMU page tables regardless of whether they're needed. > 2. > I need: > Allow IOMMU driver to be ready to handle IOMMU mapping updates from > the first "p2m_set_entry". Why (see also the question above)? > I do: > I always allocate IOMMU page table during iommu_domain_init() for every > domain even this domain won't have any assigned devices in future. I > don't wait for iommu_construct. > I have doubts: > Is it correct? It might be just wasting memory and CPU time if domain > doesn't have any assigned devices in future. Indeed. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |