From: sashiko-bot@kernel.org
To: "SJ Park" <sj@kernel.org>
Cc: "Andrew Morton" <akpm@linux-foundation.org>,
damon@lists.linux.dev, linux-mm@kvack.org
Subject: Re: [RFC PATCH v2 3/6] mm/damon/vaddr: implement sz_filter_passed for migrate_{hot,cold} action
Date: Sun, 01 Nov 2026 17:21:39 +0000 [thread overview]
Message-ID: <sashiko-outbox-192523@kernel.org> (raw)
In-Reply-To: <20261101171630.81477-4-sj@kernel.org>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] mm/damon/vaddr: undeclared dests in damos_va_migrate_pmd_entry()
--
commit 7670e03c4d866e7e831b34d6066cefe5b658b73a
Author: SJ Park <sj@kernel.org>
mm/damon/vaddr: implement sz_filter_passed for migrate_{hot,cold} action
This commit adds sz_filter_passed accounting to the DAMON_VADDR
migrate_hot and migrate_cold actions by passing the counter through
damos_va_migrate_private and accumulating the size of folios that pass
ops filters in damos_va_migrate_pmd_entry().
> diff --git a/mm/damon/vaddr.c b/mm/damon/vaddr.c
> index b1d7bcf7305bb..6fd0e07b60705 100644
> --- a/mm/damon/vaddr.c
> +++ b/mm/damon/vaddr.c
[ ... ]
> @@ -846,7 +847,7 @@ static int damos_va_migrate_pmd_entry(pmd_t *pmd, unsigned long addr,
> struct damos_va_migrate_private *priv = walk->private;
> struct list_head *migration_lists = priv->migration_lists;
> struct damos *s = priv->scheme;
> - struct damos_migrate_dests *dests = &s->migrate_dests;
> + unsigned long *sz_filter_passed = priv->sz_filter_passed;
> struct folio *folio;
> spinlock_t *ptl;
> pte_t *start_pte, *pte, ptent;
> @@ -865,6 +866,7 @@ static int damos_va_migrate_pmd_entry(pmd_t *pmd, unsigned long addr,
> if (damos_va_filter_out(s, folio, walk->vma, addr, NULL, pmd))
> goto huge_out;
> s->last_applied = folio;
> + *sz_filter_passed += folio_size(folio);
> damos_va_migrate_dests_add(folio, walk->vma, addr, dests,
> migration_lists);
[Severity: Low]
Was the declaration of dests in damos_va_migrate_pmd_entry() removed by
accident when adding sz_filter_passed?
Both the transparent hugepage path above and the PTE loop below in
damos_va_migrate_pmd_entry() still pass dests to
damos_va_migrate_dests_add(), which causes mm/damon/vaddr.c to fail to
compile with an undeclared identifier error when CONFIG_DAMON_VADDR is
enabled.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261101171630.81477-1-sj@kernel.org?part=3
next prev parent reply other threads:[~2026-11-01 17:21 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-01 17:16 [RFC PATCH v2 0/6] mm/damon: misc improvements/cleanups for core, vaddr, sysfs and tests SJ Park
2026-11-01 17:16 ` [RFC PATCH v2 1/6] mm/damon/vaddr: advance migration attempt in folio level for filter out SJ Park
2026-11-01 17:20 ` sashiko-bot
2026-11-01 17:16 ` [RFC PATCH v2 2/6] mm/damon/vaddr: use damos->last_applied for migrate action SJ Park
2026-11-01 17:27 ` sashiko-bot
2026-11-01 17:33 ` SJ Park
2026-11-01 17:16 ` [RFC PATCH v2 3/6] mm/damon/vaddr: implement sz_filter_passed for migrate_{hot,cold} action SJ Park
2026-11-01 17:21 ` sashiko-bot [this message]
2026-11-01 17:37 ` SJ Park
2026-11-01 17:16 ` [RFC PATCH v2 4/6] mm/damon/sysfs-schemes: drop redundant and racy zero target_value check SJ Park
2026-11-01 17:24 ` sashiko-bot
2026-11-01 17:16 ` [RFC PATCH v2 5/6] selftests/damon/damos_apply_interval: remove unused variables SJ Park
2026-11-01 17:18 ` sashiko-bot
2026-11-01 17:16 ` [RFC PATCH v2 6/6] selftests/damon: remove unused imports of os and sys modules SJ Park
2026-11-01 17:20 ` sashiko-bot
2026-11-01 17:38 ` 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=sashiko-outbox-192523@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=damon@lists.linux.dev \
--cc=linux-mm@kvack.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=sj@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.