From: Vinicius Costa Gomes <vinicius.gomes@intel.com>
To: Lu Baolu <baolu.lu@linux.intel.com>,
Joerg Roedel <joro@8bytes.org>, Will Deacon <will@kernel.org>,
Robin Murphy <robin.murphy@arm.com>,
Jason Gunthorpe <jgg@ziepe.ca>, Kevin Tian <kevin.tian@intel.com>
Cc: iommu@lists.linux.dev, linux-kernel@vger.kernel.org,
Lu Baolu <baolu.lu@linux.intel.com>,
stable@vger.kernel.org
Subject: Re: [PATCH 1/2] iommu/vt-d: Set FPD when tearing down a PASID entry with fault_ignore
Date: Thu, 05 Nov 2026 14:01:28 -0800 [thread overview]
Message-ID: <87o6c3uedj.fsf@intel.com> (raw)
In-Reply-To: <20261104051059.1345010-2-baolu.lu@linux.intel.com>
Lu Baolu <baolu.lu@linux.intel.com> writes:
> static void
> pasid_cache_invalidation_with_pasid(struct intel_iommu *iommu,
> u16 did, u32 pasid)
> @@ -253,7 +238,6 @@ void intel_pasid_tear_down_entry(struct intel_iommu *iommu, struct device *dev,
>
> if (!pasid_pte_is_present(pte)) {
> if (!pasid_pte_is_fault_disabled(pte)) {
> - WARN_ON(READ_ONCE(pte->val[0]) != 0);
> spin_unlock(&iommu->lock);
> return;
> }
> @@ -266,6 +250,8 @@ void intel_pasid_tear_down_entry(struct intel_iommu *iommu, struct device *dev,
> */
> pasid_clear_entry(pte);
> spin_unlock(&iommu->lock);
> + if (!ecap_coherent(iommu->ecap))
> + clflush_cache_range(pte, sizeof(*pte));
> intel_iommu_drain_pasid_prq(dev, pasid);
>
I think it's worth documenting in the commit message why both of these
are needed, removing the warning and adding the flush.
Cheers,
--
Vinicius
next prev parent reply other threads:[~2026-11-05 22:01 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-04 5:10 [PATCH 0/2] iommu/vt-d: Fix SVA teardown races with process exit Lu Baolu
2026-11-04 5:10 ` [PATCH 1/2] iommu/vt-d: Set FPD when tearing down a PASID entry with fault_ignore Lu Baolu
2026-11-05 22:01 ` Vinicius Costa Gomes [this message]
2026-11-09 7:34 ` Baolu Lu
2026-11-12 5:58 ` Tian, Kevin
2026-11-04 5:10 ` [PATCH 2/2] iommu/vt-d: Serialize SVA unbind teardown with intel_mm_release() Lu Baolu
2026-11-12 5:58 ` Tian, Kevin
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=87o6c3uedj.fsf@intel.com \
--to=vinicius.gomes@intel.com \
--cc=baolu.lu@linux.intel.com \
--cc=iommu@lists.linux.dev \
--cc=jgg@ziepe.ca \
--cc=joro@8bytes.org \
--cc=kevin.tian@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=robin.murphy@arm.com \
--cc=stable@vger.kernel.org \
--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.