]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
mm/damon/reclaim: respect addr_unit on default monitoring region setup
authorSeongJae Park <sj@kernel.org>
Wed, 11 Mar 2026 05:29:25 +0000 (22:29 -0700)
committerAndrew Morton <akpm@linux-foundation.org>
Sun, 5 Apr 2026 20:53:29 +0000 (13:53 -0700)
commitfdfcda8d08df9055bc7e081a919ee0463c3a926f
treeae874c96b228fe8a053ee46646217102fb2689bd
parent5f9a5926b75c12ac01b9c2eae98c43939272632b
mm/damon/reclaim: respect addr_unit on default monitoring region setup

In the past, damon_set_region_biggest_system_ram_default(), which is the
core function for setting the default monitoring target region of
DAMON_RECLAIM, didn't support addr_unit.  Hence DAMON_RECLAIM was silently
ignoring the user input for addr_unit when the user doesn't explicitly set
the monitoring target regions, and therefore the default target region is
being used.  No real problem from that ignorance was reported so far.
But, the implicit rule is only making things confusing.  Also, the default
target region setup function is updated to support addr_unit.  Hence there
is no reason to keep ignoring it.  Respect the user-passed addr_unit for
the default target monitoring region use case.

Link: https://lkml.kernel.org/r/20260311052927.93921-5-sj@kernel.org
Signed-off-by: SeongJae Park <sj@kernel.org>
Cc: Yang yingliang <yangyingliang@huawei.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/damon/reclaim.c