WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] Re: [PATCH 0/6] IOMMU, vtd and iotlb flush rework (v8)

To: Jean Guyader <jean.guyader@xxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Re: [PATCH 0/6] IOMMU, vtd and iotlb flush rework (v8)
From: Keir Fraser <keir@xxxxxxx>
Date: Thu, 17 Nov 2011 09:20:18 +0000
Cc: allen.m.kay@xxxxxxxxx, tim@xxxxxxx, JBeulich@xxxxxxxx
Delivery-date: Thu, 17 Nov 2011 01:21:12 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:user-agent:date:subject:from:to:cc:message-id:thread-topic :thread-index:in-reply-to:mime-version:content-type :content-transfer-encoding; bh=uvbr8N+AWZJAmpMf2Qo+89gqmvg+gA6LoeHEugXKuM4=; b=F/i/8SWHRXCWJl1FQysTa+gP1zmcVA3GB2qLehysHFQ/bpC6xkO7Q7RO8wJNfRGNiT 7QvolF9Cop4fHQyeZ/WXy2U2kO5V39kHjWnu9f2qdp5Vuy9P6tF6Z+NumvKCSQxO5xAr UI3cgxNeQJpAVcE7ZXoa+fMRg2xs2NRZnwv2s=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1321471508-31633-1-git-send-email-jean.guyader@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcylCh9IfCUEIzJP2EmLf72UxZbYcw==
Thread-topic: [PATCH 0/6] IOMMU, vtd and iotlb flush rework (v8)
User-agent: Microsoft-Entourage/12.31.0.110725
On 16/11/2011 19:25, "Jean Guyader" <jean.guyader@xxxxxxxxxxxxx> wrote:

> 
> In one of my previous email I detailed a bug I was seeing when passing
> through a Intel GPU on a guest that has more that 4G or RAM.
> 
> Allen suggested that I go for the Plan B but after a discussion with Tim
> we agreed that Plan B was way to disruptive in term of code change.
> 
> This patch series implements Plan A.

I'll check these in when they get an Ack from Jan.

 -- Keir

> http://xen.1045712.n5.nabble.com/VTD-Intel-iommu-IOTLB-flush-really-slow-td495
> 2866.html
> 
> Changes between v7 and v8:
>         - Rebase on new add_to_physmap from Andres Lagar-Cavilla
>         - Only do copy_to_guest on the new XENMAPSPACE
> (XENMAPSPACE_gmfn_range).
>         - Convert the xatp argument to a pointer in xenmem_add_to_physmap.
>         - Modify xenmem_add_to_physmap so it doesn't touchs the input (xatp is
> const now).
> 
> Changes between v6 and v7:
>        - xenmem_add_to_physmap_once can't take a pointer on xatp because
>          it modifies .idx and .gpfn.
>        - Cancel hypercall continuation in the compat layer if the
> copy_to_guest
>          failed.
> 
> Changes between v5 and v6:
>       - Rework the patch queue to make it more readable.
>       - Modify xatp in place in xenmem_add_to_physmap
>       - Only check for preemption if we are not at the last iteration
>       - Copy xatp guest handler back to the guest only in case of continuation
>       - Add continuation only when dealing with the new xenmem space
>         (XENMAPSPACE_gmfn_range).
> 
> Changes between v4 and v5:
>       - Fix hypercall continuation for add_to_physmap in compat mode.
> 
> Changes between v3 and v4:
>       - Move the loop for gmfn_range from arch_memory_op to
> xenmem_add_to_physmap.
>       - Add a comment to comment to explain the purpose of
> iommu_dont_flush_iotlb.
> 
> Changes between v2 and v3:
>       - Check for the presence iotlb_flush_all callback before calling it.
> 
> Changes between v1 and v2:
>       - Move size in struct xen_add_to_physmap in padding between .domid and
> .space.
>       - Store iommu_dont_flush per cpu
>       - Change the code in hvmloader to relocate by batch of 64K, .size is now
> 16 bits.
> 
> Jean Guyader (6):
>   vtd: Refactor iotlb flush code
>   iommu: Introduce iommu_flush and iommu_flush_all.
>   add_to_physmap: Move the code for XENMEM_add_to_physmap
>   mm: New XENMEM space, XENMAPSPACE_gmfn_range
>   hvmloader: Change memory relocation loop when overlap with PCI hole
>   Introduce per cpu flag (iommu_dont_flush_iotlb) to avoid unnecessary
>     iotlb flush
> 
>  tools/firmware/hvmloader/pci.c      |   20 +++-
>  xen/arch/x86/mm.c                   |  212
> +++++++++++++++++++++++------------
>  xen/arch/x86/x86_64/compat/mm.c     |   18 +++
>  xen/drivers/passthrough/iommu.c     |   25 ++++
>  xen/drivers/passthrough/vtd/iommu.c |  100 ++++++++++-------
>  xen/include/public/memory.h         |    4 +
>  xen/include/xen/iommu.h             |   17 +++
>  7 files changed, 277 insertions(+), 119 deletions(-)
> 



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel