[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAFgf54pBAUm3ao-UJksiuGKtvv4wzRyFq_uKwLe0H1ettO4DLQ@mail.gmail.com>
Date: Wed, 14 Jan 2026 17:41:55 +0000
From: Mostafa Saleh <smostafa@...gle.com>
To: "David Hildenbrand (Red Hat)" <david@...nel.org>
Cc: Jason Gunthorpe <jgg@...pe.ca>, linux-mm@...ck.org, iommu@...ts.linux.dev,
linux-kernel@...r.kernel.org, linux-doc@...r.kernel.org, corbet@....net,
joro@...tes.org, will@...nel.org, robin.murphy@....com,
akpm@...ux-foundation.org, vbabka@...e.cz, surenb@...gle.com, mhocko@...e.com,
jackmanb@...gle.com, hannes@...xchg.org, ziy@...dia.com,
lorenzo.stoakes@...cle.com, Liam.Howlett@...cle.com, rppt@...nel.org,
xiaqinxin@...wei.com, baolu.lu@...ux.intel.com, rdunlap@...radead.org,
Samiullah Khawaja <skhawaja@...gle.com>
Subject: Re: [PATCH v6 3/4] iommu: debug-pagealloc: Track IOMMU pages
On Wed, Jan 14, 2026 at 5:30 PM David Hildenbrand (Red Hat)
<david@...nel.org> wrote:
>
> On 1/13/26 16:08, Jason Gunthorpe wrote:
> > On Tue, Jan 13, 2026 at 10:49:28AM +0000, Mostafa Saleh wrote:
> >> Would you have a problem if we added a new function in page_ext
> >> "page_ext_from_phys()" as Jason suggested?
> >
> > Given the hidden complexity that David just pointed out I think this
> > is essential to encapsulate it in a function.
> >
> > The function must be able to accept any phys_addr_t and safely returns
> > NULL if page_ext cannot be used for some reason.
>
> Right. I think pfn_to_online_page() is the appropriate check.
>
> @Mostafa, I saw you already sent a v7, is the pfn_to_online_page() stuff
> handled in there?
>
Yes, it's in the first patch in function page_ext_get_phys(). After
spending some time looking into it, that was my conclusion also.
Thanks,
Mostafa
> --
> Cheers
>
> David
Powered by blists - more mailing lists