From: sashiko-bot@kernel.org
To: "SJ Park" <sj@kernel.org>
Cc: damon@lists.linux.dev
Subject: Re: [RFC PATCH 3/3] mm/damon/core: move static variable rotation to damon_ctx
Date: Sat, 24 Oct 2026 19:37:58 +0000 [thread overview]
Message-ID: <sashiko-outbox-183857@kernel.org> (raw)
In-Reply-To: <20261024193351.87130-4-sj@kernel.org>
> damon_split_some_reigons() uses a static variable, rotation, to remember
> how many times it was called. It is again used to determine fair
> selection of regions to split. Since it is a static variable, it can be
> indeterministic and therefore less fair.
>
> The user impact is not critical. No crash, no leak. DAMON's
> best-effort and indeterministic monitoring accuracy could be slightly
> more indeterministic when multiple kdamonds are used in parallel.
>
> Fix the problem by moving the static variable into the damon_ctx struct.
>
> Fixes: 1a582e6e0174 ("mm/damon/core: split a fraction of regions when nr_regions exceeds max/2")
> Cc: <stable@vger.kernel.org> # 7.3.x
> Closes: https://sashiko.dev/#/bug/linux-eebfcdde-2881-48ef-8df1-e2019d2a47f2
> Signed-off-by: SJ Park <sj@kernel.org>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261024193351.87130-1-sj@kernel.org?part=3
prev parent reply other threads:[~2026-10-24 19:37 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-24 19:33 [RFC PATCH 0/3] mm/damon: fix three race bugs in sysfs and core SJ Park
2026-10-24 19:33 ` [RFC PATCH 1/3] mm/damon/sysfs-schemes: hold damon_sysfs_lock in target_metric_store() SJ Park
2026-10-24 19:44 ` sashiko-bot
2026-10-24 19:33 ` [RFC PATCH 2/3] mm/damon/core: move static variable last_nr_regions to damon_ctx SJ Park
2026-10-24 19:39 ` sashiko-bot
2026-10-24 19:33 ` [RFC PATCH 3/3] mm/damon/core: move static variable rotation " SJ Park
2026-10-24 19:37 ` sashiko-bot [this message]
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-183857@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=damon@lists.linux.dev \
--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.