Re: [syzbot] [mm?] WARNING in alloc_frozen_pages_noprof
From: Dominique Martinet
Date: Wed Aug 13 2025 - 00:51:25 EST
Harry Yoo wrote on Wed, Aug 13, 2025 at 09:31:34AM +0900:
> The warning is:
>
> /*
> * There are several places where we assume that the order value is sane
> * so bail out early if the request is out of bound.
> */
> if (WARN_ON_ONCE_GFP(order > MAX_PAGE_ORDER, gfp))
> return NULL;
>
> There's not much the buddy allocator can do when a user requests
> order > MAX_PAGE_ORDER allocations.
>
> > alloc_pages_mpol+0x1e4/0x460 mm/mempolicy.c:2416
> > alloc_frozen_pages_noprof+0xe0/0x210 mm/mempolicy.c:2487
> > ___kmalloc_large_node+0xac/0x154 mm/slub.c:4306
> > __kmalloc_large_node_noprof+0x2c/0x8c mm/slub.c:4337
> > __do_kmalloc_node mm/slub.c:4353 [inline]
> > __kmalloc_noprof+0x3bc/0x4c8 mm/slub.c:4377
> > kmalloc_noprof include/linux/slab.h:909 [inline]
> > kzalloc_noprof include/linux/slab.h:1039 [inline]
> > v9fs_fid_get_acl+0x64/0x114 fs/9p/acl.c:32
>
> So... 9p FS shouldn't really request that?
>
> Cc'ing 9p FS folks.
Thanks for the Cc.
So, this comes up once in a while, everytime we discuss limiting the
xattr size, then someone says we should do something else or I'm using
the wrong define or I don't remember and then when I ask what we should
do never reply again.
See [1] or [2] for the last two time this happened.
[1] https://lore.kernel.org/all/20240304-xattr_maxsize-v1-1-322357ec6bdf@xxxxxxxxxxxxx/T/#u
[2] https://lore.kernel.org/lkml/20240202121319.21743-1-pchelkin@xxxxxxxxx/
I'll be happy to take any patch you send (or one of the older patches if
you tell me which is "correct"), I don't care anymore.
--
Dominique