diff options
| author | SJ Park <sj@kernel.org> | 2026-06-28 15:01:17 -0700 |
|---|---|---|
| committer | Andrew Morton <akpm@linux-foundation.org> | 2026-07-28 21:12:08 -0700 |
| commit | c37dfd69829702785963314fb8c4e644a908aa7d (patch) | |
| tree | a789be572476d85b90ea243781fd2bff32adc79f | |
| parent | 286380c78bc51e6c578621b9ae660bf9e5ad2563 (diff) | |
| download | linux-next-c37dfd69829702785963314fb8c4e644a908aa7d.tar.gz linux-next-c37dfd69829702785963314fb8c4e644a908aa7d.zip | |
mm/damon/sysfs: kobject_del() probe dirs
On CONFIG_DEBUG_KOBJECT_RELEASE enabled kernel, lack of kobject_del()
could cause directories creation failures due to the name conflicts. Fix
those issues for data attribute probe directories by adding kobject_del()
calls.
Link: https://lore.kernel.org/20260628220121.97360-9-sj@kernel.org
Fixes: bf3ea3d30880 ("mm/damon/sysfs: implement probe dir")
Signed-off-by: SJ Park <sj@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
| -rw-r--r-- | mm/damon/sysfs.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/mm/damon/sysfs.c b/mm/damon/sysfs.c index 204aed6a3e5d..9f92ebdb2857 100644 --- a/mm/damon/sysfs.c +++ b/mm/damon/sysfs.c @@ -1137,6 +1137,7 @@ static void damon_sysfs_probes_rm_dirs( for (i = 0; i < probes->nr; i++) { damon_sysfs_probe_rm_dirs(probes_arr[i]); + kobject_del(&probes_arr[i]->kobj); kobject_put(&probes_arr[i]->kobj); } probes->nr = 0; |
