intel-xe.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Baolu Lu <baolu.lu@linux.intel.com>
To: Jason Gunthorpe <jgg@nvidia.com>, "Tian, Kevin" <kevin.tian@intel.com>
Cc: "Borah, Chaitanya Kumar" <chaitanya.kumar.borah@intel.com>,
	"intel-gfx@lists.freedesktop.org"
	<intel-gfx@lists.freedesktop.org>,
	"intel-xe@lists.freedesktop.org" <intel-xe@lists.freedesktop.org>,
	"De Marchi, Lucas" <lucas.demarchi@intel.com>,
	"Kurmi, Suresh Kumar" <suresh.kumar.kurmi@intel.com>,
	"Saarinen, Jani" <jani.saarinen@intel.com>,
	"Auld, Matthew" <matthew.auld@intel.com>,
	"iommu@lists.linux.dev" <iommu@lists.linux.dev>
Subject: Re: REGRESSION on linux-next (next-20251106)
Date: Thu, 20 Nov 2025 15:27:58 +0800	[thread overview]
Message-ID: <94ae0210-734b-41cb-b8a8-657b76324aba@linux.intel.com> (raw)
In-Reply-To: <20251120021831.GT120075@nvidia.com>

On 11/20/25 10:18, Jason Gunthorpe wrote:
> On Wed, Nov 19, 2025 at 11:56:16PM +0000, Tian, Kevin wrote:
>>> So we should be using dmar->width to constrain the first stage and
>>> expect that mgaw is less than dmar->width ?
>>>
>> dmar->width is the host address width, i.e. for OA. so it's irrelevant
>> to the input iova here.
> Oh that makes sense!
> 
> In that case we should probably pedantically have:
> 
> 	cfg.common.hw_max_oasz_lg2 = dmar->width;
> 
> ?
> 
> However we get dmar into that function?
> 
>> "
>> 3.6 First-Stage Translation
>>
>> First-stage translation restricts the input-address to a canonical address
>> (i.e., address bits 63:N have the same value as address bit [N-1], where
>> N is 48 bits with 4-level paging and 57 bits with 5-level paging). Requests
>> subject to first-stage translation by remapping hardware are subject to
>> canonical address checking as a pre-condition for first-stage translation,
>> and a violation is treated as a translation-fault.
>>
>> Software using first-stage translation structures to translate an IO Virtual
>> Address (IOVA) must use canonical addresses. Additionally, software
>> must limit addresses to less than the minimum of MGAW and the lower
>> canonical address width implied by FSPM (i.e., 47-bit when FSPM is 4-level
>> and 56-bit when FSPM is 5-level)
>> "
> That seems very clear, indeed. OK! Easy to fix then! Balou can you
> take it? I think something like this?

A fix patch was posted here:

https://lore.kernel.org/linux-iommu/20251120072524.3218282-1-baolu.lu@linux.intel.com/

Thanks,
baolu

  parent reply	other threads:[~2025-11-20  7:32 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-10  6:36 REGRESSION on linux-next (next-20251106) Borah, Chaitanya Kumar
2025-11-12 22:32 ` Jason Gunthorpe
2025-11-13  2:00   ` Tian, Kevin
2025-11-17 15:24     ` Jason Gunthorpe
2025-11-17 12:54   ` Baolu Lu
2025-11-17 15:22     ` Jason Gunthorpe
2025-11-18  1:29 ` Jason Gunthorpe
2025-11-18  4:04   ` Tian, Kevin
2025-11-18  6:19     ` Baolu Lu
2025-11-18  6:23     ` Baolu Lu
2025-11-18  7:47       ` Tian, Kevin
2025-11-18 11:29         ` Baolu Lu
2025-11-18 12:35           ` Jason Gunthorpe
2025-11-19  7:25             ` Baolu Lu
2025-11-18 10:30   ` Baolu Lu
2025-11-18 15:16   ` Borah, Chaitanya Kumar
2025-11-18 16:13     ` Jason Gunthorpe
2025-11-19  9:29       ` Baolu Lu
     [not found]       ` <0c3cd494-e42a-4607-896c-4c341f90c270@intel.com>
2025-11-19  9:31         ` Tian, Kevin
2025-11-19 18:51           ` Jason Gunthorpe
2025-11-19 23:56             ` Tian, Kevin
2025-11-20  2:18               ` Jason Gunthorpe
2025-11-20  2:24                 ` Baolu Lu
2025-11-20  7:27                 ` Baolu Lu [this message]
2025-11-20  0:19             ` 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=94ae0210-734b-41cb-b8a8-657b76324aba@linux.intel.com \
    --to=baolu.lu@linux.intel.com \
    --cc=chaitanya.kumar.borah@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=iommu@lists.linux.dev \
    --cc=jani.saarinen@intel.com \
    --cc=jgg@nvidia.com \
    --cc=kevin.tian@intel.com \
    --cc=lucas.demarchi@intel.com \
    --cc=matthew.auld@intel.com \
    --cc=suresh.kumar.kurmi@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).