[RFC PATCH 0/6] mm/damon: introduce probe_hits_wsum DAMOS core filter
From: SJ Park
Date: Sun Sep 06 2026 - 17:05:51 EST
DAMON can do flexible data attributes monitoring. The classical data
access monitoring can also be done using the attributes monitoring. The
access event is just one of the data attributes that DAMON supports.
Users do monitoring to make some actions based on it. DAMOS is a
feature for automating that. However, DAMOS cannot utilize the data
attributes monitoring results. It is still Data "Access"
Monitoring-based Operation Schemes. It requires users to set the target
"access" pattern.
DAMOS core filter is effectively the same as the target access pattern.
It is just a more generalized and flexible way of describing the
operation action target region. Introduce a new DAMOS core filter type,
probe_hits_wsum. It specifies the filter target based on a range of the
probe hits weighted sum. Using this, users can apply DAMOS actions to
regions of specific data attributes pattern.
Note that the classic target access pattern still works. Hence the
target nr_accesses range should still be properly configured. The new
filter would be used in only data attributes-only mode. In the mode,
classic access monitoring is just turned off, and therefore nr_accesses
of regions are always zero. Users could simply set the target
nr_accesses range to include the zero nr_Accesses regions.
Patches Sequence
================
Patch 1 updates the DAMON kernel API for the new filter type. Patch 2
implements the filter type in the core layer. Patch 3 refactor DAMON
sysfs interface internal data structure for efficient reuse of data
structure for the probe hits weighted sum range user inputs. Patch 4
updates DAMON sysfs interface to support the new filter type. Patches 5
and 6 update design and usage documents for the new filter type,
respectively.
SJ Park (6):
mm/damon/api: introduce DAMOS_FILTER_TYPE_PROBE_HITS_WSUM
mm/damon/core: support probe_hits_wsum damos core filter
mm/damon/sysfs-schemes: rename sysfs_filter->sz_range to
range_{min,max}
mm/damon/sysfs-schemes: setup range_{min,max} for probe_hits_wsum
filter
Docs/mm/damon/design: update for probe_hits_wsum DAMOS core filter
Docs/admin-guide/mm/damon/usage: update for probe_hits_wsum DAMOS
filter
Documentation/admin-guide/mm/damon/usage.rst | 4 +++
Documentation/mm/damon/design.rst | 3 ++
include/linux/damon.h | 8 ++++++
mm/damon/core.c | 12 +++++++-
mm/damon/sysfs-schemes.c | 30 ++++++++++++++------
5 files changed, 48 insertions(+), 9 deletions(-)
base-commit: 787c63ba44ce65021966f55673e27d778c8d9c68
--
2.47.3