[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20250102190138.47258-6-sj@kernel.org>
Date: Thu, 2 Jan 2025 11:01:38 -0800
From: SeongJae Park <sj@...nel.org>
To:
Cc: SeongJae Park <sj@...nel.org>,
Andrew Morton <akpm@...ux-foundation.org>,
damon@...ts.linux.dev,
kernel-team@...a.com,
linux-kernel@...r.kernel.org,
linux-mm@...ck.org,
Yunjeong Mun <yunjeong.mun@...com>,
Honggyu Kim <honggyu.kim@...com>
Subject: [RFC PATCH 5/5] mm/damon: explain "effective quota" on kernel-doc comment
The kernel-doc comment for 'struct damos_quota' describes how "effective
quota" is calculated, but does not explain what it is. Actually there
was an input[1] about it. Add the explanation on the comment.
Also, fix a trivial typo on the comment block: s/empt/empty/
[1] https://github.com/damonitor/damo/issues/17#issuecomment-2497525043
Cc: Yunjeong Mun <yunjeong.mun@...com>
Cc: Honggyu Kim <honggyu.kim@...com>
Suggested-by: Honggyu Kim <honggyu.kim@...com>
Signed-off-by: SeongJae Park <sj@...nel.org>
---
Changes from single-RFC
(https://lore.kernel.org/20241126002921.50035-1-sj@kernel.org)
- fix a typo and grammartical error (Honggyu Kim)
- Integrate into this patch series
include/linux/damon.h | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/include/linux/damon.h b/include/linux/damon.h
index ad0360711aca..ce477a0ed6a2 100644
--- a/include/linux/damon.h
+++ b/include/linux/damon.h
@@ -193,11 +193,16 @@ struct damos_quota_goal {
* size quota is set, DAMON tries to apply the action only up to &sz bytes
* within &reset_interval.
*
- * Internally, the time quota is transformed to a size quota using estimated
- * throughput of the scheme's action. DAMON then compares it against &sz and
- * uses smaller one as the effective quota.
+ * To convince the different types of quotas and goals, DAMON internally
+ * converts those into one single size quota called "effective quota". DAMON
+ * internally uses it as the only one real quota. The conversion is made as
+ * follows.
*
- * If @goals is not empt, DAMON calculates yet another size quota based on the
+ * The time quota is transformed to a size quota using estimated throughput of
+ * the scheme's action. DAMON then compares it against &sz and uses smaller
+ * one as the effective quota.
+ *
+ * If @goals is not empty, DAMON calculates yet another size quota based on the
* goals using its internal feedback loop algorithm, for every @reset_interval.
* Then, if the new size quota is smaller than the effective quota, it uses the
* new size quota as the effective quota.
--
2.39.5
Powered by blists - more mailing lists