Re: [RESEND RFC PATCH v2 0/5] mm/damon: add mTHP collapse and split actions

From: SJ Park

Date: Fri Jul 03 2026 - 12:39:22 EST


On Fri, 3 Jul 2026 09:10:51 +0800 wang lian <lianux.mm@xxxxxxxxx> wrote:

> Hi,Lorenzo
>
> > On Jul 2, 2026, at 18:23, Lorenzo Stoakes <ljs@xxxxxxxxxx> wrote:
> >
> > +cc all those you missed.
> >
> > I really need to write a bot to do this, because I'm getting a little tired of
> > pointing this out :))
> >
> > On Thu, Jul 02, 2026 at 05:46:28PM +0800, Lian Wang wrote:
> >> include/linux/damon.h | 10 +++
> >> include/linux/khugepaged.h | 9 +++
> >> mm/damon/core.c | 2 +
> >> mm/damon/sysfs-schemes.c | 77 ++++++++++++++++++++++
> >> mm/damon/vaddr.c | 128 +++++++++++++++++++++++++++++++++++++
> >> mm/khugepaged.c | 46 +++++++++++++
> >> 6 files changed, 272 insertions(+)
> >
> > You are doing damon changes, and that belongs to SJ, sure.
> >
> > But you're also changing core THP code? Please ensure you cc- THP people because
> > without our approval this cannot be merged:
> >
> > $ scripts/get_maintainer.pl 20260702094633.75658-1-lianux.mm@xxxxxxxxxxxxx <mailto:20260702094633.75658-1-lianux.mm@xxxxxxxxxxxxx>
> > SJ Park <sj@xxxxxxxxxx <mailto:sj@xxxxxxxxxx>> (maintainer:DAMON)
> > Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx <mailto:akpm@xxxxxxxxxxxxxxxxxxxx>> (maintainer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > David Hildenbrand <david@xxxxxxxxxx <mailto:david@xxxxxxxxxx>> (maintainer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Lorenzo Stoakes <ljs@xxxxxxxxxx <mailto:ljs@xxxxxxxxxx>> (maintainer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Zi Yan <ziy@xxxxxxxxxx <mailto:ziy@xxxxxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Baolin Wang <baolin.wang@xxxxxxxxxxxxxxxxx <mailto:baolin.wang@xxxxxxxxxxxxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > "Liam R. Howlett" <liam@xxxxxxxxxxxxx <mailto:liam@xxxxxxxxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Nico Pache <npache@xxxxxxxxxx <mailto:npache@xxxxxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Ryan Roberts <ryan.roberts@xxxxxxx <mailto:ryan.roberts@xxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Dev Jain <dev.jain@xxxxxxx <mailto:dev.jain@xxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Barry Song <baohua@xxxxxxxxxx <mailto:baohua@xxxxxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > Lance Yang <lance.yang@xxxxxxxxx <mailto:lance.yang@xxxxxxxxx>> (reviewer:MEMORY MANAGEMENT - THP (TRANSPARENT HUGE PAGE))
> > damon@xxxxxxxxxxxxxxx <mailto:damon@xxxxxxxxxxxxxxx> (open list:DAMON)
> > linux-mm@xxxxxxxxx <mailto:linux-mm@xxxxxxxxx> (open list:DAMON)
> > linux-kernel@xxxxxxxxxxxxxxx <mailto:linux-kernel@xxxxxxxxxxxxxxx> (open list)
> >
> >>
> >> --
> >> 2.50.1 (Apple Git-155)
> >>
> >
>
> Thank you for pointing this out again, and I deeply appreciate all the tedious
> work you do as a maintainer to keep the mailing lists aligned.
>
> As a newcomer trying to transition into complex feature development, I must
> admit my initial design is far from perfect. I leveraged AI tools to assist
> with certain implementation paths, and although I extensively self-reviewed,
> tested, and reasoned through every single line of code, your and SJ's
> feedback clearly shows there are still major architectural flaws. Just like my
> very first kernel patch—which was strictly reviewed and guided by you and David H.
> —I know that your sharp feedback is exactly what will help me grow as a kernel engineer.
>
> I will completely step back and radically rethink the design of this series,
> especially regarding the cross-subsystem encapsulation and locking hazards.

No worries, take your time :)

>
> As for that bot you mentioned getting tired of running manually—let me write
> it for you. An imperfect newcomer who just made these exact mistakes knows
> precisely where the traps are. I can craft a pre-flight patch check script or
> a CI bot that automatically validates the `get_maintainer.pl` output against
> the patch file diffstat before any email is dispatched, throwing a loud warning
> if core MM files are touched but their respective maintainers are missing from
> the CC line.
>
> What do you think? I would love to build this tool to save your and other
> maintainers' valuable time in the future.

Sounds great! hkml already has all building blocks for doing the check, so I'm
planning to develop such checks in hkml, but only for manual runs. I ain't
develop and run a bot, since I don't have that much compute resource. Maybe
you could save your time by reusing the hkml feature on your bot.


Thanks,
SJ

[...]