From: syzbot <syzbot+2aee6839a252e612ce34@syzkaller.appspotmail.com>
To: ke.zhao.kernel@gmail.com
Cc: ke.zhao.kernel@gmail.com, linux-kernel@vger.kernel.org,
syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] KMSAN: uninit-value in follow_page_pte
Date: Thu, 02 Apr 2026 23:13:47 -0700 [thread overview]
Message-ID: <69cf5a9b.050a0220.182279.000e.GAE@google.com> (raw)
In-Reply-To: <e47cc4ec-8164-40dc-aede-7618181e900f@gmail.com>
> #syz test
This crash does not have a reproducer. I cannot test it.
>
> This is a test patch to fix the KMSAN uninit-value in follow_page_pte.
>
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -5189,6 +5189,10 @@ unsigned long alloc_pages_bulk_noprof(gfp_t gfp,
> int preferred_nid,
>
> prep_new_page(page, 0, gfp, 0);
> set_page_refcounted(page);
> +
> + trace_mm_page_alloc(page, 0, gfp, ac.migratetype);
> + kmsan_alloc_page(page, 0, gfp);
> +
> page_array[nr_populated++] = page;
> }
>
> @@ -6911,6 +6915,12 @@ static void split_free_frozen_pages(struct
> list_head *list, gfp_t gfp_mask)
> int i;
>
> post_alloc_hook(page, order, gfp_mask);
> + /*
> + * Initialize KMSAN state right after
> post_alloc_hook().
> + * This prepares the pages for subsequent outer
> callers
> + * that might free sub-pages after the split.
> + */
> + kmsan_alloc_page(page, order, gfp_mask);
> if (!order)
> continue;
>
> @@ -7117,6 +7127,8 @@ int alloc_contig_frozen_range_noprof(unsigned long
> start, unsigned long end,
>
> check_new_pages(head, order);
> prep_new_page(head, order, gfp_mask, 0);
> +
> + kmsan_alloc_page(head, order, gfp_mask);
> } else {
> ret = -EINVAL;
> WARN(true, "PFN range: requested [%lu, %lu), allocated
> [%lu, %lu)\n",
>
parent reply other threads:[~2026-04-03 6:13 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <e47cc4ec-8164-40dc-aede-7618181e900f@gmail.com>]
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=69cf5a9b.050a0220.182279.000e.GAE@google.com \
--to=syzbot+2aee6839a252e612ce34@syzkaller.appspotmail.com \
--cc=ke.zhao.kernel@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=syzkaller-bugs@googlegroups.com \
/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
all inboxes | Powered by JetHome®