From: SJ Park <sj@kernel.org>
Cc: SJ Park <sj@kernel.org>, "Liam R. Howlett" <liam@infradead.org>,
Andrew Morton <akpm@linux-foundation.org>,
David Hildenbrand <david@kernel.org>,
Jonathan Corbet <corbet@lwn.net>,
Lorenzo Stoakes <ljs@kernel.org>, Michal Hocko <mhocko@suse.com>,
Mike Rapoport <rppt@kernel.org>, Shuah Khan <shuah@kernel.org>,
Shuah Khan <skhan@linuxfoundation.org>,
Suren Baghdasaryan <surenb@google.com>,
Vlastimil Babka <vbabka@kernel.org>,
damon@lists.linux.dev, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org,
linux-mm@kvack.org
Subject: [RFC PATCH 00/17] mm/damon: introduce data access-as-a-data attribute
Date: Sat, 25 Jul 2026 14:02:04 -0700 [thread overview]
Message-ID: <20260725210225.129944-1-sj@kernel.org> (raw)
TL;DR: extend DAMON's data attributes monitoring system to support page
table accessed bit and PG_idle based access monitoring.
DAMON was initially introduced as a data access monitor. Users found
data access pattern becomes more useful when it is combined with other
data attributes such as belonging cgroups and backing page types. For
such cases, DAMON has extended to support such data attributes
monitoring in addition to the original data access monitoring. The
DAMON probes system was introduced for this purpose. Users set probes
for filtering data attributes of their interest. For use cases where
the primary interests are the attributes but the access pattern, probe
weights system has been introduced. When it is used, DAMON applies its
adaptive regions adjustment based on the monitored data attributes.
However, DAMON stops access monitoring when the probe weights are used.
DAMON cannot optimally help users who have interests in both data
attributes and access patterns. Data access can also be thought of as
another data attribute, though. Extend the probe system to support data
access as a data attribute.
Introduce a new probe filter type, pgidle_unset. It shows if the page
is not set as idle. Specifically, it shows the page table accessed bit
and the PG_idle flag. It can inform if the region is ever accessed. But
it cannot say when it is accessed. To answer the second question,
introduce a new probe feature, prep actions. Using the features, Users
can specify what preparation actions should be made to each region for
each probe. DAMON executes the preparation actions for each sampling
interval, like it is doing the preparation for access check in the
access monitoring mode. To help 'pgidle_unset' probe action use case,
'set_pgidle' preparation action is introduced together. The action does
exactly what the access monitoring was doing: clearing the page table
accessed bits and setting the PG_idle flags.
Patches Sequence
================
First four patches (patches 1-4) introduce the new probe filter type for
knowing if a region is accessed. Patch 1 defines the new type in the
core. Patch 2 implements the execution of the new filter in the
physical address space DAMON operation set. Patch 3 implements a user
interface on DAMON sysfs interface. Patch 4 updates the documentation
for the new filter type.
Following 13 patches (patches 5-17) introduce the probe preparation
actions feature. Patch 5 defines the data structure for specifying the
preparation actions. Patch 6 completes setup of the API parameter for
the prep. Patch 7 extends the DAMON operation set callback list to
connect the parameter with the underlying operation set. Patch 8
implements the execution of the prep in the physical address space DAMON
operation set.
Following five patches (patches 9-13) extends DAMON sysfs interface for
the new prep feature. Patch 14 adds simple selftest for basic file
operations of the new sysfs files. Final three patches (patches 15-17)
respectively update design, usage and ABI documents for the new feature
and its interface.
SJ Park (17):
mm/damon/core: introduce DAMON_FILTER_TYPE_PGIDLE_UNSET
mm/damon/paddr: support PGIDLE_UNSET probe filter type
mm/damon/sysfs: support pgidle_unset probe filter type
Docs/mm/damon/design: document pgidle_unset probe filter type
mm/damon/core: introduce damon_prep struct
mm/damon/core: commit preps
mm/damon/core: introduce damon_operations->prep_probes()
mm/damon/paddr: support damon_prep
mm/damon/sysfs: implement preps directory
mm/damon/sysfs: create probe preps directory
mm/damon/sysfs: implement probe prep directory
mm/damon/sysfs: create probe prep files for preps/nr file write
mm/damon/sysfs: pass preps to DAMON core
selftests/damon/sysfs.sh: test probe prep sysfs files
Docs/mm/damon/design: document probe preps
Docs/admin-guide/mm/damon/usage: document probe preps sysfs files
Docs/ABI/damon: document probe prep sysfs files
.../ABI/testing/sysfs-kernel-mm-damon | 13 +
Documentation/admin-guide/mm/damon/usage.rst | 18 +-
Documentation/mm/damon/design.rst | 17 +-
include/linux/damon.h | 42 ++-
mm/damon/core.c | 103 ++++++-
mm/damon/paddr.c | 41 +++
mm/damon/sysfs.c | 280 +++++++++++++++++-
tools/testing/selftests/damon/sysfs.sh | 27 ++
8 files changed, 527 insertions(+), 14 deletions(-)
base-commit: 7c69a13f116ab63f525a2c4b0be7ce89f73befcd
--
2.47.3
next reply other threads:[~2026-07-25 21:02 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-25 21:02 SJ Park [this message]
2026-07-25 21:02 ` [RFC PATCH 01/17] mm/damon/core: introduce DAMON_FILTER_TYPE_PGIDLE_UNSET SJ Park
2026-07-25 21:02 ` [RFC PATCH 02/17] mm/damon/paddr: support PGIDLE_UNSET probe filter type SJ Park
2026-07-25 21:02 ` [RFC PATCH 03/17] mm/damon/sysfs: support pgidle_unset " SJ Park
2026-07-25 21:02 ` [RFC PATCH 04/17] Docs/mm/damon/design: document " SJ Park
2026-07-25 21:02 ` [RFC PATCH 05/17] mm/damon/core: introduce damon_prep struct SJ Park
2026-07-25 21:02 ` [RFC PATCH 06/17] mm/damon/core: commit preps SJ Park
2026-07-25 21:02 ` [RFC PATCH 07/17] mm/damon/core: introduce damon_operations->prep_probes() SJ Park
2026-07-25 21:02 ` [RFC PATCH 08/17] mm/damon/paddr: support damon_prep SJ Park
2026-07-25 21:02 ` [RFC PATCH 09/17] mm/damon/sysfs: implement preps directory SJ Park
2026-07-25 21:02 ` [RFC PATCH 10/17] mm/damon/sysfs: create probe " SJ Park
2026-07-25 21:02 ` [RFC PATCH 11/17] mm/damon/sysfs: implement probe prep directory SJ Park
2026-07-25 21:02 ` [RFC PATCH 12/17] mm/damon/sysfs: create probe prep files for preps/nr file write SJ Park
2026-07-25 21:02 ` [RFC PATCH 13/17] mm/damon/sysfs: pass preps to DAMON core SJ Park
2026-07-25 21:02 ` [RFC PATCH 14/17] selftests/damon/sysfs.sh: test probe prep sysfs files SJ Park
2026-07-25 21:02 ` [RFC PATCH 15/17] Docs/mm/damon/design: document probe preps SJ Park
2026-07-25 21:02 ` [RFC PATCH 16/17] Docs/admin-guide/mm/damon/usage: document probe preps sysfs files SJ Park
2026-07-25 21:02 ` [RFC PATCH 17/17] Docs/ABI/damon: document probe prep " SJ Park
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260725210225.129944-1-sj@kernel.org \
--to=sj@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=corbet@lwn.net \
--cc=damon@lists.linux.dev \
--cc=david@kernel.org \
--cc=liam@infradead.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=ljs@kernel.org \
--cc=mhocko@suse.com \
--cc=rppt@kernel.org \
--cc=shuah@kernel.org \
--cc=skhan@linuxfoundation.org \
--cc=surenb@google.com \
--cc=vbabka@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox