All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Roedel, Joerg" <Joerg.Roedel@amd.com>
To: Jan Kiszka <jan.kiszka@web.de>
Cc: Avi Kivity <avi@redhat.com>,
	Marcelo Tosatti <mtosatti@redhat.com>, kvm <kvm@vger.kernel.org>,
	Zachary Amsden <zamsden@redhat.com>
Subject: Re: [PATCH v2] KVM: Fix order passed to iommu_unmap
Date: Thu, 27 May 2010 12:08:38 +0200	[thread overview]
Message-ID: <20100527100838.GS3266@amd.com> (raw)
In-Reply-To: <4BFD7841.9060302@web.de>

On Wed, May 26, 2010 at 03:36:33PM -0400, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
> 
> This is obviously a left-over from the the old interface taking the
> size. Apparently a mostly harmless issue with the current iommu_unmap
> implementation.
> 
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>

Uh, good catch.

Acked-by: Joerg Roedel <joerg.roedel@amd.com>

> ---
> 
> I think this one is even closer to the right order. :)
> 
>  virt/kvm/iommu.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/virt/kvm/iommu.c b/virt/kvm/iommu.c
> index 5adc578..673c88a 100644
> --- a/virt/kvm/iommu.c
> +++ b/virt/kvm/iommu.c
> @@ -273,7 +273,7 @@ static void kvm_iommu_put_pages(struct kvm *kvm,
>  		pfn  = phys >> PAGE_SHIFT;
>  
>  		/* Unmap address from IO address space */
> -		order       = iommu_unmap(domain, gfn_to_gpa(gfn), PAGE_SIZE);
> +		order       = iommu_unmap(domain, gfn_to_gpa(gfn), 0);
>  		unmap_pages = 1ULL << order;
>  
>  		/* Unpin all pages we just unmapped to not leak any memory */
> 


  reply	other threads:[~2010-05-27 10:08 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-26 19:29 [PATCH] KVM: Fix order passed to iommu_unmap Jan Kiszka
2010-05-26 19:36 ` [PATCH v2] " Jan Kiszka
2010-05-27 10:08   ` Roedel, Joerg [this message]
2010-05-27 12:40   ` Avi Kivity

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100527100838.GS3266@amd.com \
    --to=joerg.roedel@amd.com \
    --cc=avi@redhat.com \
    --cc=jan.kiszka@web.de \
    --cc=kvm@vger.kernel.org \
    --cc=mtosatti@redhat.com \
    --cc=zamsden@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.