All of lore.kernel.org
 help / color / mirror / Atom feed
From: SJ Park <sj@kernel.org>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: SJ Park <sj@kernel.org>, Shuah Khan <shuah@kernel.org>,
	damon@lists.linux.dev, linux-kernel@vger.kernel.org,
	linux-kselftest@vger.kernel.org, linux-mm@kvack.org
Subject: [PATCH 6/6] selftests/damon/sysfs.py: test damon probes
Date: Wed,  2 Sep 2026 07:03:12 -0700	[thread overview]
Message-ID: <20260902140313.85983-7-sj@kernel.org> (raw)
In-Reply-To: <20260902140313.85983-1-sj@kernel.org>

Extend sysfs.py to commit DAMON probes via sysfs, and see if it changed
in-kernel DAMON status as expected using drgn.

Signed-off-by: SJ Park <sj@kernel.org>
---
 tools/testing/selftests/damon/sysfs.py | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/tools/testing/selftests/damon/sysfs.py b/tools/testing/selftests/damon/sysfs.py
index 159cbeac067f8..66c826189320d 100755
--- a/tools/testing/selftests/damon/sysfs.py
+++ b/tools/testing/selftests/damon/sysfs.py
@@ -319,7 +319,21 @@ def main():
                 intervals_goal=_damon_sysfs.IntervalsGoal(
                     access_bp=400, aggrs=3, min_sample_us=5000,
                     max_sample_us=10000000),
-                update_us=2000000),
+                update_us=2000000,
+                probes=_damon_sysfs.DamonProbes(
+                    probes=[_damon_sysfs.DamonProbe(
+                        weight=42,
+                        filters=_damon_sysfs.DamonFilters(
+                            filters=[
+                                _damon_sysfs.DamonFilter(
+                                    type_='anon',
+                                    matching=True,
+                                    allow=True,
+                                    ),
+                                ]),
+                            ),
+                            ]),
+                    ),
             schemes=[_damon_sysfs.Damos(
                 action='pageout',
                 access_pattern=_damon_sysfs.DamosAccessPattern(
-- 
2.47.3


  parent reply	other threads:[~2026-09-02 14:04 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-02 14:03 [PATCH 0/6] mm/damon: add kunit and selftests for probes and probe weights SJ Park
2026-09-02 14:03 ` [PATCH 1/6] mm/damon/tests/core-kunit: test damon_commit_filter() SJ Park
2026-09-02 14:10   ` sashiko-bot
2026-09-02 14:03 ` [PATCH 2/6] mm/damon/tests/core-kunit: add damon_commit_probes() test SJ Park
2026-09-02 14:11   ` sashiko-bot
2026-09-02 14:03 ` [PATCH 3/6] selftests/damon/_damon_sysfs: implement DamonProbes SJ Park
2026-09-02 14:15   ` sashiko-bot
2026-09-02 14:03 ` [PATCH 4/6] selftests/damon/drgn_dump_damon_status: dump probes SJ Park
2026-09-02 14:15   ` sashiko-bot
2026-09-02 14:23     ` SJ Park
2026-09-02 14:03 ` [PATCH 5/6] selftests/damon/sysfs.py: extend commit assertion function for probes SJ Park
2026-09-02 14:13   ` sashiko-bot
2026-09-02 14:03 ` SJ Park [this message]
2026-09-02 14:15   ` [PATCH 6/6] selftests/damon/sysfs.py: test damon probes sashiko-bot
2026-09-02 14:25 ` [PATCH 0/6] mm/damon: add kunit and selftests for probes and probe weights 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=20260902140313.85983-7-sj@kernel.org \
    --to=sj@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=damon@lists.linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=shuah@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.