[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <722af60d-efde-48f7-b521-657c25f68195@nvidia.com>
Date: Fri, 14 Jun 2024 19:12:36 -0700
From: John Hubbard <jhubbard@...dia.com>
To: "Jason A. Donenfeld" <Jason@...c4.com>, <linux-kernel@...r.kernel.org>,
<patches@...ts.linux.dev>, <tglx@...utronix.de>
CC: <linux-crypto@...r.kernel.org>, <linux-api@...r.kernel.org>,
<x86@...nel.org>, Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Adhemerval Zanella Netto" <adhemerval.zanella@...aro.org>, Carlos O'Donell
<carlos@...hat.com>, Florian Weimer <fweimer@...hat.com>, Arnd Bergmann
<arnd@...db.de>, Jann Horn <jannh@...gle.com>, Christian Brauner
<brauner@...nel.org>, David Hildenbrand <dhildenb@...hat.com>,
<linux-mm@...ck.org>
Subject: Re: [PATCH v17 1/5] mm: add VM_DROPPABLE for designating always
lazily freeable mappings
On 6/14/24 12:06 PM, Jason A. Donenfeld wrote:
...
> diff --git a/mm/Kconfig b/mm/Kconfig
> index b4cb45255a54..6cd65ea4b3ad 100644
> --- a/mm/Kconfig
> +++ b/mm/Kconfig
> @@ -1056,6 +1056,9 @@ config ARCH_USES_HIGH_VMA_FLAGS
> bool
> config ARCH_HAS_PKEYS
> bool
> +config NEED_VM_DROPPABLE
> + select ARCH_USES_HIGH_VMA_FLAGS
Hi Jason!
The naming and use of NEED_VM_DROPPABLE are a little bit backwards. :)
First of all, the name should probably be:
HAVE_VM_DROPPABLE
...although that doesn't yet work here. And the reason it doesn't work
yet is that the logic also needs to change: only the arch layers should
be doing this:
select ARCH_USES_HIGH_VMA_FLAGS
If a feature does it, then the logic and dependency tree gets all weird
and wrong.
So:
a) 64-bit arches should do this part:
select ARCH_USES_HIGH_VMA_FLAGS (already done, in most cases) select
HAVE_VM_DROPPABLE
b) VDSO_GETRANDOM should depend on:
HAVE_VM_DROPPABLE
...and then you'll find that the uses of HAVE_VM_DROPPABLE read more
like the pre-existing cases of other "HAVE_" items, too.
thanks,
--
John Hubbard
NVIDIA
Powered by blists - more mailing lists