<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/include/linux/damon.h, branch v7.3-rc2</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>mm/damon: update outdated comment about DAMOS filter handling</title>
<updated>2026-08-07T01:57:22+00:00</updated>
<author>
<name>Song Hu</name>
<email>husong@kylinos.cn</email>
</author>
<published>2026-07-21T14:00:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=51fa46c364039d5f44737f24e2bf22ca5e143d0f'/>
<id>51fa46c364039d5f44737f24e2bf22ca5e143d0f</id>
<content type='text'>
The kernel-doc comment above enum damos_filter_type states that only the
anon and memcg type filters are handled by damon_operations (and therefore
accounted as 'tried'), and that DAMON_OPS_VADDR and DAMON_OPS_FVADDR do
not support those two filter types.

Neither is accurate anymore.  damos_filter_for_ops() routes every filter
type except ADDR and TARGET to the operations layer, and the VADDR and
FVADDR operations (the latter being a copy of the former) handle all of
those types through damos_folio_filter_match() / damos_va_filter_out(). 
Update the comment to match the code.

Link: https://lore.kernel.org/20260721140011.269802-1-sj@kernel.org
Signed-off-by: Song Hu &lt;husong@kylinos.cn&gt;
Reviewed-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The kernel-doc comment above enum damos_filter_type states that only the
anon and memcg type filters are handled by damon_operations (and therefore
accounted as 'tried'), and that DAMON_OPS_VADDR and DAMON_OPS_FVADDR do
not support those two filter types.

Neither is accurate anymore.  damos_filter_for_ops() routes every filter
type except ADDR and TARGET to the operations layer, and the VADDR and
FVADDR operations (the latter being a copy of the former) handle all of
those types through damos_folio_filter_match() / damos_va_filter_out(). 
Update the comment to match the code.

Link: https://lore.kernel.org/20260721140011.269802-1-sj@kernel.org
Signed-off-by: Song Hu &lt;husong@kylinos.cn&gt;
Reviewed-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide core-private damon_ctx fields</title>
<updated>2026-08-07T01:57:07+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8315cf471eff1669bdc536829935ef2607caa108'/>
<id>8315cf471eff1669bdc536829935ef2607caa108</id>
<content type='text'>
'ops', 'probes', 'adaptive_targets', 'schemes', and 'rnd_state' fields of
damon_ctx are intended to be used by only the DAMON core layer.  However,
those are mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-11-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'ops', 'probes', 'adaptive_targets', 'schemes', and 'rnd_state' fields of
damon_ctx are intended to be used by only the DAMON core layer.  However,
those are mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-11-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damon_probe fields</title>
<updated>2026-08-07T01:57:07+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=6a0c38aba6040c92d2213b9fad4cdac4fcbf3c8a'/>
<id>6a0c38aba6040c92d2213b9fad4cdac4fcbf3c8a</id>
<content type='text'>
'filters' and 'list' fields of damon_probe are intended to be used by only
the DAMON core layer.  However, those are mistakenly not marked as
private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-9-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'filters' and 'list' fields of damon_probe are intended to be used by only
the DAMON core layer.  However, those are mistakenly not marked as
private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-9-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damon_filter fields</title>
<updated>2026-08-07T01:57:06+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=55686d63f343cd738f70d120a1864bd5949d092d'/>
<id>55686d63f343cd738f70d120a1864bd5949d092d</id>
<content type='text'>
damon_filter-&gt;list is intended to be used by only the DAMON core layer. 
However, it is mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-8-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
damon_filter-&gt;list is intended to be used by only the DAMON core layer. 
However, it is mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-8-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damos fields</title>
<updated>2026-08-07T01:57:06+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=c647b1ec5e9bba76b3fe594f1ff9e6b32ff6b2c2'/>
<id>c647b1ec5e9bba76b3fe594f1ff9e6b32ff6b2c2</id>
<content type='text'>
'core_filters', 'ops_filters', 'last_applied' and 'list' fields of damos
are intended to be used by only the DAMON core layer.  However, those are
mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-7-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'core_filters', 'ops_filters', 'last_applied' and 'list' fields of damos
are intended to be used by only the DAMON core layer.  However, those are
mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-7-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damos_filter fields</title>
<updated>2026-08-07T01:57:06+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=b814d8f86a58a95a12147e0733c97ddef23bb261'/>
<id>b814d8f86a58a95a12147e0733c97ddef23bb261</id>
<content type='text'>
damos_filter-&gt;list is intended to be used by only the DAMON core layer. 
However, it is mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-6-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
damos_filter-&gt;list is intended to be used by only the DAMON core layer. 
However, it is mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-6-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damos_quota fields</title>
<updated>2026-08-07T01:57:05+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=f4dacc7d93231016a494ee2451a2351a95e017bb'/>
<id>f4dacc7d93231016a494ee2451a2351a95e017bb</id>
<content type='text'>
damos_quota-&gt;goals is intended to be used by only the DAMON core layer. 
But it is mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-5-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
damos_quota-&gt;goals is intended to be used by only the DAMON core layer. 
But it is mistakenly not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-5-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damos_quota_goal fields</title>
<updated>2026-08-07T01:57:05+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=4e061ef21a09ca0256b60ed0cf05085ecae2ef70'/>
<id>4e061ef21a09ca0256b60ed0cf05085ecae2ef70</id>
<content type='text'>
'last_psi_total' and 'list' of damos_quota_goal are intended to be used by
only the DAMON core layer.  Those are mistakenly not marked as private,
though.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-4-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'last_psi_total' and 'list' of damos_quota_goal are intended to be used by
only the DAMON core layer.  Those are mistakenly not marked as private,
though.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-4-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damon_target fields</title>
<updated>2026-08-07T01:57:05+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=300cb8592dd2722783eacb2fece0325570be1b0e'/>
<id>300cb8592dd2722783eacb2fece0325570be1b0e</id>
<content type='text'>
'nr_regions', 'regions_list' and 'list' fields of damon_target are
intended to be used by only the DAMON core layer.  Those are mistakenly
not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-3-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'nr_regions', 'regions_list' and 'list' fields of damon_target are
intended to be used by only the DAMON core layer.  Those are mistakenly
not marked as private.  Mark as private.

Link: https://lore.kernel.org/20260714143544.101305-3-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mm/damon/core: hide private damon_region fields</title>
<updated>2026-08-07T01:57:05+00:00</updated>
<author>
<name>SJ Park</name>
<email>sj@kernel.org</email>
</author>
<published>2026-07-14T14:35:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=e0ea9467dbefc5803fd36b6f1714c2be51518977'/>
<id>e0ea9467dbefc5803fd36b6f1714c2be51518977</id>
<content type='text'>
Patch series "mm/damon/core: hide core-private struct fields".

DAMON core structs hide core-private fields using 'private:' comment tags.
It is incomplete and inconsistent.  The linked list heads in a few
structs, for example, are intended to be hidden, and always be used using
the wrapper macros like damon_for_each_region().  But those were
mistakenly marked as non-private.  A few core layer-only fields were also
mistakenly added as non-private.

This only encourages callers to directly use the private fields.  It is
easy to make mistakes, and difficult to control.  Mark all such DAMON core
struct fields as private.

Patches 1-8 mark the private fields for damon_region, damon_target,
damos_quota_goal, damos_quota, damos_filter, damos, damon_filter and
damon_probe, respectively.  Patch 9 removes DAMON_SYSFS's direct access to
core-private field, damon_ctx-&gt;ops.  Finally patch 10 mark the private
fields for damon_ctx.


This patch (of 10):

damon_region-&gt;list is intended to be used by only the DAMON core layer. 
But it is mistakenly not marked as private.  Hide it from the callers by
marking it private.

Link: https://lore.kernel.org/20260714143544.101305-1-sj@kernel.org
Link: https://lore.kernel.org/20260714143544.101305-2-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Patch series "mm/damon/core: hide core-private struct fields".

DAMON core structs hide core-private fields using 'private:' comment tags.
It is incomplete and inconsistent.  The linked list heads in a few
structs, for example, are intended to be hidden, and always be used using
the wrapper macros like damon_for_each_region().  But those were
mistakenly marked as non-private.  A few core layer-only fields were also
mistakenly added as non-private.

This only encourages callers to directly use the private fields.  It is
easy to make mistakes, and difficult to control.  Mark all such DAMON core
struct fields as private.

Patches 1-8 mark the private fields for damon_region, damon_target,
damos_quota_goal, damos_quota, damos_filter, damos, damon_filter and
damon_probe, respectively.  Patch 9 removes DAMON_SYSFS's direct access to
core-private field, damon_ctx-&gt;ops.  Finally patch 10 mark the private
fields for damon_ctx.


This patch (of 10):

damon_region-&gt;list is intended to be used by only the DAMON core layer. 
But it is mistakenly not marked as private.  Hide it from the callers by
marking it private.

Link: https://lore.kernel.org/20260714143544.101305-1-sj@kernel.org
Link: https://lore.kernel.org/20260714143544.101305-2-sj@kernel.org
Signed-off-by: SJ Park &lt;sj@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
