All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nadav Amit <namit@vmware.com>
To: Jon Pan-Doh <pandoh@google.com>
Cc: Joerg Roedel <joro@8bytes.org>,
	Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>,
	Will Deacon <will@kernel.org>,
	Robin Murphy <robin.murphy@arm.com>,
	"iommu@lists.linux.dev" <iommu@lists.linux.dev>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Sudheer Dantuluri <dantuluris@google.com>,
	Gary Zibrat <gzibrat@google.com>
Subject: Re: [PATCH] iommu/amd: Fix domain flush size when syncing iotlb
Date: Wed, 26 Apr 2023 21:22:56 +0000	[thread overview]
Message-ID: <985C9735-6009-449B-BF9A-1293AFBCBDE7@vmware.com> (raw)
In-Reply-To: <7F4D224A-A6A0-46BF-B008-A9E488257639@vmware.com>



> On Apr 26, 2023, at 2:04 PM, Nadav Amit <namit@vmware.com> wrote:
> 
> 
> 
>> On Apr 26, 2023, at 1:32 PM, Jon Pan-Doh <pandoh@google.com> wrote:
>> 
>> When running on an AMD vIOMMU, we observed multiple invalidations (of
>> decreasing power of 2 aligned sizes) when unmapping a single page.
>> 
>> Domain flush takes gather bounds (end-start) as size param. However,
>> gather->end is defined as the last inclusive address (start + size - 1).
>> This leads to an off by 1 error.
>> 
>> With this patch, verified that 1 invalidation occurs when unmapping a
>> single page.
>> 
>> Fixes: a270be1b3fdf ("iommu/amd: Use only natural aligned flushes in a VM")
>> Signed-off-by: Jon Pan-Doh <pandoh@google.com>
>> Tested-by: Sudheer Dantuluri <dantuluris@google.com>
>> Suggested-by: Gary Zibrat <gzibrat@google.com>
>> 
> 
> Sorry for that.
> 
> Acked-by: Nadav Amit <namit@vmware.com>

P.S. I think it is stable-worthy.


  reply	other threads:[~2023-04-26 21:23 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-26 20:32 [PATCH] iommu/amd: Fix domain flush size when syncing iotlb Jon Pan-Doh
2023-04-26 21:04 ` Nadav Amit
2023-04-26 21:22   ` Nadav Amit [this message]
2023-04-28  5:20 ` Vasant Hegde
2023-05-16 20:59 ` Jon Pan-Doh
2023-05-17  4:38   ` Greg KH
2023-05-17  5:54     ` Jon Pan-Doh
2023-05-17  5:49 ` Jon Pan-Doh
2023-05-17  5:58   ` Nadav Amit
2023-05-18  2:05     ` Jon Pan-Doh
2023-05-22 15:34 ` Joerg Roedel
2023-05-05  1:43 Jon Pan-Doh

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=985C9735-6009-449B-BF9A-1293AFBCBDE7@vmware.com \
    --to=namit@vmware.com \
    --cc=dantuluris@google.com \
    --cc=gzibrat@google.com \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pandoh@google.com \
    --cc=robin.murphy@arm.com \
    --cc=suravee.suthikulpanit@amd.com \
    --cc=will@kernel.org \
    /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.