[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7b6b6430-0237-4512-b99b-9eb815b3dc68@intel.com>
Date: Thu, 23 May 2024 20:30:19 -0700
From: Dave Hansen <dave.hansen@...el.com>
To: Peter Xu <peterx@...hat.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
Thomas Gleixner <tglx@...utronix.de>, Jason Gunthorpe <jgg@...dia.com>,
Andrew Morton <akpm@...ux-foundation.org>, Al Viro
<viro@...iv.linux.org.uk>, Dave Hansen <dave.hansen@...ux.intel.com>,
Andy Lutomirski <luto@...nel.org>, Matthew Wilcox <willy@...radead.org>,
Dan Williams <dan.j.williams@...el.com>,
"Kirill A . Shutemov" <kirill@...temov.name>, Mike Rapoport
<rppt@...nel.org>, Ingo Molnar <mingo@...hat.com>,
Michal Hocko <mhocko@...e.com>, Alex Williamson
<alex.williamson@...hat.com>, Peter Zijlstra <peterz@...radead.org>,
Suren Baghdasaryan <surenb@...gle.com>, Borislav Petkov <bp@...en8.de>,
x86@...nel.org
Subject: Re: [PATCH RFC 2/2] mm/x86/pat: Do proper PAT bit shift for large
mappings
On 5/23/24 16:07, Peter Xu wrote:
> Probably not.. I think I can define a pgprot_to_large() globally, pointing
> that to pgprot_4k_2_large() on x86 and make the fallback to be noop. And
> if there's a new version I'll guarantee to run over my cross compilers.
I guess that would be functional, but it would be a bit mean to
everybody else.
> Any comments on the idea itself? Do we have a problem, or maybe I
> overlooked something?
I think it's probably unnecessary to inflict this particular x86-ism on
generic code. The arch-generic 'prot' should have PAT at its 4k
(_PAGE_BIT_PAT) position and then p*d_mkhuge() can shift it into the
_PAGE_BIT_PAT_LARGE spot.
Powered by blists - more mailing lists