Re: [PATCH] selftests/damon: stop kdamond on error exits of no-op commit test
From: SJ Park
Date: Mon Sep 07 2026 - 12:49:21 EST
On Mon, 7 Sep 2026 20:34:55 +0800 Zenghui Yu <zenghui.yu@xxxxxxxxx> wrote:
> From: "Zenghui Yu (Huawei)" <zenghui.yu@xxxxxxxxx>
>
> The sysfs_no_op_commit_break test starts a kdamond via sysfs, but its error
> paths (e.g., drgn not installed) exit without stopping it. The leaked
> kdamond then makes subsequent tests, e.g. lru_sort.sh and reclaim.sh, skip
> with "Another kdamond is running".
>
> Wrap the post-start logic in try-finally so that kdamonds.stop() is
> executed on every exit path.
Looks good to me, thank you for fixing this, Zenghui.
>
> Fixes: 10725cd2b09a ("selftests/damon: test no-op commit broke DAMON status")
> Assisted-by: GLM-5.3 OpenCode
> Signed-off-by: Zenghui Yu (Huawei) <zenghui.yu@xxxxxxxxx>
Reviewed-by: SJ Park <sj@xxxxxxxxxx>
This patch is applied to damon/next [1] 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://origin.kernel.org/doc/html/latest/mm/damon/maintainer-profile.html#scm-trees
Thanks,
SJ
[...]