All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sairaj Kodilkar <sarunkod@amd.com>
To: "Joerg Roedel (AMD)" <joro@8bytes.org>,
	Adrian Huang <ahuang12@lenovo.com>,
	Joerg Roedel <jroedel@suse.de>,
	Robin Murphy <robin.murphy@arm.com>,
	Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>,
	Vasant Hegde <vasant.hegde@amd.com>,
	"Will Deacon" <will@kernel.org>, <iommu@lists.linux.dev>
Cc: <Vasant.Hegde@amd.com>, <Suravee.Suthikulpanit@amd.com>,
	Sairaj Kodilkar <sarunkod@amd.com>
Subject: [PATCH v5 0/3] iommu/amd: IVMD handling cleanup and ivmd= boot override
Date: Fri, 27 Nov 2026 15:34:11 +0530	[thread overview]
Message-ID: <20261127100414.6980-1-sarunkod@amd.com> (raw)

This series refreshes how the AMD IOMMU driver models IVRS IVMD entries
after the hardware exclusion range registers were repurposed.

The first patch renames the associated MMIO offsets to reflect completion-wait
store base/limit.

The second patch drops the workaround that forced IVMD exclusion ranges to
r/w unity mappings; the driver no longer programs exclusion range
registers, so that the workaround is obsolete.

The third patch renames the unity-map symbols to ivmd-entry
structures to ivmd_entry. 

Changes from v4:
https://lore.kernel.org/all/20261117070654.3699-1-sarunkod@amd.com/
* Patch 1: Rectify commit message [Vasant]

* Patch 2: Ignore IW,IR and Unity when exclusion range is set. [Vasant]
	   Add comment explaining why exclusion range is marked as reserved. [Vasant]
	   Move unknown flag check to init_unity_map_range(). [Vasant]

* Patch 3: Keep dev_err instead of using pr_err.

Changes from v3:
https://lore.kernel.org/all/20261106041650.24076-1-sarunkod@amd.com/

* Patch 2: rectify the flag checks and move it under init_unity_map_range(). [Akshay]

* Patch 3: Rename ivmd_entry_map to ivmd_entry_to. [Akshay]

Changes from v2:
https://lore.kernel.org/all/20260424092213.16976-1-suravee.suthikulpanit@amd.com/#t

*Patch 2: Report an IVMD exclusion range as IOMMU_RESV_RESERVED in this
	  patch, instead of leaving that for patch 3. This patch stops
	  forcing the exclusion to read/write unity, the range has no read
	  or write permission. iommu_map() rejects that, so a tree checked
	  out at patch 2 does not boot. Reserving the range in the same
	  patch keeps the series bisectable.

* Patch 4: Drop this patch, ivmd= command line does not have any real use and
	   complicates driver.


Change from v1:
(https://lore.kernel.org/linux-iommu/20260420170033.6780-1-suravee.suthikulpanit@amd.com/)

* Rebase on top of patch "[PATCH] iommu/amd: Remove dead code for exclusion ranges in IVMD"
  that was submitted by Yu Zhang <zhangyu1@linux.microsoft.com>.
  (https://lore.kernel.org/all/20260331152550.479841-1-zhangyu1@linux.microsoft.com/)

* Patch 1: Modified to only rename the marco.

* Patch 3: Reintroduce logic to parse IVMD exclusion flag to allow
  reserve region of type IOMMU_RESV_RESERVED.

* Patch 4: 
  - Update the sscan function to scan start, length, flags in hex format only.
  - Fix apply_ivmd_cmdline_entries() to not free the cmd, which points to
    the early_ivmd_cmdline_map[]  on failure path.


Sairaj Kodilkar (1):
  iommu/amd: Rename unity_map symbols to ivmd_entry

Suravee Suthikulpanit (2):
  iommu/amd: Rename exclusion range base and limit macros
  iommu/amd: Do not convert IVMD exclusion range to unity range

 drivers/iommu/amd/amd_iommu_types.h | 28 +++++------
 drivers/iommu/amd/init.c            | 72 +++++++++++++++--------------
 drivers/iommu/amd/iommu.c           | 30 ++++++++++--
 3 files changed, 78 insertions(+), 52 deletions(-)

Base: 4dce97c6c265544342e716e62fd24bbb232590c5
-- 
2.34.1


             reply	other threads:[~2026-11-27 10:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-27 10:04 Sairaj Kodilkar [this message]
2026-11-27 10:04 ` [PATCH v5 1/3] iommu/amd: Rename exclusion range base and limit macros Sairaj Kodilkar
2026-11-27 10:04 ` [PATCH v5 2/3] iommu/amd: Do not convert IVMD exclusion range to unity range Sairaj Kodilkar
2026-12-01  8:50   ` Vasant Hegde
2026-12-01 12:01     ` Sairaj Kodilkar
2026-12-01 12:33       ` Sairaj Kodilkar
2026-11-27 10:04 ` [PATCH v5 3/3] iommu/amd: Rename unity_map symbols to ivmd_entry Sairaj Kodilkar

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=20261127100414.6980-1-sarunkod@amd.com \
    --to=sarunkod@amd.com \
    --cc=ahuang12@lenovo.com \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=jroedel@suse.de \
    --cc=robin.murphy@arm.com \
    --cc=suravee.suthikulpanit@amd.com \
    --cc=vasant.hegde@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.