[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <0deb55a5-8ed9-466d-8dca-1f4229ba9334@lucifer.local>
Date: Mon, 18 Nov 2024 10:32:37 +0000
From: Lorenzo Stoakes <lorenzo.stoakes@...cle.com>
To: Christoph Hellwig <hch@...radead.org>
Cc: Pasha Tatashin <pasha.tatashin@...een.com>, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, linux-doc@...r.kernel.org,
linux-fsdevel@...r.kernel.org, cgroups@...r.kernel.org,
linux-kselftest@...r.kernel.org, akpm@...ux-foundation.org,
corbet@....net, derek.kiernan@....com, dragan.cvetic@....com,
arnd@...db.de, gregkh@...uxfoundation.org, viro@...iv.linux.org.uk,
brauner@...nel.org, jack@...e.cz, tj@...nel.org, hannes@...xchg.org,
mhocko@...nel.org, roman.gushchin@...ux.dev, shakeel.butt@...ux.dev,
muchun.song@...ux.dev, Liam.Howlett@...cle.com, vbabka@...e.cz,
jannh@...gle.com, shuah@...nel.org, vegard.nossum@...cle.com,
vattunuru@...vell.com, schalla@...vell.com, david@...hat.com,
willy@...radead.org, osalvador@...e.de, usama.anjum@...labora.com,
andrii@...nel.org, ryan.roberts@....com, peterx@...hat.com,
oleg@...hat.com, tandersen@...flix.com, rientjes@...gle.com,
gthelen@...gle.com
Subject: Re: [RFCv1 2/6] pagewalk: Add a page table walker for init_mm page
table
On Sun, Nov 17, 2024 at 10:49:06PM -0800, Christoph Hellwig wrote:
> On Sat, Nov 16, 2024 at 05:59:18PM +0000, Pasha Tatashin wrote:
> > } while (start = next, start < end);
> > return err;
> > }
> > +EXPORT_SYMBOL_GPL(walk_page_range);
>
> Umm, no. We really should not expose all these page table detail
> to modules.
>
> > +EXPORT_SYMBOL_GPL(walk_page_range_kernel);
>
> Even more so here.
>
Very much agree. You basically then have the ability for any (GPL) driver to
come in and modify page tables at will which is VERY MUCH not a good idea.
The rules around page table manipulation are very subtle and constantly
changing, this is not something for anything outside of mm to be fiddling with.
Again, I find it bizarre we're exporting mm internal implementation details to a
driver to do stuff with rather than adding functionality to mm.
Powered by blists - more mailing lists