Re: [PATCH v2] selftests/damon/sysfs.py: clean up sh processes used for obsolete_target test
From: SJ Park
Date: Tue Jul 21 2026 - 23:38:56 EST
Hello Hari,
>From the next time, please don't post a new version of a patch as a reply to
the previous version. Post a new version as a new thread, with changelogs [1]
including links to previous revisions.
Also, give others sufficient time, say, one day, to add comments before posting
a new version. If someone publicly asked questions to your patch, please
answer the questions and keep the discussion in public until the discussion is
clearly completed, before posting a new version.
On Wed, 22 Jul 2026 03:23:49 +0200 Hari Mishal <harimishal1@xxxxxxxxx> wrote:
> The obsolete_target test spawns three sh processes and uses their pids
> as DAMON monitoring targets. These processes are never terminated or
> waited on, so they are left running (or become zombies) as orphaned
> children after the test program exits.
>
> Terminate each process and communicate() with it after the targets are
> no longer needed, so it exits and gets reaped instead of being leaked.
Makes sense to me. Thank you for this patch.
>
> Signed-off-by: Hari Mishal <harimishal1@xxxxxxxxx>
Reviewed-by: SJ Park <sj@xxxxxxxxxx>
> ---
> v2: Terminate each sh process directly instead of giving it its own
> stdin pipe to close, dropping the stdin=PIPE changes and shrinking
> the diff.
When you add changelog, please add links to the previous revisions.
Finally, please use mm-new [2] as the baseline of DAMON patches from the next
time.
This patch is applied to damon/next [2] tree. If this patch is not added to
mm.git in short term (~1 week?), I will ask mm.git maintainer (Andrew Morton)
to pick this. So, no action from your side is needed for now. If it seems I
also forgot doing that or you cannot wait for my action, please feel free to
directly ask that to Andrew.
[1] https://docs.kernel.org/process/submitting-patches.html#commentary
[2] https://origin.kernel.org/doc/html/latest/mm/damon/maintainer-profile.html#scm-trees
Thanks,
SJ
[...]