Re: [PATCH 2/7] mm/damon/core: introduce damon_set_target_pid()

From: SJ Park

Date: Mon Aug 31 2026 - 20:42:18 EST


On Mon, 31 Aug 2026 16:31:19 -0700 Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> wrote:

> On Mon, 31 Aug 2026 07:26:04 -0700 SJ Park <sj@xxxxxxxxxx> wrote:
>
> > The logic that finds the struct pid for a given pid number and assigns
> > it to a damon_target is duplicated in multiple places. Including
> > damon_sysfs_add_target() of mm/damon/sysfs.c and the start functions
> > of the two sample modules, samples/damon/wsse.c and
> > samples/damon/prcl.c. Add a function that does the work, and replace
> > the duplicated code in the places with calls to the function.
> >
> > Signed-off-by: Enze Li <lienze@xxxxxxxxxx>
> > Reviewed-by: SJ Park <sj@xxxxxxxxxx>
> > Signed-off-by: SJ Park <sj@xxxxxxxxxx>
>
> I assumed that From:Enze was intended here.

You're correct Andrew. I found you already fixed this when applying this to
mm-new. Appreciate!


Thanks,
SJ