mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rik van Riel <riel@surriel.com>
To: Lorenzo Stoakes <ljs@kernel.org>
Cc: linux-kernel@vger.kernel.org, kernel-team@meta.com,
	linux-mm@kvack.org,  akpm@linux-foundation.org, david@kernel.org,
	ziy@nvidia.com,  baolin.wang@linux.alibaba.com,
	liam@infradead.org, npache@redhat.com,  ryan.roberts@arm.com,
	dev.jain@arm.com, baohua@kernel.org, lance.yang@linux.dev,
		yang@os.amperecomputing.com
Subject: Re: [PATCH] mm/huge_memory: set PG_has_hwpoisoned only after new folio head is established
Date: Wed, 01 Jul 2026 12:29:25 -0400	[thread overview]
Message-ID: <c1bac3b7b4a4cc3f7a3a04269307aeb13dbbf963.camel@surriel.com> (raw)
In-Reply-To: <akUoqvmGtSMgD0QT@lucifer>

On Wed, 2026-07-01 at 15:52 +0100, Lorenzo Stoakes wrote:
> On Wed, Jul 01, 2026 at 09:46:22AM -0400, Rik van Riel wrote:
> > 
> > @@ -3612,6 +3608,18 @@ static void __split_folio_to_order(struct
> > folio *folio, int old_order,
> >  			folio_set_large_rmappable(new_folio);
> >  		}
> > 
> > +		/*
> > +		 * PG_has_hwpoisoned is a FOLIO_SECOND_PAGE flag,
> > so it can only
> > +		 * be set once @new_folio is a real (head) folio. 
> > Defer setting
> > +		 * it until after
> > clear_compound_head()/prep_compound_page() have
> > +		 * turned @new_head from a tail page into a proper
> > folio head;
> > +		 * otherwise folio_flags() trips on (page-
> > >compound_info & 1).
> > +		 * handle_hwpoison implies new_order != 0.
> > +		 */
> 
> This reads like an LLM comment...! A ton of noise and unnecessary
> detail.
> 
> How about:
> 
> 		/*
> 		 * PG_has_hwpoisoned is on the 2nd page, so set it
> after
> 		 * compound head prepped.
> 		 */

It was an LLM comment, indeed. I harvest these
syzkaller fixes from an automated run every
once in a while, where the fix is "verified"
by checking whether the issue can still reproduce
after a tentative fix has been applied.

I've fixed up the comment as suggested, and
will CC: stable@kernel.org on v2.

thank you for the review,

Rik
-- 
All Rights Reversed.

  reply	other threads:[~2026-07-01 16:29 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-01 13:46 Rik van Riel
2026-07-01 14:34 ` Zi Yan
2026-07-01 14:52 ` Lorenzo Stoakes
2026-07-01 16:29   ` Rik van Riel [this message]
2026-07-01 15:24 ` Lance Yang
2026-07-01 16:33 ` David Hildenbrand (Arm)
2026-07-01 17:24   ` Rik van Riel
2026-07-02  2:29     ` Lance Yang

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=c1bac3b7b4a4cc3f7a3a04269307aeb13dbbf963.camel@surriel.com \
    --to=riel@surriel.com \
    --cc=akpm@linux-foundation.org \
    --cc=baohua@kernel.org \
    --cc=baolin.wang@linux.alibaba.com \
    --cc=david@kernel.org \
    --cc=dev.jain@arm.com \
    --cc=kernel-team@meta.com \
    --cc=lance.yang@linux.dev \
    --cc=liam@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=ljs@kernel.org \
    --cc=npache@redhat.com \
    --cc=ryan.roberts@arm.com \
    --cc=yang@os.amperecomputing.com \
    --cc=ziy@nvidia.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®