linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Pranjal Shrivastava <praan@google.com>
Cc: Ashish Mhetre <amhetre@nvidia.com>,
	Leon Romanovsky <leon@kernel.org>,
	robin.murphy@arm.com, joro@8bytes.org, will@kernel.org,
	iommu@lists.linux.dev, linux-kernel@vger.kernel.org,
	linux-tegra@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH RFC] iommu/dma: Validate page before accessing P2PDMA state
Date: Fri, 27 Feb 2026 10:13:30 -0400	[thread overview]
Message-ID: <20260227141330.GK5933@nvidia.com> (raw)
In-Reply-To: <aaGlapPSmFJcXsDh@google.com>

On Fri, Feb 27, 2026 at 02:08:42PM +0000, Pranjal Shrivastava wrote:

> The question is, are we sure to use scatterlists to represent non-paged
> memory? 

This is absolutely illegal and a driver bug to put non-struct page
memory into a scatter list. It was never an acceptable "work
around". What driver is doing this??

If you want to improve robustness add some pfn_valid/etc checks under
the CONFING DMA DEBUG and throw warns for these mistakes.

Jason


  reply	other threads:[~2026-02-27 14:13 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20260224104257.1641429-1-amhetre@nvidia.com>
     [not found] ` <20260224123221.GM10607@unreal>
2026-02-24 20:57   ` Pranjal Shrivastava
2026-02-25  4:49     ` Ashish Mhetre
2026-02-25  7:56       ` Leon Romanovsky
2026-02-25 20:11         ` Pranjal Shrivastava
2026-02-26  7:58           ` Leon Romanovsky
2026-02-27  5:46             ` Ashish Mhetre
2026-02-27 14:05               ` Robin Murphy
2026-02-27 14:08               ` Pranjal Shrivastava
2026-02-27 14:13                 ` Jason Gunthorpe [this message]
2026-02-25  7:50     ` Leon Romanovsky
2026-02-25 20:15       ` Pranjal Shrivastava

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=20260227141330.GK5933@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=amhetre@nvidia.com \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=praan@google.com \
    --cc=robin.murphy@arm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox