]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mm/damon/sysfs: use damos_walk() for update_schemes_tried_{bytes,regions}
authorSeongJae Park <sj@kernel.org>
Fri, 3 Jan 2025 17:43:59 +0000 (09:43 -0800)
committerAndrew Morton <akpm@linux-foundation.org>
Sun, 26 Jan 2025 04:22:26 +0000 (20:22 -0800)
commit66178e4ec30a67777f3795dc59a891b106cdb4db
treecd611c56aea19974b76fd28e4bcba8872b600893
parentcce0b334c3108b49b0d550c387cde949b6788f22
mm/damon/sysfs: use damos_walk() for update_schemes_tried_{bytes,regions}

DAMON sysfs interface uses damon_callback with its own complicated
synchronization facility to handle update_schemes_tried_bytes and
update_schemes_tried_regions commands.  But damos_walk() can support the
use case without the additional synchronizations.  Convert the code to use
damos_walk() instead.

Link: https://lkml.kernel.org/r/20250103174400.54890-10-sj@kernel.org
Signed-off-by: SeongJae Park <sj@kernel.org>
Cc: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/damon/sysfs-common.h
mm/damon/sysfs-schemes.c
mm/damon/sysfs.c