From: Uladzislau Rezki <urezki@gmail.com>
To: Brendan Jackman <jackmanb@google.com>
Cc: Anshuman Khandual <anshuman.khandual@arm.com>,
Andrew Morton <akpm@linux-foundation.org>,
Uladzislau Rezki <urezki@gmail.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm/vmalloc: clarify why vmap_range_noflush() might sleep
Date: Mon, 8 Dec 2025 18:32:24 +0100 [thread overview]
Message-ID: <aTcLqNyqm_WIyn99@milan> (raw)
In-Reply-To: <DESNXS1K25LW.2E7ZWFWV56PZD@google.com>
On Mon, Dec 08, 2025 at 07:39:39AM +0000, Brendan Jackman wrote:
> Hi Anshuman, thanks a lot for taking a look.
>
> On Mon Dec 8, 2025 at 6:41 AM UTC, Anshuman Khandual wrote:
> > Please add <asm-generic/pgalloc.h> in mm/vmalloc.c - otherwise it does not
> > get built as GFP_PGTABLE_KERNEL is not available. But otherwise LGTM.
>
> Oh, but that's not correct, IIUC we shouldn't directly be including
> asm-generic headers from here.
>
> So while in principle GFP_PGTABLE_KERNEL is a sensible common
> demoninator here, it doesn't actually exist at all everywhere, e.g. it
> doesn't look like m68k defines it for Motorola.
>
> So maybe the best way here is a really vague:
>
> /*
> * Different archs allocate pagetables in different ways, assume
> * GFP_KERNEL as a common denominator.
> */
> might_alloc(GFP_KERNEL)
>
> ... a bit yucky but I think still useful.
>
> Any thoughts?
>
Maybe just add a comment why that might_sleep() is there?
We can simply state that page table allocation path is hard-coded
internally to use GFP_KERNEL flag.
Thanks!
--
Uladzislau Rezki
next prev parent reply other threads:[~2025-12-08 17:32 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-08 5:19 Brendan Jackman
2025-12-08 6:41 ` Anshuman Khandual
2025-12-08 7:39 ` Brendan Jackman
2025-12-08 17:32 ` Uladzislau Rezki [this message]
2025-12-08 8:51 ` [syzbot ci] " syzbot ci
2025-12-09 2:56 ` Brendan Jackman
2025-12-09 1:10 ` [PATCH] " kernel test robot
2025-12-09 1:52 ` kernel test robot
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=aTcLqNyqm_WIyn99@milan \
--to=urezki@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=anshuman.khandual@arm.com \
--cc=jackmanb@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.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