sphinx.addnodesdocument)}( rawsourcechildren]( translations LanguagesNode)}(hhh](h pending_xref)}(hhh]docutils.nodesTextChinese (Simplified)}parenthsba attributes}(ids]classes]names]dupnames]backrefs] refdomainstdreftypedoc reftarget /translations/zh_CN/mm/damon/apimodnameN classnameN refexplicitutagnamehhh ubh)}(hhh]hChinese (Traditional)}hh2sbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget /translations/zh_TW/mm/damon/apimodnameN classnameN refexplicituh1hhh ubh)}(hhh]hItalian}hhFsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget /translations/it_IT/mm/damon/apimodnameN classnameN refexplicituh1hhh ubh)}(hhh]hJapanese}hhZsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget /translations/ja_JP/mm/damon/apimodnameN classnameN refexplicituh1hhh ubh)}(hhh]hKorean}hhnsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget /translations/ko_KR/mm/damon/apimodnameN classnameN refexplicituh1hhh ubh)}(hhh]hPortuguese (Brazilian)}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget /translations/pt_BR/mm/damon/apimodnameN classnameN refexplicituh1hhh ubh)}(hhh]hSpanish}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget /translations/sp_SP/mm/damon/apimodnameN classnameN refexplicituh1hhh ubeh}(h]h ]h"]h$]h&]current_languageEnglishuh1h hh _documenthsourceNlineNubhcomment)}(h SPDX-License-Identifier: GPL-2.0h]h SPDX-License-Identifier: GPL-2.0}hhsbah}(h]h ]h"]h$]h&] xml:spacepreserveuh1hhhhhh:/var/lib/git/docbuild/linux/Documentation/mm/damon/api.rsthKubhsection)}(hhh](htitle)}(h API Referenceh]h API Reference}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhhhhhKubh paragraph)}(hKernel space programs can use every feature of DAMON using below APIs. All you need to do is including ``damon.h``, which is located in ``include/linux/`` of the source tree.h](hhKernel space programs can use every feature of DAMON using below APIs. All you need to do is including }(hhhhhNhNubhliteral)}(h ``damon.h``h]hdamon.h}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhubh, which is located in }(hhhhhNhNubh)}(h``include/linux/``h]hinclude/linux/}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhubh of the source tree.}(hhhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKhhhhubh)}(hhh](h)}(h Structuresh]h Structures}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhK ubhindex)}(hhh]h}(h]h ]h"]h$]h&]entries](singledamon_addr_range (C struct)c.damon_addr_rangehNtauh1j$hjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhNubhdesc)}(hhh](hdesc_signature)}(hdamon_addr_rangeh]hdesc_signature_line)}(hstruct damon_addr_rangeh](hdesc_sig_keyword)}(hstructh]hstruct}(hjIhhhNhNubah}(h]h ]kah"]h$]h&]uh1jGhjChhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKubhdesc_sig_space)}(h h]h }(hj[hhhNhNubah}(h]h ]wah"]h$]h&]uh1jYhjChhhjXhKubh desc_name)}(hdamon_addr_rangeh]h desc_sig_name)}(hj?h]hdamon_addr_range}(hjrhhhNhNubah}(h]h ]nah"]h$]h&]uh1jphjlubah}(h]h ](sig-namedescnameeh"]h$]h&]hhuh1jjhjChhhjXhKubeh}(h]h ]h"]h$]h&]hhƌ add_permalinkuh1jAsphinx_line_type declaratorhj=hhhjXhKubah}(h]j3ah ](sig sig-objecteh"]h$]h&] is_multiline _toc_parts) _toc_namehuh1j;hjXhKhj8hhubh desc_content)}(hhh]h)}(h5Represents an address region of [**start**, **end**).h](h!Represents an address region of [}(hjhhhNhNubhstrong)}(h **start**h]hstart}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh, }(hjhhhNhNubj)}(h**end**h]hend}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh).}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubah}(h]h ]h"]h$]h&]uh1jhj8hhhjXhKubeh}(h]h ](cstructeh"]h$]h&]domainjobjtypejdesctypejnoindex noindexentrynocontentsentryuh1j6hhhjhj5hNubh container)}(h**Definition**:: struct damon_addr_range { unsigned long start; unsigned long end; }; **Members** ``start`` Start address of the region (inclusive). ``end`` End address of the region (exclusive).h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubh literal_block)}(hLstruct damon_addr_range { unsigned long start; unsigned long end; };h]hLstruct damon_addr_range { unsigned long start; unsigned long end; };}hjsbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubh)}(h **Members**h]j)}(hj h]hMembers}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK#hjubhdefinition_list)}(hhh](hdefinition_list_item)}(h3``start`` Start address of the region (inclusive). h](hterm)}(h ``start``h]h)}(hjEh]hstart}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjCubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj=ubh definition)}(hhh]h)}(h(Start address of the region (inclusive).h]h(Start address of the region (inclusive).}(hj`hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZhKhj]ubah}(h]h ]h"]h$]h&]uh1j[hj=ubeh}(h]h ]h"]h$]h&]uh1j;hjZhKhj8ubj<)}(h.``end`` End address of the region (exclusive).h](jB)}(h``end``h]h)}(hjh]hend}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj~ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjzubj\)}(hhh]h)}(h&End address of the region (exclusive).h]h&End address of the region (exclusive).}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubah}(h]h ]h"]h$]h&]uh1j[hjzubeh}(h]h ]h"]h$]h&]uh1j;hjhKhj8ubeh}(h]h ]h"]h$]h&]uh1j6hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_size_range (C struct)c.damon_size_rangehNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamon_size_rangeh]jB)}(hstruct damon_size_rangeh](jH)}(hjKh]hstruct}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK!ubjZ)}(h h]h }(hjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhjhK!ubjk)}(hdamon_size_rangeh]jq)}(hjh]hdamon_size_range}(hjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhjhK!ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhjhK!ubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hjhK!hjhhubj)}(hhh]h)}(hubah}(h]h ]h"]h$]h&]uh1j[hj"ubeh}(h]h ]h"]h$]h&]uh1j;hj=hK/hjubj<)}(h1``nr_accesses`` Access frequency of this region. h](jB)}(h``nr_accesses``h]h)}(hjah]h nr_accesses}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhj_ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK0hj[ubj\)}(hhh]h)}(h Access frequency of this region.h]h Access frequency of this region.}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjvhK0hjwubah}(h]h ]h"]h$]h&]uh1j[hj[ubeh}(h]h ]h"]h$]h&]uh1j;hjvhK0hjubj<)}(h8``probe_hits`` Number of probe-positive region samples. h](jB)}(h``probe_hits``h]h)}(hjh]h probe_hits}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK1hjubj\)}(hhh]h)}(h(Number of probe-positive region samples.h]h(Number of probe-positive region samples.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK1hjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhK1hjubj<)}(h``age`` Age of this region.h](jB)}(h``age``h]h)}(hjh]hage}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK1hjubj\)}(hhh]h)}(hAge of this region.h]hAge of this region.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK2hjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhK1hjubeh}(h]h ]h"]h$]h&]uh1j6hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK5hjhhubh)}(hdFor any use case, **ar** should be non-zero positive size. damon_set_regions() does the validation.h](hFor any use case, }(hj,hhhNhNubj)}(h**ar**h]har}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj,ubhL should be non-zero positive size. damon_set_regions() does the validation.}(hj,hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK2hjhhubh)}(hXu**nr_accesses** is reset to zero for every :c:type:`damon_attrs->aggr_interval ` and be increased for every :c:type:`damon_attrs->sample_interval ` if an access to the region during the last sampling interval is found. The update of this field should not be done with direct access but with the helper function, damon_update_region_access_rate().h](j)}(h**nr_accesses**h]h nr_accesses}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjMubh is reset to zero for every }(hjMhhhNhNubh)}(h2:c:type:`damon_attrs->aggr_interval `h]h)}(hjeh]hdamon_attrs->aggr_interval}(hjghhhNhNubah}(h]h ](xrefjc-typeeh"]h$]h&]uh1hhjcubah}(h]h ]h"]h$]h&]refdoc mm/damon/api refdomainjreftypetype refexplicitrefwarn c:parent_keysphinx.domains.c LookupKey)}data]sb reftarget damon_attrsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK5hjMubh and be increased for every }(hjMhhhNhNubh)}(h4:c:type:`damon_attrs->sample_interval `h]h)}(hjh]hdamon_attrs->sample_interval}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhjhK5hjMubh if an access to the region during the last sampling interval is found. The update of this field should not be done with direct access but with the helper function, damon_update_region_access_rate().}(hjMhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhK5hjhhubh)}(hX3**age** is initially zero, increased for each aggregation interval, and reset to zero again if the access frequency is significantly changed. If two regions are merged into a new region, both **nr_accesses** and **age** of the new region are set as region size-weighted average of those of the two regions.h](j)}(h**age**h]hage}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh is initially zero, increased for each aggregation interval, and reset to zero again if the access frequency is significantly changed. If two regions are merged into a new region, both }(hjhhhNhNubj)}(h**nr_accesses**h]h nr_accesses}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh and }(hjhhhNhNubj)}(h**age**h]hage}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubhW of the new region are set as region size-weighted average of those of the two regions.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK;hjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_target (C struct)c.damon_targethNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damon_targeth]jB)}(hstruct damon_targeth](jH)}(hjKh]hstruct}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKCubjZ)}(h h]h }(hj#hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhj"hKCubjk)}(h damon_targeth]jq)}(hjh]h damon_target}(hj5hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj1ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhj"hKCubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj hhhj"hKCubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hj"hKChj hhubj)}(hhh]h)}(hRepresents a monitoring target.h]hRepresents a monitoring target.}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKPhjThhubah}(h]h ]h"]h$]h&]uh1jhj hhhj"hKCubeh}(h]h ](jstructeh"]h$]h&]jjjjojjojjjuh1j6hhhjhj5hNubj)}(h**Definition**:: struct damon_target { struct pid *pid; bool obsolete; }; **Members** ``pid`` The PID of the virtual address space to monitor. ``obsolete`` Whether the commit destination target is obsolete.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjwubh:}(hjwhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKThjsubj)}(h@struct damon_target { struct pid *pid; bool obsolete; };h]h@struct damon_target { struct pid *pid; bool obsolete; };}hjsbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKVhjsubh)}(h **Members**h]j)}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK[hjsubj7)}(hhh](j<)}(h9``pid`` The PID of the virtual address space to monitor. h](jB)}(h``pid``h]h)}(hjh]hpid}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKRhjubj\)}(hhh]h)}(h0The PID of the virtual address space to monitor.h]h0The PID of the virtual address space to monitor.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKRhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKRhjubj<)}(h?``obsolete`` Whether the commit destination target is obsolete.h](jB)}(h ``obsolete``h]h)}(hjh]hobsolete}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKRhjubj\)}(hhh]h)}(h2Whether the commit destination target is obsolete.h]h2Whether the commit destination target is obsolete.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKShjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKRhjubeh}(h]h ]h"]h$]h&]uh1j6hjsubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj@h]h Description}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj>ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKVhjhhubh)}(hX0Each monitoring context could have multiple targets. For example, a context for virtual memory address spaces could have multiple target processes. The **pid** should be set for appropriate :c:type:`struct damon_operations ` including the virtual address spaces monitoring operations.h](hEach monitoring context could have multiple targets. For example, a context for virtual memory address spaces could have multiple target processes. The }(hjVhhhNhNubj)}(h**pid**h]hpid}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjVubh should be set for appropriate }(hjVhhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hjrh]hstruct damon_operations}(hjthhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjpubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKShjVubh< including the virtual address spaces monitoring operations.}(hjVhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKShjhhubh)}(h**obsolete** is used only for damon_commit_targets() source targets, to specify the matching destination targets are obsolete. Read damon_commit_targets() to see how it is handled.h](j)}(h **obsolete**h]hobsolete}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh is used only for damon_commit_targets() source targets, to specify the matching destination targets are obsolete. Read damon_commit_targets() to see how it is handled.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKXhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_action (C enum)c.damos_actionhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damos_actionh]jB)}(henum damos_actionh](jH)}(henumh]henum}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK_ubjZ)}(h h]h }(hjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhjhK_ubjk)}(h damos_actionh]jq)}(hjh]h damos_action}(hjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhjhK_ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhjhK_ubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hjhK_hjhhubj)}(hhh]h)}(hHRepresents an action of a Data Access Monitoring-based Operation Scheme.h]hHRepresents an action of a Data Access Monitoring-based Operation Scheme.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKjhj hhubah}(h]h ]h"]h$]h&]uh1jhjhhhjhK_ubeh}(h]h ](jenumeh"]h$]h&]jjjj+ jj+ jjjuh1j6hhhjhj5hNubj)}(hX***Constants** ``DAMOS_WILLNEED`` Call ``madvise()`` for the region with MADV_WILLNEED. ``DAMOS_COLD`` Call ``madvise()`` for the region with MADV_COLD. ``DAMOS_PAGEOUT`` Reclaim the region. ``DAMOS_HUGEPAGE`` Call ``madvise()`` for the region with MADV_HUGEPAGE. ``DAMOS_NOHUGEPAGE`` Call ``madvise()`` for the region with MADV_NOHUGEPAGE. ``DAMOS_COLLAPSE`` Call ``madvise()`` for the region with MADV_COLLAPSE. ``DAMOS_LRU_PRIO`` Prioritize the region on its LRU lists. ``DAMOS_LRU_DEPRIO`` Deprioritize the region on its LRU lists. ``DAMOS_MIGRATE_HOT`` Migrate the regions prioritizing warmer regions. ``DAMOS_MIGRATE_COLD`` Migrate the regions prioritizing colder regions. ``DAMOS_STAT`` Do nothing but count the stat. ``NR_DAMOS_ACTIONS`` Total number of DAMOS actionsh](h)}(h **Constants**h]j)}(hj5 h]h Constants}(hj7 hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj3 ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKnhj/ ubj7)}(hhh](j<)}(hI``DAMOS_WILLNEED`` Call ``madvise()`` for the region with MADV_WILLNEED. h](jB)}(h``DAMOS_WILLNEED``h]h)}(hjT h]hDAMOS_WILLNEED}(hjV hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjR ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKqhjN ubj\)}(hhh]h)}(h5Call ``madvise()`` for the region with MADV_WILLNEED.h](hCall }(hjm hhhNhNubh)}(h ``madvise()``h]h madvise()}(hju hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjm ubh# for the region with MADV_WILLNEED.}(hjm hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhji hKqhjj ubah}(h]h ]h"]h$]h&]uh1j[hjN ubeh}(h]h ]h"]h$]h&]uh1j;hji hKqhjK ubj<)}(hA``DAMOS_COLD`` Call ``madvise()`` for the region with MADV_COLD. h](jB)}(h``DAMOS_COLD``h]h)}(hj h]h DAMOS_COLD}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKthj ubj\)}(hhh]h)}(h1Call ``madvise()`` for the region with MADV_COLD.h](hCall }(hj hhhNhNubh)}(h ``madvise()``h]h madvise()}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubh for the region with MADV_COLD.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj hKthj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKthjK ubj<)}(h&``DAMOS_PAGEOUT`` Reclaim the region. h](jB)}(h``DAMOS_PAGEOUT``h]h)}(hj h]h DAMOS_PAGEOUT}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKwhj ubj\)}(hhh]h)}(hReclaim the region.h]hReclaim the region.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKwhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKwhjK ubj<)}(hI``DAMOS_HUGEPAGE`` Call ``madvise()`` for the region with MADV_HUGEPAGE. h](jB)}(h``DAMOS_HUGEPAGE``h]h)}(hj# h]hDAMOS_HUGEPAGE}(hj% hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj! ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKzhj ubj\)}(hhh]h)}(h5Call ``madvise()`` for the region with MADV_HUGEPAGE.h](hCall }(hj< hhhNhNubh)}(h ``madvise()``h]h madvise()}(hjD hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj< ubh# for the region with MADV_HUGEPAGE.}(hj< hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj8 hKzhj9 ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj8 hKzhjK ubj<)}(hM``DAMOS_NOHUGEPAGE`` Call ``madvise()`` for the region with MADV_NOHUGEPAGE. h](jB)}(h``DAMOS_NOHUGEPAGE``h]h)}(hjn h]hDAMOS_NOHUGEPAGE}(hjp hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjl ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK}hjh ubj\)}(hhh]h)}(h7Call ``madvise()`` for the region with MADV_NOHUGEPAGE.h](hCall }(hj hhhNhNubh)}(h ``madvise()``h]h madvise()}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubh% for the region with MADV_NOHUGEPAGE.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj hK}hj ubah}(h]h ]h"]h$]h&]uh1j[hjh ubeh}(h]h ]h"]h$]h&]uh1j;hj hK}hjK ubj<)}(hI``DAMOS_COLLAPSE`` Call ``madvise()`` for the region with MADV_COLLAPSE. h](jB)}(h``DAMOS_COLLAPSE``h]h)}(hj h]hDAMOS_COLLAPSE}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(h5Call ``madvise()`` for the region with MADV_COLLAPSE.h](hCall }(hj hhhNhNubh)}(h ``madvise()``h]h madvise()}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubh# for the region with MADV_COLLAPSE.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjK ubj<)}(h;``DAMOS_LRU_PRIO`` Prioritize the region on its LRU lists. h](jB)}(h``DAMOS_LRU_PRIO``h]h)}(hj h]hDAMOS_LRU_PRIO}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(h'Prioritize the region on its LRU lists.h]h'Prioritize the region on its LRU lists.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjK ubj<)}(h?``DAMOS_LRU_DEPRIO`` Deprioritize the region on its LRU lists. h](jB)}(h``DAMOS_LRU_DEPRIO``h]h)}(hj= h]hDAMOS_LRU_DEPRIO}(hj? hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj; ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj7 ubj\)}(hhh]h)}(h)Deprioritize the region on its LRU lists.h]h)Deprioritize the region on its LRU lists.}(hjV hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjR hKhjS ubah}(h]h ]h"]h$]h&]uh1j[hj7 ubeh}(h]h ]h"]h$]h&]uh1j;hjR hKhjK ubj<)}(hG``DAMOS_MIGRATE_HOT`` Migrate the regions prioritizing warmer regions. h](jB)}(h``DAMOS_MIGRATE_HOT``h]h)}(hjv h]hDAMOS_MIGRATE_HOT}(hjx hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjt ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjp ubj\)}(hhh]h)}(h0Migrate the regions prioritizing warmer regions.h]h0Migrate the regions prioritizing warmer regions.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hjp ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjK ubj<)}(hH``DAMOS_MIGRATE_COLD`` Migrate the regions prioritizing colder regions. h](jB)}(h``DAMOS_MIGRATE_COLD``h]h)}(hj h]hDAMOS_MIGRATE_COLD}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(h0Migrate the regions prioritizing colder regions.h]h0Migrate the regions prioritizing colder regions.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjK ubj<)}(h.``DAMOS_STAT`` Do nothing but count the stat. h](jB)}(h``DAMOS_STAT``h]h)}(hj h]h DAMOS_STAT}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(hDo nothing but count the stat.h]hDo nothing but count the stat.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjK ubj<)}(h2``NR_DAMOS_ACTIONS`` Total number of DAMOS actionsh](jB)}(h``NR_DAMOS_ACTIONS``h]h)}(hj! h]hNR_DAMOS_ACTIONS}(hj# hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(hTotal number of DAMOS actionsh]hTotal number of DAMOS actions}(hj: hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj7 ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj6 hKhjK ubeh}(h]h ]h"]h$]h&]uh1j6hj/ ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjd h]h Description}(hjf hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjb ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hThe support of each action is up to running :c:type:`struct damon_operations `. Refer to 'Operation Action' section of Documentation/mm/damon/design.rst for status of the supports.h](h,The support of each action is up to running }(hjz hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj h]hstruct damon_operations}(hj hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKyhjz ubhj. Refer to ‘Operation Action’ section of Documentation/mm/damon/design.rst for status of the supports.}(hjz hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj hKyhjhhubh)}(h2Note that DAMOS_PAGEOUT doesn't trigger demotions.h]h4Note that DAMOS_PAGEOUT doesn’t trigger demotions.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhK}hjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1 damos_quota_goal_metric (C enum)c.damos_quota_goal_metrichNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_quota_goal_metrich]jB)}(henum damos_quota_goal_metrich](jH)}(hjh]henum}(hj hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKubjZ)}(h h]h }(hj hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj hhhj hKubjk)}(hdamos_quota_goal_metrich]jq)}(hj h]hdamos_quota_goal_metric}(hj hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj hhhj hKubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj hhhj hKubah}(h]j ah ](jjeh"]h$]h&]jj)jhuh1j;hj hKhj hhubj)}(hhh]h)}(h,Represents the metric to be used as the goalh]h,Represents the metric to be used as the goal}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj hhubah}(h]h ]h"]h$]h&]uh1jhj hhhj hKubeh}(h]h ](jenumeh"]h$]h&]jjjj. jj. jjjuh1j6hhhjhj5hNubj)}(hX**Constants** ``DAMOS_QUOTA_USER_INPUT`` User-input value. ``DAMOS_QUOTA_SOME_MEM_PSI_US`` System level some memory PSI in us. ``DAMOS_QUOTA_NODE_MEM_USED_BP`` MemUsed ratio of a node. ``DAMOS_QUOTA_NODE_MEM_FREE_BP`` MemFree ratio of a node. ``DAMOS_QUOTA_NODE_MEMCG_USED_BP`` MemUsed ratio of a node for a cgroup. ``DAMOS_QUOTA_NODE_MEMCG_FREE_BP`` MemFree ratio of a node for a cgroup. ``DAMOS_QUOTA_ACTIVE_MEM_BP`` Active to total LRU memory ratio. ``DAMOS_QUOTA_INACTIVE_MEM_BP`` Inactive to total LRU memory ratio. ``DAMOS_QUOTA_NODE_ELIGIBLE_MEM_BP`` Scheme-eligible memory ratio of a node in basis points (0-10000). ``NR_DAMOS_QUOTA_GOAL_METRICS`` Number of DAMOS quota goal metrics.h](h)}(h **Constants**h]j)}(hj8 h]h Constants}(hj: hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj6 ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj2 ubj7)}(hhh](j<)}(h-``DAMOS_QUOTA_USER_INPUT`` User-input value. h](jB)}(h``DAMOS_QUOTA_USER_INPUT``h]h)}(hjW h]hDAMOS_QUOTA_USER_INPUT}(hjY hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjU ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjQ ubj\)}(hhh]h)}(hUser-input value.h]hUser-input value.}(hjp hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjl hKhjm ubah}(h]h ]h"]h$]h&]uh1j[hjQ ubeh}(h]h ]h"]h$]h&]uh1j;hjl hKhjN ubj<)}(hD``DAMOS_QUOTA_SOME_MEM_PSI_US`` System level some memory PSI in us. h](jB)}(h``DAMOS_QUOTA_SOME_MEM_PSI_US``h]h)}(hj h]hDAMOS_QUOTA_SOME_MEM_PSI_US}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(h#System level some memory PSI in us.h]h#System level some memory PSI in us.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjN ubj<)}(h:``DAMOS_QUOTA_NODE_MEM_USED_BP`` MemUsed ratio of a node. h](jB)}(h ``DAMOS_QUOTA_NODE_MEM_USED_BP``h]h)}(hj h]hDAMOS_QUOTA_NODE_MEM_USED_BP}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(hMemUsed ratio of a node.h]hMemUsed ratio of a node.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hKhj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hKhjN ubj<)}(h:``DAMOS_QUOTA_NODE_MEM_FREE_BP`` MemFree ratio of a node. h](jB)}(h ``DAMOS_QUOTA_NODE_MEM_FREE_BP``h]h)}(hjh]hDAMOS_QUOTA_NODE_MEM_FREE_BP}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj ubj\)}(hhh]h)}(hMemFree ratio of a node.h]hMemFree ratio of a node.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjN ubj<)}(hI``DAMOS_QUOTA_NODE_MEMCG_USED_BP`` MemUsed ratio of a node for a cgroup. h](jB)}(h"``DAMOS_QUOTA_NODE_MEMCG_USED_BP``h]h)}(hj;h]hDAMOS_QUOTA_NODE_MEMCG_USED_BP}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj5ubj\)}(hhh]h)}(h%MemUsed ratio of a node for a cgroup.h]h%MemUsed ratio of a node for a cgroup.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hhjPhKhjQubah}(h]h ]h"]h$]h&]uh1j[hj5ubeh}(h]h ]h"]h$]h&]uh1j;hjPhKhjN ubj<)}(hI``DAMOS_QUOTA_NODE_MEMCG_FREE_BP`` MemFree ratio of a node for a cgroup. h](jB)}(h"``DAMOS_QUOTA_NODE_MEMCG_FREE_BP``h]h)}(hjth]hDAMOS_QUOTA_NODE_MEMCG_FREE_BP}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjrubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjnubj\)}(hhh]h)}(h%MemFree ratio of a node for a cgroup.h]h%MemFree ratio of a node for a cgroup.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjnubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjN ubj<)}(h@``DAMOS_QUOTA_ACTIVE_MEM_BP`` Active to total LRU memory ratio. h](jB)}(h``DAMOS_QUOTA_ACTIVE_MEM_BP``h]h)}(hjh]hDAMOS_QUOTA_ACTIVE_MEM_BP}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h!Active to total LRU memory ratio.h]h!Active to total LRU memory ratio.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjN ubj<)}(hD``DAMOS_QUOTA_INACTIVE_MEM_BP`` Inactive to total LRU memory ratio. h](jB)}(h``DAMOS_QUOTA_INACTIVE_MEM_BP``h]h)}(hjh]hDAMOS_QUOTA_INACTIVE_MEM_BP}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h#Inactive to total LRU memory ratio.h]h#Inactive to total LRU memory ratio.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjN ubj<)}(hg``DAMOS_QUOTA_NODE_ELIGIBLE_MEM_BP`` Scheme-eligible memory ratio of a node in basis points (0-10000). h](jB)}(h$``DAMOS_QUOTA_NODE_ELIGIBLE_MEM_BP``h]h)}(hjh]h DAMOS_QUOTA_NODE_ELIGIBLE_MEM_BP}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(hAScheme-eligible memory ratio of a node in basis points (0-10000).h]hAScheme-eligible memory ratio of a node in basis points (0-10000).}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj5ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hj4hKhjN ubj<)}(hC``NR_DAMOS_QUOTA_GOAL_METRICS`` Number of DAMOS quota goal metrics.h](jB)}(h``NR_DAMOS_QUOTA_GOAL_METRICS``h]h)}(hjYh]hNR_DAMOS_QUOTA_GOAL_METRICS}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjWubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjSubj\)}(hhh]h)}(h#Number of DAMOS quota goal metrics.h]h#Number of DAMOS quota goal metrics.}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjoubah}(h]h ]h"]h$]h&]uh1j[hjSubeh}(h]h ]h"]h$]h&]uh1j;hjnhKhjN ubeh}(h]h ]h"]h$]h&]uh1j6hj2 ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hMMetrics equal to larger than **NR_DAMOS_QUOTA_GOAL_METRICS** are unsupported.h](hMetrics equal to larger than }(hjhhhNhNubj)}(h**NR_DAMOS_QUOTA_GOAL_METRICS**h]hNR_DAMOS_QUOTA_GOAL_METRICS}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh are unsupported.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_quota_goal (C struct)c.damos_quota_goalhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_quota_goalh]jB)}(hstruct damos_quota_goalh](jH)}(hjKh]hstruct}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKubjZ)}(h h]h }(hjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhjhKubjk)}(hdamos_quota_goalh]jq)}(hjh]hdamos_quota_goal}(hj hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhjhKubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhjhKubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hjhKhjhhubj)}(hhh]h)}(h$DAMOS scheme quota auto-tuning goal.h]h$DAMOS scheme quota auto-tuning goal.}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj+hhubah}(h]h ]h"]h$]h&]uh1jhjhhhjhKubeh}(h]h ](jstructeh"]h$]h&]jjjjFjjFjjjuh1j6hhhjhj5hNubj)}(hXB**Definition**:: struct damos_quota_goal { enum damos_quota_goal_metric metric; unsigned long target_value; unsigned long current_value; union { struct { int nid; u64 memcg_id; }; }; }; **Members** ``metric`` Metric to be used for representing the goal. ``target_value`` Target value of **metric** to achieve with the tuning. ``current_value`` Current value of **metric**. ``{unnamed_union}`` anonymous ``{unnamed_struct}`` anonymous ``nid`` Node id. ``memcg_id`` Memcg id.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNubh:}(hjNhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjJubj)}(hstruct damos_quota_goal { enum damos_quota_goal_metric metric; unsigned long target_value; unsigned long current_value; union { struct { int nid; u64 memcg_id; }; }; };h]hstruct damos_quota_goal { enum damos_quota_goal_metric metric; unsigned long target_value; unsigned long current_value; union { struct { int nid; u64 memcg_id; }; }; };}hjksbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjJubh)}(h **Members**h]j)}(hj|h]hMembers}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjzubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjJubj7)}(hhh](j<)}(h8``metric`` Metric to be used for representing the goal. h](jB)}(h ``metric``h]h)}(hjh]hmetric}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h,Metric to be used for representing the goal.h]h,Metric to be used for representing the goal.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjubj<)}(hH``target_value`` Target value of **metric** to achieve with the tuning. h](jB)}(h``target_value``h]h)}(hjh]h target_value}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h6Target value of **metric** to achieve with the tuning.h](hTarget value of }(hjhhhNhNubj)}(h **metric**h]hmetric}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh to achieve with the tuning.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjubj<)}(h/``current_value`` Current value of **metric**. h](jB)}(h``current_value``h]h)}(hjh]h current_value}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(hCurrent value of **metric**.h](hCurrent value of }(hj8hhhNhNubj)}(h **metric**h]hmetric}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8ubh.}(hj8hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj4hKhj5ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hj4hKhjubj<)}(h``{unnamed_union}`` anonymous h](jB)}(h``{unnamed_union}``h]h)}(hjjh]h{unnamed_union}}(hjlhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjdubj\)}(hhh]h)}(h anonymoush]h anonymous}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjdubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjubj<)}(h``{unnamed_struct}`` anonymous h](jB)}(h``{unnamed_struct}``h]h)}(hjh]h{unnamed_struct}}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h anonymoush]h anonymous}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjubj<)}(h``nid`` Node id. h](jB)}(h``nid``h]h)}(hjh]hnid}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(hNode id.h]hNode id.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjubj<)}(h``memcg_id`` Memcg id.h](jB)}(h ``memcg_id``h]h)}(hjh]hmemcg_id}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h Memcg id.h]h Memcg id.}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj+ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hj*hKhjubeh}(h]h ]h"]h$]h&]uh1j6hjJubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjXh]h Description}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjVubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hData structure for getting the current score of the quota tuning goal. The score is calculated by how close **current_value** and **target_value** are. Then the score is entered to DAMON's internal feedback loop mechanism to get the auto-tuned quota.h](hmData structure for getting the current score of the quota tuning goal. The score is calculated by how close }(hjnhhhNhNubj)}(h**current_value**h]h current_value}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjnubh and }(hjnhhhNhNubj)}(h**target_value**h]h target_value}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjnubhk are. Then the score is entered to DAMON’s internal feedback loop mechanism to get the auto-tuned quota.}(hjnhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hIf **metric** is DAMOS_QUOTA_USER_INPUT, **current_value** should be manually entered by the user, probably inside the kdamond callbacks. Otherwise, DAMON sets **current_value** with self-measured value of **metric**.h](hIf }(hjhhhNhNubj)}(h **metric**h]hmetric}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh is DAMOS_QUOTA_USER_INPUT, }(hjhhhNhNubj)}(h**current_value**h]h current_value}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubhg should be manually entered by the user, probably inside the kdamond callbacks. Otherwise, DAMON sets }(hjhhhNhNubj)}(h**current_value**h]h current_value}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh with self-measured value of }(hjhhhNhNubj)}(h **metric**h]hmetric}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hIf **metric** is DAMOS_QUOTA_NODE_MEM_{USED,FREE}_BP, **nid** represents the node id of the target node to account the used/free memory.h](hIf }(hjhhhNhNubj)}(h **metric**h]hmetric}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh) is DAMOS_QUOTA_NODE_MEM_{USED,FREE}_BP, }(hjhhhNhNubj)}(h**nid**h]hnid}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubhK represents the node id of the target node to account the used/free memory.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hIf **metric** is DAMOS_QUOTA_NODE_MEMCG_{USED,FREE}_BP, **nid** and **memcg_id** represents the node id and the cgroup to account the used memory for.h](hIf }(hj+hhhNhNubj)}(h **metric**h]hmetric}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubh+ is DAMOS_QUOTA_NODE_MEMCG_{USED,FREE}_BP, }(hj+hhhNhNubj)}(h**nid**h]hnid}(hjEhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubh and }(hj+hhhNhNubj)}(h **memcg_id**h]hmemcg_id}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubhF represents the node id and the cgroup to account the used memory for.}(hj+hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_quota_goal_tuner (C enum)c.damos_quota_goal_tunerhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_quota_goal_tunerh]jB)}(henum damos_quota_goal_tunerh](jH)}(hjh]henum}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKubjZ)}(h h]h }(hjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhjhKubjk)}(hdamos_quota_goal_tunerh]jq)}(hjh]hdamos_quota_goal_tuner}(hjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhjhKubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhjhKubah}(h]j|ah ](jjeh"]h$]h&]jj)jhuh1j;hjhKhj~hhubj)}(hhh]h)}(hGoal-based quota tuning logic.h]hGoal-based quota tuning logic.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubah}(h]h ]h"]h$]h&]uh1jhj~hhhjhKubeh}(h]h ](jenumeh"]h$]h&]jjjjjjjjjuh1j6hhhjhj5hNubj)}(h**Constants** ``DAMOS_QUOTA_GOAL_TUNER_CONSIST`` Aim long term consistent quota. ``DAMOS_QUOTA_GOAL_TUNER_TEMPORAL`` Aim zero quota asap.h](h)}(h **Constants**h]j)}(hjh]h Constants}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj7)}(hhh](j<)}(hC``DAMOS_QUOTA_GOAL_TUNER_CONSIST`` Aim long term consistent quota. h](jB)}(h"``DAMOS_QUOTA_GOAL_TUNER_CONSIST``h]h)}(hj h]hDAMOS_QUOTA_GOAL_TUNER_CONSIST}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(hAim long term consistent quota.h]hAim long term consistent quota.}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!hKhj"ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hj!hKhjubj<)}(h8``DAMOS_QUOTA_GOAL_TUNER_TEMPORAL`` Aim zero quota asap.h](jB)}(h#``DAMOS_QUOTA_GOAL_TUNER_TEMPORAL``h]h)}(hjEh]hDAMOS_QUOTA_GOAL_TUNER_TEMPORAL}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjCubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj?ubj\)}(hhh]h)}(hAim zero quota asap.h]hAim zero quota asap.}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj[ubah}(h]h ]h"]h$]h&]uh1j[hj?ubeh}(h]h ]h"]h$]h&]uh1j;hjZhKhjubeh}(h]h ]h"]h$]h&]uh1j6hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_quota (C struct) c.damos_quotahNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damos_quotah]jB)}(hstruct damos_quotah](jH)}(hjKh]hstruct}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKubjZ)}(h h]h }(hjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhjhKubjk)}(h damos_quotah]jq)}(hjh]h damos_quota}(hjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhjhKubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhjhKubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hjhKhjhhubj)}(hhh]h)}(h0Controls the aggressiveness of the given scheme.h]h0Controls the aggressiveness of the given scheme.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubah}(h]h ]h"]h$]h&]uh1jhjhhhjhKubeh}(h]h ](jstructeh"]h$]h&]jjjjjjjjjuh1j6hhhjhj5hNubj)}(hX**Definition**:: struct damos_quota { unsigned long reset_interval; unsigned long ms; unsigned long sz; enum damos_quota_goal_tuner goal_tuner; unsigned long esz; unsigned int fail_charge_num; unsigned int fail_charge_denom; unsigned int weight_sz; unsigned int weight_nr_accesses; unsigned int weight_age; }; **Members** ``reset_interval`` Charge reset interval in milliseconds. ``ms`` Maximum milliseconds that the scheme can use. ``sz`` Maximum bytes of memory that the action can be applied. ``goal_tuner`` Goal-based **esz** tuning algorithm to use. ``esz`` Effective size quota in bytes. ``fail_charge_num`` Failed regions charge rate numerator. ``fail_charge_denom`` Failed regions charge rate denominator. ``weight_sz`` Weight of the region's size for prioritization. ``weight_nr_accesses`` Weight of the region's nr_accesses for prioritization. ``weight_age`` Weight of the region's age for prioritization.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj)}(hXLstruct damos_quota { unsigned long reset_interval; unsigned long ms; unsigned long sz; enum damos_quota_goal_tuner goal_tuner; unsigned long esz; unsigned int fail_charge_num; unsigned int fail_charge_denom; unsigned int weight_sz; unsigned int weight_nr_accesses; unsigned int weight_age; };h]hXLstruct damos_quota { unsigned long reset_interval; unsigned long ms; unsigned long sz; enum damos_quota_goal_tuner goal_tuner; unsigned long esz; unsigned int fail_charge_num; unsigned int fail_charge_denom; unsigned int weight_sz; unsigned int weight_nr_accesses; unsigned int weight_age; };}hjsbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubh)}(h **Members**h]j)}(hj/h]hMembers}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj-ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj7)}(hhh](j<)}(h:``reset_interval`` Charge reset interval in milliseconds. h](jB)}(h``reset_interval``h]h)}(hjNh]hreset_interval}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjLubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjHubj\)}(hhh]h)}(h&Charge reset interval in milliseconds.h]h&Charge reset interval in milliseconds.}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1hhjchKhjdubah}(h]h ]h"]h$]h&]uh1j[hjHubeh}(h]h ]h"]h$]h&]uh1j;hjchKhjEubj<)}(h5``ms`` Maximum milliseconds that the scheme can use. h](jB)}(h``ms``h]h)}(hjh]hms}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h-Maximum milliseconds that the scheme can use.h]h-Maximum milliseconds that the scheme can use.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjEubj<)}(h?``sz`` Maximum bytes of memory that the action can be applied. h](jB)}(h``sz``h]h)}(hjh]hsz}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h7Maximum bytes of memory that the action can be applied.h]h7Maximum bytes of memory that the action can be applied.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjEubj<)}(h;``goal_tuner`` Goal-based **esz** tuning algorithm to use. h](jB)}(h``goal_tuner``h]h)}(hjh]h goal_tuner}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h+Goal-based **esz** tuning algorithm to use.h](h Goal-based }(hjhhhNhNubj)}(h**esz**h]hesz}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh tuning algorithm to use.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjEubj<)}(h'``esz`` Effective size quota in bytes. h](jB)}(h``esz``h]h)}(hjDh]hesz}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjBubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj>ubj\)}(hhh]h)}(hEffective size quota in bytes.h]hEffective size quota in bytes.}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjYhKhjZubah}(h]h ]h"]h$]h&]uh1j[hj>ubeh}(h]h ]h"]h$]h&]uh1j;hjYhKhjEubj<)}(h:``fail_charge_num`` Failed regions charge rate numerator. h](jB)}(h``fail_charge_num``h]h)}(hj}h]hfail_charge_num}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj{ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjwubj\)}(hhh]h)}(h%Failed regions charge rate numerator.h]h%Failed regions charge rate numerator.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjwubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjEubj<)}(h>``fail_charge_denom`` Failed regions charge rate denominator. h](jB)}(h``fail_charge_denom``h]h)}(hjh]hfail_charge_denom}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h'Failed regions charge rate denominator.h]h'Failed regions charge rate denominator.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjEubj<)}(h>``weight_sz`` Weight of the region's size for prioritization. h](jB)}(h ``weight_sz``h]h)}(hjh]h weight_sz}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubj\)}(hhh]h)}(h/Weight of the region's size for prioritization.h]h1Weight of the region’s size for prioritization.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhKhjEubj<)}(hN``weight_nr_accesses`` Weight of the region's nr_accesses for prioritization. h](jB)}(h``weight_nr_accesses``h]h)}(hj(h]hweight_nr_accesses}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj&ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj"ubj\)}(hhh]h)}(h6Weight of the region's nr_accesses for prioritization.h]h8Weight of the region’s nr_accesses for prioritization.}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj=hKhj>ubah}(h]h ]h"]h$]h&]uh1j[hj"ubeh}(h]h ]h"]h$]h&]uh1j;hj=hKhjEubj<)}(h=``weight_age`` Weight of the region's age for prioritization.h](jB)}(h``weight_age``h]h)}(hjah]h weight_age}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhj_ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj[ubj\)}(hhh]h)}(h.Weight of the region's age for prioritization.h]h0Weight of the region’s age for prioritization.}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjwubah}(h]h ]h"]h$]h&]uh1j[hj[ubeh}(h]h ]h"]h$]h&]uh1j;hjvhKhjEubeh}(h]h ]h"]h$]h&]uh1j6hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hXTo avoid consuming too much CPU time or IO resources for applying the :c:type:`struct damos `->action to large memory, DAMON allows users to set time and/or size quotas. The quotas can be set by writing non-zero values to :c:type:`ms` and :c:type:`sz`, respectively. If the time quota is set, DAMON tries to use only up to :c:type:`ms` milliseconds within :c:type:`reset_interval` for applying the action. If the size quota is set, DAMON tries to apply the action only up to :c:type:`sz` bytes within :c:type:`reset_interval`.h](hFTo avoid consuming too much CPU time or IO resources for applying the }(hjhhhNhNubh)}(h:c:type:`struct damos `h]h)}(hjh]h struct damos}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamosuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubh->action to large memory, DAMON allows users to set time and/or size quotas. The quotas can be set by writing non-zero values to }(hjhhhNhNubh)}(h :c:type:`ms`h]h)}(hjh]hms}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmsuh1hhjhKhjubh and }(hjhhhNhNubh)}(h :c:type:`sz`h]h)}(hj h]hsz}(hj hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjszuh1hhjhKhjubhI, respectively. If the time quota is set, DAMON tries to use only up to }(hjhhhNhNubh)}(h :c:type:`ms`h]h)}(hj.h]hms}(hj0hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj,ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmsuh1hhjhKhjubh milliseconds within }(hjhhhNhNubh)}(h:c:type:`reset_interval`h]h)}(hjQh]hreset_interval}(hjShhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjOubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjreset_intervaluh1hhjhKhjubh` for applying the action. If the size quota is set, DAMON tries to apply the action only up to }(hjhhhNhNubh)}(h :c:type:`sz`h]h)}(hjth]hsz}(hjvhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjrubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjszuh1hhjhKhjubh bytes within }(hjhhhNhNubh)}(h:c:type:`reset_interval`h]h)}(hjh]hreset_interval}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjreset_intervaluh1hhjhKhjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjhhubh)}(hTo 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.h]hTo 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.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjhhubh)}(hThe time quota is transformed to a size quota using estimated throughput of the scheme's action. DAMON then compares it against :c:type:`sz` and uses smaller one as the effective quota.h](hThe time quota is transformed to a size quota using estimated throughput of the scheme’s action. DAMON then compares it against }(hjhhhNhNubh)}(h :c:type:`sz`h]h)}(hjh]hsz}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjszuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjubh- and uses smaller one as the effective quota.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjhhubh)}(hXIf 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.h](hIf goals is not empty, DAMON calculates yet another size quota based on the goals using its internal feedback loop algorithm, for every }(hjhhhNhNubj)}(h**reset_interval**h]hreset_interval}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubhu. Then, if the new size quota is smaller than the effective quota, it uses the new size quota as the effective quota.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(h>The resulting effective size quota in bytes is set to **esz**.h](h6The resulting effective size quota in bytes is set to }(hj hhhNhNubj)}(h**esz**h]hesz}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubh.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hFor DAMOS action applying failed amount of regions, charging those same to those that the action has successfully applied may be unfair. For the reason, 'the size * **fail_charge_num** / **fail_charge_denom**' is charged.h](hFor DAMOS action applying failed amount of regions, charging those same to those that the action has successfully applied may be unfair. For the reason, ‘the size * }(hjAhhhNhNubj)}(h**fail_charge_num**h]hfail_charge_num}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAubh / }(hjAhhhNhNubj)}(h**fail_charge_denom**h]hfail_charge_denom}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAubh’ is charged.}(hjAhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hXvFor selecting regions within the quota, DAMON prioritizes current scheme's target memory regions using the :c:type:`struct damon_operations `->get_scheme_score. You could customize the prioritization logic by setting :c:type:`weight_sz`, :c:type:`weight_nr_accesses`, and :c:type:`weight_age`, because monitoring operations are encouraged to respect those.h](hmFor selecting regions within the quota, DAMON prioritizes current scheme’s target memory regions using the }(hjthhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj~h]hstruct damon_operations}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj|ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hjtubhL->get_scheme_score. You could customize the prioritization logic by setting }(hjthhhNhNubh)}(h:c:type:`weight_sz`h]h)}(hjh]h weight_sz}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj weight_szuh1hhjhM hjtubh, }(hjthhhNhNubh)}(h:c:type:`weight_nr_accesses`h]h)}(hjh]hweight_nr_accesses}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjweight_nr_accessesuh1hhjhM hjtubh, and }(hjthhhNhNubh)}(h:c:type:`weight_age`h]h)}(hjh]h weight_age}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj weight_ageuh1hhjhM hjtubh@, because monitoring operations are encouraged to respect those.}(hjthhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhM hjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_wmark_metric (C enum)c.damos_wmark_metrichNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_wmark_metrich]jB)}(henum damos_wmark_metrich](jH)}(hjh]henum}(hj(hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj$hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj6hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj$hhhj5hMubjk)}(hdamos_wmark_metrich]jq)}(hj"h]hdamos_wmark_metric}(hjHhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjDubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj$hhhj5hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj hhhj5hMubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hj5hMhjhhubj)}(hhh]h)}(h Represents the watermark metric.h]h Represents the watermark metric.}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM6hjghhubah}(h]h ]h"]h$]h&]uh1jhjhhhj5hMubeh}(h]h ](jenumeh"]h$]h&]jjjjjjjjjuh1j6hhhjhj5hNubj)}(h**Constants** ``DAMOS_WMARK_NONE`` Ignore the watermarks of the given scheme. ``DAMOS_WMARK_FREE_MEM_RATE`` Free memory rate of the system in [0,1000]. ``NR_DAMOS_WMARK_METRICS`` Total number of DAMOS watermark metricsh](h)}(h **Constants**h]j)}(hjh]h Constants}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM:hjubj7)}(hhh](j<)}(h@``DAMOS_WMARK_NONE`` Ignore the watermarks of the given scheme. h](jB)}(h``DAMOS_WMARK_NONE``h]h)}(hjh]hDAMOS_WMARK_NONE}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM=hjubj\)}(hhh]h)}(h*Ignore the watermarks of the given scheme.h]h*Ignore the watermarks of the given scheme.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM=hjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhM=hjubj<)}(hJ``DAMOS_WMARK_FREE_MEM_RATE`` Free memory rate of the system in [0,1000]. h](jB)}(h``DAMOS_WMARK_FREE_MEM_RATE``h]h)}(hjh]hDAMOS_WMARK_FREE_MEM_RATE}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM@hjubj\)}(hhh]h)}(h+Free memory rate of the system in [0,1000].h]h+Free memory rate of the system in [0,1000].}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM@hjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhM@hjubj<)}(hB``NR_DAMOS_WMARK_METRICS`` Total number of DAMOS watermark metricsh](jB)}(h``NR_DAMOS_WMARK_METRICS``h]h)}(hjh]hNR_DAMOS_WMARK_METRICS}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMBhjubj\)}(hhh]h)}(h'Total number of DAMOS watermark metricsh]h'Total number of DAMOS watermark metrics}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMChj3ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hj2hMBhjubeh}(h]h ]h"]h$]h&]uh1j6hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_watermarks (C struct)c.damos_watermarkshNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_watermarksh]jB)}(hstruct damos_watermarksh](jH)}(hjKh]hstruct}(hjwhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjshhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMHubjZ)}(h h]h }(hjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjshhhjhMHubjk)}(hdamos_watermarksh]jq)}(hjqh]hdamos_watermarks}(hjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjshhhjhMHubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjohhhjhMHubah}(h]jjah ](jjeh"]h$]h&]jj)jhuh1j;hjhMHhjlhhubj)}(hhh]h)}(h1Controls when a given scheme should be activated.h]h1Controls when a given scheme should be activated.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMChjhhubah}(h]h ]h"]h$]h&]uh1jhjlhhhjhMHubeh}(h]h ](jstructeh"]h$]h&]jjjjjjjjjuh1j6hhhjhj5hNubj)}(hX**Definition**:: struct damos_watermarks { enum damos_wmark_metric metric; unsigned long interval; unsigned long high; unsigned long mid; unsigned long low; }; **Members** ``metric`` Metric for the watermarks. ``interval`` Watermarks check time interval in microseconds. ``high`` High watermark. ``mid`` Middle watermark. ``low`` Low watermark.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMGhjubj)}(hstruct damos_watermarks { enum damos_wmark_metric metric; unsigned long interval; unsigned long high; unsigned long mid; unsigned long low; };h]hstruct damos_watermarks { enum damos_wmark_metric metric; unsigned long interval; unsigned long high; unsigned long mid; unsigned long low; };}hjsbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMIhjubh)}(h **Members**h]j)}(hjh]hMembers}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMQhjubj7)}(hhh](j<)}(h&``metric`` Metric for the watermarks. h](jB)}(h ``metric``h]h)}(hj&h]hmetric}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMEhj ubj\)}(hhh]h)}(hMetric for the watermarks.h]hMetric for the watermarks.}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj;hMEhj<ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj;hMEhjubj<)}(h=``interval`` Watermarks check time interval in microseconds. h](jB)}(h ``interval``h]h)}(hj_h]hinterval}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1hhj]ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMFhjYubj\)}(hhh]h)}(h/Watermarks check time interval in microseconds.h]h/Watermarks check time interval in microseconds.}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjthMFhjuubah}(h]h ]h"]h$]h&]uh1j[hjYubeh}(h]h ]h"]h$]h&]uh1j;hjthMFhjubj<)}(h``high`` High watermark. h](jB)}(h``high``h]h)}(hjh]hhigh}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMGhjubj\)}(hhh]h)}(hHigh watermark.h]hHigh watermark.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMGhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhMGhjubj<)}(h``mid`` Middle watermark. h](jB)}(h``mid``h]h)}(hjh]hmid}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMHhjubj\)}(hhh]h)}(hMiddle watermark.h]hMiddle watermark.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMHhjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhMHhjubj<)}(h``low`` Low watermark.h](jB)}(h``low``h]h)}(hj h]hlow}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMHhjubj\)}(hhh]h)}(hLow watermark.h]hLow watermark.}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMIhj ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhMHhjubeh}(h]h ]h"]h$]h&]uh1j6hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjMh]h Description}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjKubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMLhjhhubh)}(hX8If :c:type:`metric` is :c:type:`DAMOS_WMARK_NONE`, the scheme is always active. Being active means DAMON does monitoring and applying the action of the scheme to appropriate memory regions. Else, DAMON checks :c:type:`metric` of the system for at least every :c:type:`interval` microseconds and works as below.h](hIf }(hjchhhNhNubh)}(h:c:type:`metric`h]h)}(hjmh]hmetric}(hjohhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjkubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmetricuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMIhjcubh is }(hjchhhNhNubh)}(h:c:type:`DAMOS_WMARK_NONE`h]h)}(hjh]hDAMOS_WMARK_NONE}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjDAMOS_WMARK_NONEuh1hhjhMIhjcubh, the scheme is always active. Being active means DAMON does monitoring and applying the action of the scheme to appropriate memory regions. Else, DAMON checks }(hjchhhNhNubh)}(h:c:type:`metric`h]h)}(hjh]hmetric}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmetricuh1hhjhMIhjcubh" of the system for at least every }(hjchhhNhNubh)}(h:c:type:`interval`h]h)}(hjh]hinterval}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjintervaluh1hhjhMIhjcubh! microseconds and works as below.}(hjchhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMIhjhhubh)}(hIf :c:type:`metric` is higher than :c:type:`high`, the scheme is inactivated. If :c:type:`metric` is between :c:type:`mid` and :c:type:`low`, the scheme is activated. If :c:type:`metric` is lower than :c:type:`low`, the scheme is inactivated.h](hIf }(hjhhhNhNubh)}(h:c:type:`metric`h]h)}(hjh]hmetric}(hj hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmetricuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMNhjubh is higher than }(hjhhhNhNubh)}(h:c:type:`high`h]h)}(hj,h]hhigh}(hj.hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj*ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjhighuh1hhj%hMNhjubh!, the scheme is inactivated. If }(hjhhhNhNubh)}(h:c:type:`metric`h]h)}(hjOh]hmetric}(hjQhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjMubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmetricuh1hhj%hMNhjubh is between }(hjhhhNhNubh)}(h :c:type:`mid`h]h)}(hjrh]hmid}(hjthhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjpubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmiduh1hhj%hMNhjubh and }(hjhhhNhNubh)}(h :c:type:`low`h]h)}(hjh]hlow}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjlowuh1hhj%hMNhjubh, the scheme is activated. If }(hjhhhNhNubh)}(h:c:type:`metric`h]h)}(hjh]hmetric}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmetricuh1hhj%hMNhjubh is lower than }(hjhhhNhNubh)}(h :c:type:`low`h]h)}(hjh]hlow}(hjhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjlowuh1hhj%hMNhjubh, the scheme is inactivated.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj%hMNhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_stat (C struct) c.damos_stathNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damos_stath]jB)}(hstruct damos_stath](jH)}(hjKh]hstruct}(hjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMUubjZ)}(h h]h }(hj)hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhj(hMUubjk)}(h damos_stath]jq)}(hjh]h damos_stat}(hj;hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj7ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhj(hMUubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhj(hMUubah}(h]jah ](jjeh"]h$]h&]jj)jhuh1j;hj(hMUhjhhubj)}(hhh]h)}(hStatistics on a given scheme.h]hStatistics on a given scheme.}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM_hjZhhubah}(h]h ]h"]h$]h&]uh1jhjhhhj(hMUubeh}(h]h ](jstructeh"]h$]h&]jjjjujjujjjuh1j6hhhjhj5hNubj)}(hX;**Definition**:: struct damos_stat { unsigned long nr_tried; unsigned long sz_tried; unsigned long nr_applied; unsigned long sz_applied; unsigned long sz_ops_filter_passed; unsigned long qt_exceeds; unsigned long nr_snapshots; }; **Members** ``nr_tried`` Total number of regions that the scheme is tried to be applied. ``sz_tried`` Total size of regions that the scheme is tried to be applied. ``nr_applied`` Total number of regions that the scheme is applied. ``sz_applied`` Total size of regions that the scheme is applied. ``sz_ops_filter_passed`` Total bytes that passed ops layer-handled DAMOS filters. ``qt_exceeds`` Total number of times the quota of the scheme has exceeded. ``nr_snapshots`` Total number of DAMON snapshots that the scheme has tried.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj}ubh:}(hj}hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMchjyubj)}(hstruct damos_stat { unsigned long nr_tried; unsigned long sz_tried; unsigned long nr_applied; unsigned long sz_applied; unsigned long sz_ops_filter_passed; unsigned long qt_exceeds; unsigned long nr_snapshots; };h]hstruct damos_stat { unsigned long nr_tried; unsigned long sz_tried; unsigned long nr_applied; unsigned long sz_applied; unsigned long sz_ops_filter_passed; unsigned long qt_exceeds; unsigned long nr_snapshots; };}hjsbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMehjyubh)}(h **Members**h]j)}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMohjyubj7)}(hhh](j<)}(hM``nr_tried`` Total number of regions that the scheme is tried to be applied. h](jB)}(h ``nr_tried``h]h)}(hjh]hnr_tried}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMahjubj\)}(hhh]h)}(h?Total number of regions that the scheme is tried to be applied.h]h?Total number of regions that the scheme is tried to be applied.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMahjubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hjhMahjubj<)}(hK``sz_tried`` Total size of regions that the scheme is tried to be applied. h](jB)}(h ``sz_tried``h]h)}(hj h]hsz_tried}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMbhjubj\)}(hhh]h)}(h=Total size of regions that the scheme is tried to be applied.h]h=Total size of regions that the scheme is tried to be applied.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMbhj ubah}(h]h ]h"]h$]h&]uh1j[hjubeh}(h]h ]h"]h$]h&]uh1j;hj hMbhjubj<)}(hC``nr_applied`` Total number of regions that the scheme is applied. h](jB)}(h``nr_applied``h]h)}(hj< h]h nr_applied}(hj> hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj: ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMchj6 ubj\)}(hhh]h)}(h3Total number of regions that the scheme is applied.h]h3Total number of regions that the scheme is applied.}(hjU hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjQ hMchjR ubah}(h]h ]h"]h$]h&]uh1j[hj6 ubeh}(h]h ]h"]h$]h&]uh1j;hjQ hMchjubj<)}(hA``sz_applied`` Total size of regions that the scheme is applied. h](jB)}(h``sz_applied``h]h)}(hju h]h sz_applied}(hjw hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjs ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMdhjo ubj\)}(hhh]h)}(h1Total size of regions that the scheme is applied.h]h1Total size of regions that the scheme is applied.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMdhj ubah}(h]h ]h"]h$]h&]uh1j[hjo ubeh}(h]h ]h"]h$]h&]uh1j;hj hMdhjubj<)}(hR``sz_ops_filter_passed`` Total bytes that passed ops layer-handled DAMOS filters. h](jB)}(h``sz_ops_filter_passed``h]h)}(hj h]hsz_ops_filter_passed}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMehj ubj\)}(hhh]h)}(h8Total bytes that passed ops layer-handled DAMOS filters.h]h8Total bytes that passed ops layer-handled DAMOS filters.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMehj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hMehjubj<)}(hK``qt_exceeds`` Total number of times the quota of the scheme has exceeded. h](jB)}(h``qt_exceeds``h]h)}(hj h]h qt_exceeds}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMghj ubj\)}(hhh]h)}(h;Total number of times the quota of the scheme has exceeded.h]h;Total number of times the quota of the scheme has exceeded.}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMghj ubah}(h]h ]h"]h$]h&]uh1j[hj ubeh}(h]h ]h"]h$]h&]uh1j;hj hMghjubj<)}(hK``nr_snapshots`` Total number of DAMON snapshots that the scheme has tried.h](jB)}(h``nr_snapshots``h]h)}(hj !h]h nr_snapshots}(hj"!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMghj!ubj\)}(hhh]h)}(h:Total number of DAMON snapshots that the scheme has tried.h]h:Total number of DAMON snapshots that the scheme has tried.}(hj9!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhhj6!ubah}(h]h ]h"]h$]h&]uh1j[hj!ubeh}(h]h ]h"]h$]h&]uh1j;hj5!hMghjubeh}(h]h ]h"]h$]h&]uh1j6hjyubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hjc!h]h Description}(hje!hhhNhNubah}(h]h ]h"]h$]h&]uh1jhja!ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMkhjhhubh)}(hX2"Tried an action to a region" in this context means the DAMOS core logic determined the region as eligible to apply the action. The access pattern (:c:type:`struct damos_access_pattern `), quotas (:c:type:`struct damos_quota `), watermarks (:c:type:`struct damos_watermarks `) and filters (:c:type:`struct damos_filter `) that handled on core logic can affect this. The core logic asks the operation set (:c:type:`struct damon_operations `) to apply the action to the region.h](h“Tried an action to a region” in this context means the DAMOS core logic determined the region as eligible to apply the action. The access pattern (}(hjy!hhhNhNubh)}(h<:c:type:`struct damos_access_pattern `h]h)}(hj!h]hstruct damos_access_pattern}(hj!hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj!ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamos_access_patternuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMihjy!ubh ), quotas (}(hjy!hhhNhNubh)}(h*:c:type:`struct damos_quota `h]h)}(hj!h]hstruct damos_quota}(hj!hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj!ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damos_quotauh1hhj!hMihjy!ubh), watermarks (}(hjy!hhhNhNubh)}(h4:c:type:`struct damos_watermarks `h]h)}(hj!h]hstruct damos_watermarks}(hj!hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj!ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamos_watermarksuh1hhj!hMihjy!ubh) and filters (}(hjy!hhhNhNubh)}(h,:c:type:`struct damos_filter `h]h)}(hj!h]hstruct damos_filter}(hj!hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj!ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damos_filteruh1hhj!hMihjy!ubhV) that handled on core logic can affect this. The core logic asks the operation set (}(hjy!hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj"h]hstruct damon_operations}(hj"hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj"ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhj!hMihjy!ubh$) to apply the action to the region.}(hjy!hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj!hMihjhhubh)}(hX"Applied an action to a region" in this context means the operation set (:c:type:`struct damon_operations `) successfully applied the action to the region, at least to a part of the region. The filters (:c:type:`struct damos_filter `) that handled on operation set layer and type of the action and pages of the region can affect this. For example, if a filter is set to exclude anonymous pages and the region has only anonymous pages, the region will be failed at applying the action. If the action is :c:type:`DAMOS_PAGEOUT` and all pages of the region are already paged out, the region will be failed at applying the action.h](hM“Applied an action to a region” in this context means the operation set (}(hj7"hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hjA"h]hstruct damon_operations}(hjC"hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj?"ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMphj7"ubha) successfully applied the action to the region, at least to a part of the region. The filters (}(hj7"hhhNhNubh)}(h,:c:type:`struct damos_filter `h]h)}(hje"h]hstruct damos_filter}(hjg"hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjc"ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damos_filteruh1hhj^"hMphj7"ubhX) that handled on operation set layer and type of the action and pages of the region can affect this. For example, if a filter is set to exclude anonymous pages and the region has only anonymous pages, the region will be failed at applying the action. If the action is }(hj7"hhhNhNubh)}(h:c:type:`DAMOS_PAGEOUT`h]h)}(hj"h]h DAMOS_PAGEOUT}(hj"hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj"ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj DAMOS_PAGEOUTuh1hhj^"hMphj7"ubhe and all pages of the region are already paged out, the region will be failed at applying the action.}(hj7"hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj^"hMphjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_filter_type (C enum)c.damos_filter_typehNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_filter_typeh]jB)}(henum damos_filter_typeh](jH)}(hjh]henum}(hj"hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj"hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM}ubjZ)}(h h]h }(hj"hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj"hhhj"hM}ubjk)}(hdamos_filter_typeh]jq)}(hj"h]hdamos_filter_type}(hj"hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj"ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj"hhhj"hM}ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj"hhhj"hM}ubah}(h]j"ah ](jjeh"]h$]h&]jj)jhuh1j;hj"hM}hj"hhubj)}(hhh]h)}(h?Type of memory for :c:type:`struct damos_filter `h](hType of memory for }(hj #hhhNhNubh)}(h,:c:type:`struct damos_filter `h]h)}(hj#h]hstruct damos_filter}(hj#hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj#ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjj)}j]j ASTIdentifier)} identifierj"sbc.damos_filter_typeasbj damos_filteruh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj #ubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj#hhubah}(h]h ]h"]h$]h&]uh1jhj"hhhj"hM}ubeh}(h]h ](jenumeh"]h$]h&]jjjjL#jjL#jjjuh1j6hhhjhj5hNubj)}(hX**Constants** ``DAMOS_FILTER_TYPE_ANON`` Anonymous pages. ``DAMOS_FILTER_TYPE_ACTIVE`` Active pages. ``DAMOS_FILTER_TYPE_MEMCG`` Specific memcg's pages. ``DAMOS_FILTER_TYPE_YOUNG`` Recently accessed pages. ``DAMOS_FILTER_TYPE_HUGEPAGE_SIZE`` Page is part of a hugepage. ``DAMOS_FILTER_TYPE_UNMAPPED`` Unmapped pages. ``DAMOS_FILTER_TYPE_ADDR`` Address range. ``DAMOS_FILTER_TYPE_TARGET`` Data Access Monitoring target. ``NR_DAMOS_FILTER_TYPES`` Number of filter types.h](h)}(h **Constants**h]j)}(hjV#h]h Constants}(hjX#hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjT#ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjP#ubj7)}(hhh](j<)}(h,``DAMOS_FILTER_TYPE_ANON`` Anonymous pages. h](jB)}(h``DAMOS_FILTER_TYPE_ANON``h]h)}(hju#h]hDAMOS_FILTER_TYPE_ANON}(hjw#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjs#ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjo#ubj\)}(hhh]h)}(hAnonymous pages.h]hAnonymous pages.}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj#hMhj#ubah}(h]h ]h"]h$]h&]uh1j[hjo#ubeh}(h]h ]h"]h$]h&]uh1j;hj#hMhjl#ubj<)}(h+``DAMOS_FILTER_TYPE_ACTIVE`` Active pages. h](jB)}(h``DAMOS_FILTER_TYPE_ACTIVE``h]h)}(hj#h]hDAMOS_FILTER_TYPE_ACTIVE}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj#ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj#ubj\)}(hhh]h)}(h Active pages.h]h Active pages.}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj#hMhj#ubah}(h]h ]h"]h$]h&]uh1j[hj#ubeh}(h]h ]h"]h$]h&]uh1j;hj#hMhjl#ubj<)}(h4``DAMOS_FILTER_TYPE_MEMCG`` Specific memcg's pages. h](jB)}(h``DAMOS_FILTER_TYPE_MEMCG``h]h)}(hj#h]hDAMOS_FILTER_TYPE_MEMCG}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj#ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj#ubj\)}(hhh]h)}(hSpecific memcg's pages.h]hSpecific memcg’s pages.}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj#hMhj#ubah}(h]h ]h"]h$]h&]uh1j[hj#ubeh}(h]h ]h"]h$]h&]uh1j;hj#hMhjl#ubj<)}(h5``DAMOS_FILTER_TYPE_YOUNG`` Recently accessed pages. h](jB)}(h``DAMOS_FILTER_TYPE_YOUNG``h]h)}(hj $h]hDAMOS_FILTER_TYPE_YOUNG}(hj"$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj$ubj\)}(hhh]h)}(hRecently accessed pages.h]hRecently accessed pages.}(hj9$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5$hMhj6$ubah}(h]h ]h"]h$]h&]uh1j[hj$ubeh}(h]h ]h"]h$]h&]uh1j;hj5$hMhjl#ubj<)}(h@``DAMOS_FILTER_TYPE_HUGEPAGE_SIZE`` Page is part of a hugepage. h](jB)}(h#``DAMOS_FILTER_TYPE_HUGEPAGE_SIZE``h]h)}(hjY$h]hDAMOS_FILTER_TYPE_HUGEPAGE_SIZE}(hj[$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjW$ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjS$ubj\)}(hhh]h)}(hPage is part of a hugepage.h]hPage is part of a hugepage.}(hjr$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjn$hMhjo$ubah}(h]h ]h"]h$]h&]uh1j[hjS$ubeh}(h]h ]h"]h$]h&]uh1j;hjn$hMhjl#ubj<)}(h/``DAMOS_FILTER_TYPE_UNMAPPED`` Unmapped pages. h](jB)}(h``DAMOS_FILTER_TYPE_UNMAPPED``h]h)}(hj$h]hDAMOS_FILTER_TYPE_UNMAPPED}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj$ubj\)}(hhh]h)}(hUnmapped pages.h]hUnmapped pages.}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$hMhj$ubah}(h]h ]h"]h$]h&]uh1j[hj$ubeh}(h]h ]h"]h$]h&]uh1j;hj$hMhjl#ubj<)}(h*``DAMOS_FILTER_TYPE_ADDR`` Address range. h](jB)}(h``DAMOS_FILTER_TYPE_ADDR``h]h)}(hj$h]hDAMOS_FILTER_TYPE_ADDR}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj$ubj\)}(hhh]h)}(hAddress range.h]hAddress range.}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$hMhj$ubah}(h]h ]h"]h$]h&]uh1j[hj$ubeh}(h]h ]h"]h$]h&]uh1j;hj$hMhjl#ubj<)}(h<``DAMOS_FILTER_TYPE_TARGET`` Data Access Monitoring target. h](jB)}(h``DAMOS_FILTER_TYPE_TARGET``h]h)}(hj%h]hDAMOS_FILTER_TYPE_TARGET}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj$ubj\)}(hhh]h)}(hData Access Monitoring target.h]hData Access Monitoring target.}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%hMhj%ubah}(h]h ]h"]h$]h&]uh1j[hj$ubeh}(h]h ]h"]h$]h&]uh1j;hj%hMhjl#ubj<)}(h1``NR_DAMOS_FILTER_TYPES`` Number of filter types.h](jB)}(h``NR_DAMOS_FILTER_TYPES``h]h)}(hj=%h]hNR_DAMOS_FILTER_TYPES}(hj?%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj;%ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj7%ubj\)}(hhh]h)}(hNumber of filter types.h]hNumber of filter types.}(hjV%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjS%ubah}(h]h ]h"]h$]h&]uh1j[hj7%ubeh}(h]h ]h"]h$]h&]uh1j;hjR%hMhjl#ubeh}(h]h ]h"]h$]h&]uh1j6hjP#ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj%h]h Description}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj~%ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hXAll types except :c:type:`DAMOS_FILTER_TYPE_ADDR` and :c:type:`DAMOS_FILTER_TYPE_TARGET` are handled by the underlying :c:type:`struct damon_operations ` as a part of scheme action trying, and therefore accounted as 'tried'. In contrast, :c:type:`DAMOS_FILTER_TYPE_ADDR` and :c:type:`DAMOS_FILTER_TYPE_TARGET` filters are handled by the core layer before trying of the action, and therefore not accounted as 'tried'.h](hAll types except }(hj%hhhNhNubh)}(h :c:type:`DAMOS_FILTER_TYPE_ADDR`h]h)}(hj%h]hDAMOS_FILTER_TYPE_ADDR}(hj%hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjDAMOS_FILTER_TYPE_ADDRuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj%ubh and }(hj%hhhNhNubh)}(h":c:type:`DAMOS_FILTER_TYPE_TARGET`h]h)}(hj%h]hDAMOS_FILTER_TYPE_TARGET}(hj%hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjDAMOS_FILTER_TYPE_TARGETuh1hhj%hMhj%ubh are handled by the underlying }(hj%hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj%h]hstruct damon_operations}(hj%hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhj%hMhj%ubhZ as a part of scheme action trying, and therefore accounted as ‘tried’. In contrast, }(hj%hhhNhNubh)}(h :c:type:`DAMOS_FILTER_TYPE_ADDR`h]h)}(hj &h]hDAMOS_FILTER_TYPE_ADDR}(hj &hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj&ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjDAMOS_FILTER_TYPE_ADDRuh1hhj%hMhj%ubh and }hj%sbh)}(h":c:type:`DAMOS_FILTER_TYPE_TARGET`h]h)}(hj-&h]hDAMOS_FILTER_TYPE_TARGET}(hj/&hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj+&ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjDAMOS_FILTER_TYPE_TARGETuh1hhj%hMhj%ubho filters are handled by the core layer before trying of the action, and therefore not accounted as ‘tried’.}(hj%hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj%hMhjhhubh)}(hwSupport for the operations-handled filters depends on the running :c:type:`struct damon_operations `.h](hBSupport for the operations-handled filters depends on the running }(hjT&hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj^&h]hstruct damon_operations}(hj`&hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj\&ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjT&ubh.}(hjT&hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj{&hMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_filter (C struct)c.damos_filterhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damos_filterh]jB)}(hstruct damos_filterh](jH)}(hjKh]hstruct}(hj&hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj&hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj&hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj&hhhj&hMubjk)}(h damos_filterh]jq)}(hj&h]h damos_filter}(hj&hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj&ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj&hhhj&hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj&hhhj&hMubah}(h]j&ah ](jjeh"]h$]h&]jj)jhuh1j;hj&hMhj&hhubj)}(hhh]h)}(h"DAMOS action target memory filter.h]h"DAMOS action target memory filter.}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj&hhubah}(h]h ]h"]h$]h&]uh1jhj&hhhj&hMubeh}(h]h ](jstructeh"]h$]h&]jjjj&jj&jjjuh1j6hhhjhj5hNubj)}(hX~**Definition**:: struct damos_filter { enum damos_filter_type type; bool matching; bool allow; union { u64 memcg_id; struct damon_addr_range addr_range; int target_idx; struct damon_size_range sz_range; }; }; **Members** ``type`` Type of the target memory. ``matching`` Whether this is for **type**-matching memory. ``allow`` Whether to include or exclude the **matching** memory. ``{unnamed_union}`` anonymous ``memcg_id`` Memcg id of the question if **type** is DAMOS_FILTER_MEMCG. ``addr_range`` Address range if **type** is DAMOS_FILTER_TYPE_ADDR. ``target_idx`` Index of the :c:type:`struct damon_target ` of :c:type:`damon_ctx->adaptive_targets ` if **type** is DAMOS_FILTER_TYPE_TARGET. ``sz_range`` Size range if **type** is DAMOS_FILTER_TYPE_HUGEPAGE_SIZE.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj'ubh:}(hj'hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj&ubj)}(hstruct damos_filter { enum damos_filter_type type; bool matching; bool allow; union { u64 memcg_id; struct damon_addr_range addr_range; int target_idx; struct damon_size_range sz_range; }; };h]hstruct damos_filter { enum damos_filter_type type; bool matching; bool allow; union { u64 memcg_id; struct damon_addr_range addr_range; int target_idx; struct damon_size_range sz_range; }; };}hj'sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj&ubh)}(h **Members**h]j)}(hj/'h]hMembers}(hj1'hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj-'ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj&ubj7)}(hhh](j<)}(h$``type`` Type of the target memory. h](jB)}(h``type``h]h)}(hjN'h]htype}(hjP'hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjL'ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjH'ubj\)}(hhh]h)}(hType of the target memory.h]hType of the target memory.}(hjg'hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjc'hMhjd'ubah}(h]h ]h"]h$]h&]uh1j[hjH'ubeh}(h]h ]h"]h$]h&]uh1j;hjc'hMhjE'ubj<)}(h;``matching`` Whether this is for **type**-matching memory. h](jB)}(h ``matching``h]h)}(hj'h]hmatching}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj'ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj'ubj\)}(hhh]h)}(h-Whether this is for **type**-matching memory.h](hWhether this is for }(hj'hhhNhNubj)}(h**type**h]htype}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj'ubh-matching memory.}(hj'hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj'hMhj'ubah}(h]h ]h"]h$]h&]uh1j[hj'ubeh}(h]h ]h"]h$]h&]uh1j;hj'hMhjE'ubj<)}(hA``allow`` Whether to include or exclude the **matching** memory. h](jB)}(h ``allow``h]h)}(hj'h]hallow}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj'ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj'ubj\)}(hhh]h)}(h6Whether to include or exclude the **matching** memory.h](h"Whether to include or exclude the }(hj'hhhNhNubj)}(h **matching**h]hmatching}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj'ubh memory.}(hj'hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj'hMhj'ubah}(h]h ]h"]h$]h&]uh1j[hj'ubeh}(h]h ]h"]h$]h&]uh1j;hj'hMhjE'ubj<)}(h``{unnamed_union}`` anonymous h](jB)}(h``{unnamed_union}``h]h)}(hj(h]h{unnamed_union}}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj(ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj(ubj\)}(hhh]h)}(h anonymoush]h anonymous}(hj6(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj2(hKhj3(ubah}(h]h ]h"]h$]h&]uh1j[hj(ubeh}(h]h ]h"]h$]h&]uh1j;hj2(hKhjE'ubj<)}(hI``memcg_id`` Memcg id of the question if **type** is DAMOS_FILTER_MEMCG. h](jB)}(h ``memcg_id``h]h)}(hjV(h]hmemcg_id}(hjX(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjT(ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjP(ubj\)}(hhh]h)}(h;Memcg id of the question if **type** is DAMOS_FILTER_MEMCG.h](hMemcg id of the question if }(hjo(hhhNhNubj)}(h**type**h]htype}(hjw(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjo(ubh is DAMOS_FILTER_MEMCG.}(hjo(hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjk(hMhjl(ubah}(h]h ]h"]h$]h&]uh1j[hjP(ubeh}(h]h ]h"]h$]h&]uh1j;hjk(hMhjE'ubj<)}(hD``addr_range`` Address range if **type** is DAMOS_FILTER_TYPE_ADDR. h](jB)}(h``addr_range``h]h)}(hj(h]h addr_range}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj(ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj(ubj\)}(hhh]h)}(h4Address range if **type** is DAMOS_FILTER_TYPE_ADDR.h](hAddress range if }(hj(hhhNhNubj)}(h**type**h]htype}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(ubh is DAMOS_FILTER_TYPE_ADDR.}(hj(hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj(hMhj(ubah}(h]h ]h"]h$]h&]uh1j[hj(ubeh}(h]h ]h"]h$]h&]uh1j;hj(hMhjE'ubj<)}(h``target_idx`` Index of the :c:type:`struct damon_target ` of :c:type:`damon_ctx->adaptive_targets ` if **type** is DAMOS_FILTER_TYPE_TARGET. h](jB)}(h``target_idx``h]h)}(hj(h]h target_idx}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj(ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj(ubj\)}(hhh]h)}(hIndex of the :c:type:`struct damon_target ` of :c:type:`damon_ctx->adaptive_targets ` if **type** is DAMOS_FILTER_TYPE_TARGET.h](h Index of the }(hj)hhhNhNubh)}(h,:c:type:`struct damon_target `h]h)}(hj)h]hstruct damon_target}(hj)hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj )ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_targetuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj)ubh of }(hj)hhhNhNubh)}(h1:c:type:`damon_ctx->adaptive_targets `h]h)}(hj3)h]hdamon_ctx->adaptive_targets}(hj5)hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj1)ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_ctxuh1hhj,)hMhj)ubh if }(hj)hhhNhNubj)}(h**type**h]htype}(hjT)hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)ubh is DAMOS_FILTER_TYPE_TARGET.}(hj)hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj,)hMhj)ubah}(h]h ]h"]h$]h&]uh1j[hj(ubeh}(h]h ]h"]h$]h&]uh1j;hj)hMhjE'ubj<)}(hG``sz_range`` Size range if **type** is DAMOS_FILTER_TYPE_HUGEPAGE_SIZE.h](jB)}(h ``sz_range``h]h)}(hj~)h]hsz_range}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj|)ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjx)ubj\)}(hhh]h)}(h:Size range if **type** is DAMOS_FILTER_TYPE_HUGEPAGE_SIZE.h](hSize range if }(hj)hhhNhNubj)}(h**type**h]htype}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)ubh$ is DAMOS_FILTER_TYPE_HUGEPAGE_SIZE.}(hj)hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj)ubah}(h]h ]h"]h$]h&]uh1j[hjx)ubeh}(h]h ]h"]h$]h&]uh1j;hj)hMhjE'ubeh}(h]h ]h"]h$]h&]uh1j6hj&ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj)h]h Description}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hX|Before applying the :c:type:`damos->action ` to a memory region, DAMOS checks if each byte of the region matches to this given condition and avoid applying the action if so. Support of each filter type depends on the running :c:type:`struct damon_operations ` and the type. Refer to :c:type:`enum damos_filter_type ` for more details.h](hBefore applying the }(hj)hhhNhNubh)}(h:c:type:`damos->action `h]h)}(hj)h]h damos->action}(hj)hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj)ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamosuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj)ubh to a memory region, DAMOS checks if each byte of the region matches to this given condition and avoid applying the action if so. Support of each filter type depends on the running }(hj)hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj*h]hstruct damon_operations}(hj*hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj*ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhj*hMhj)ubh and the type. Refer to }(hj)hhhNhNubh)}(h4:c:type:`enum damos_filter_type `h]h)}(hj:*h]henum damos_filter_type}(hj<*hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj8*ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamos_filter_typeuh1hhj*hMhj)ubh for more details.}(hj)hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj*hMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_walk_control (C struct)c.damos_walk_controlhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_walk_controlh]jB)}(hstruct damos_walk_controlh](jH)}(hjKh]hstruct}(hjz*hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjv*hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj*hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjv*hhhj*hMubjk)}(hdamos_walk_controlh]jq)}(hjt*h]hdamos_walk_control}(hj*hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj*ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjv*hhhj*hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjr*hhhj*hMubah}(h]jm*ah ](jjeh"]h$]h&]jj)jhuh1j;hj*hMhjo*hhubj)}(hhh]h)}(hControl damos_walk().h]hControl damos_walk().}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj*hhubah}(h]h ]h"]h$]h&]uh1jhjo*hhhj*hMubeh}(h]h ](jstructeh"]h$]h&]jjjj*jj*jjjuh1j6hhhjhj5hNubj)}(hXa**Definition**:: struct damos_walk_control { void (*walk_fn)(void *data, struct damon_ctx *ctx, struct damon_target *t, struct damon_region *r, struct damos *s, unsigned long sz_filter_passed); void *data; }; **Members** ``walk_fn`` Function to be called back for each region. ``data`` Data that will be passed to walk functions.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*ubh:}(hj*hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj*ubj)}(hstruct damos_walk_control { void (*walk_fn)(void *data, struct damon_ctx *ctx, struct damon_target *t, struct damon_region *r, struct damos *s, unsigned long sz_filter_passed); void *data; };h]hstruct damos_walk_control { void (*walk_fn)(void *data, struct damon_ctx *ctx, struct damon_target *t, struct damon_region *r, struct damos *s, unsigned long sz_filter_passed); void *data; };}hj*sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj*ubh)}(h **Members**h]j)}(hj +h]hMembers}(hj +hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj*ubj7)}(hhh](j<)}(h8``walk_fn`` Function to be called back for each region. h](jB)}(h ``walk_fn``h]h)}(hj)+h]hwalk_fn}(hj++hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj'+ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj#+ubj\)}(hhh]h)}(h+Function to be called back for each region.h]h+Function to be called back for each region.}(hjB+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj>+hMhj?+ubah}(h]h ]h"]h$]h&]uh1j[hj#+ubeh}(h]h ]h"]h$]h&]uh1j;hj>+hMhj +ubj<)}(h4``data`` Data that will be passed to walk functions.h](jB)}(h``data``h]h)}(hjb+h]hdata}(hjd+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj`+ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj\+ubj\)}(hhh]h)}(h+Data that will be passed to walk functions.h]h+Data that will be passed to walk functions.}(hj{+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjx+ubah}(h]h ]h"]h$]h&]uh1j[hj\+ubeh}(h]h ]h"]h$]h&]uh1j;hjw+hMhj +ubeh}(h]h ]h"]h$]h&]uh1j6hj*ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj+h]h Description}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hControl damos_walk(), which requests specific kdamond to invoke the given function to each region that eligible to apply actions of the kdamond's schemes. Refer to damos_walk() for more details.h]hControl damos_walk(), which requests specific kdamond to invoke the given function to each region that eligible to apply actions of the kdamond’s schemes. Refer to damos_walk() for more details.}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_access_pattern (C struct)c.damos_access_patternhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_access_patternh]jB)}(hstruct damos_access_patternh](jH)}(hjKh]hstruct}(hj+hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj+hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj+hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj+hhhj+hMubjk)}(hdamos_access_patternh]jq)}(hj+h]hdamos_access_pattern}(hj,hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj+ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj+hhhj+hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj+hhhj+hMubah}(h]j+ah ](jjeh"]h$]h&]jj)jhuh1j;hj+hMhj+hhubj)}(hhh]h)}(h*Target access pattern of the given scheme.h]h*Target access pattern of the given scheme.}(hj%,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj",hhubah}(h]h ]h"]h$]h&]uh1jhj+hhhj+hMubeh}(h]h ](jstructeh"]h$]h&]jjjj=,jj=,jjjuh1j6hhhjhj5hNubj)}(hXs**Definition**:: struct damos_access_pattern { unsigned long min_sz_region; unsigned long max_sz_region; unsigned int min_nr_accesses; unsigned int max_nr_accesses; unsigned int min_age_region; unsigned int max_age_region; }; **Members** ``min_sz_region`` Minimum size of target regions. ``max_sz_region`` Maximum size of target regions. ``min_nr_accesses`` Minimum ``->nr_accesses`` of target regions. ``max_nr_accesses`` Maximum ``->nr_accesses`` of target regions. ``min_age_region`` Minimum age of target regions. ``max_age_region`` Maximum age of target regions.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjI,hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjE,ubh:}(hjE,hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjA,ubj)}(hstruct damos_access_pattern { unsigned long min_sz_region; unsigned long max_sz_region; unsigned int min_nr_accesses; unsigned int max_nr_accesses; unsigned int min_age_region; unsigned int max_age_region; };h]hstruct damos_access_pattern { unsigned long min_sz_region; unsigned long max_sz_region; unsigned int min_nr_accesses; unsigned int max_nr_accesses; unsigned int min_age_region; unsigned int max_age_region; };}hjb,sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjA,ubh)}(h **Members**h]j)}(hjs,h]hMembers}(hju,hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjq,ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjA,ubj7)}(hhh](j<)}(h2``min_sz_region`` Minimum size of target regions. h](jB)}(h``min_sz_region``h]h)}(hj,h]h min_sz_region}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj,ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj,ubj\)}(hhh]h)}(hMinimum size of target regions.h]hMinimum size of target regions.}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj,hMhj,ubah}(h]h ]h"]h$]h&]uh1j[hj,ubeh}(h]h ]h"]h$]h&]uh1j;hj,hMhj,ubj<)}(h2``max_sz_region`` Maximum size of target regions. h](jB)}(h``max_sz_region``h]h)}(hj,h]h max_sz_region}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj,ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj,ubj\)}(hhh]h)}(hMaximum size of target regions.h]hMaximum size of target regions.}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj,hMhj,ubah}(h]h ]h"]h$]h&]uh1j[hj,ubeh}(h]h ]h"]h$]h&]uh1j;hj,hMhj,ubj<)}(hA``min_nr_accesses`` Minimum ``->nr_accesses`` of target regions. h](jB)}(h``min_nr_accesses``h]h)}(hj-h]hmin_nr_accesses}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj-ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj,ubj\)}(hhh]h)}(h,Minimum ``->nr_accesses`` of target regions.h](hMinimum }(hj-hhhNhNubh)}(h``->nr_accesses``h]h ->nr_accesses}(hj%-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj-ubh of target regions.}(hj-hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj-hMhj-ubah}(h]h ]h"]h$]h&]uh1j[hj,ubeh}(h]h ]h"]h$]h&]uh1j;hj-hMhj,ubj<)}(hA``max_nr_accesses`` Maximum ``->nr_accesses`` of target regions. h](jB)}(h``max_nr_accesses``h]h)}(hjO-h]hmax_nr_accesses}(hjQ-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjM-ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjI-ubj\)}(hhh]h)}(h,Maximum ``->nr_accesses`` of target regions.h](hMaximum }(hjh-hhhNhNubh)}(h``->nr_accesses``h]h ->nr_accesses}(hjp-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjh-ubh of target regions.}(hjh-hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjd-hMhje-ubah}(h]h ]h"]h$]h&]uh1j[hjI-ubeh}(h]h ]h"]h$]h&]uh1j;hjd-hMhj,ubj<)}(h2``min_age_region`` Minimum age of target regions. h](jB)}(h``min_age_region``h]h)}(hj-h]hmin_age_region}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj-ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj-ubj\)}(hhh]h)}(hMinimum age of target regions.h]hMinimum age of target regions.}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj-hMhj-ubah}(h]h ]h"]h$]h&]uh1j[hj-ubeh}(h]h ]h"]h$]h&]uh1j;hj-hMhj,ubj<)}(h1``max_age_region`` Maximum age of target regions.h](jB)}(h``max_age_region``h]h)}(hj-h]hmax_age_region}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj-ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj-ubj\)}(hhh]h)}(hMaximum age of target regions.h]hMaximum age of target regions.}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj-ubah}(h]h ]h"]h$]h&]uh1j[hj-ubeh}(h]h ]h"]h$]h&]uh1j;hj-hMhj,ubeh}(h]h ]h"]h$]h&]uh1j6hjA,ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_migrate_dests (C struct)c.damos_migrate_destshNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamos_migrate_destsh]jB)}(hstruct damos_migrate_destsh](jH)}(hjKh]hstruct}(hj-.hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj).hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj;.hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj).hhhj:.hMubjk)}(hdamos_migrate_destsh]jq)}(hj'.h]hdamos_migrate_dests}(hjM.hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjI.ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj).hhhj:.hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj%.hhhj:.hMubah}(h]j .ah ](jjeh"]h$]h&]jj)jhuh1j;hj:.hMhj".hhubj)}(hhh]h)}(h.Migration destination nodes and their weights.h]h.Migration destination nodes and their weights.}(hjo.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjl.hhubah}(h]h ]h"]h$]h&]uh1jhj".hhhj:.hMubeh}(h]h ](jstructeh"]h$]h&]jjjj.jj.jjjuh1j6hhhjhj5hNubj)}(hXa**Definition**:: struct damos_migrate_dests { unsigned int *node_id_arr; unsigned int *weight_arr; size_t nr_dests; }; **Members** ``node_id_arr`` Array of migration destination node ids. ``weight_arr`` Array of migration weights for **node_id_arr**. ``nr_dests`` Length of the **node_id_arr** and **weight_arr** arrays.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj.ubh:}(hj.hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj.ubj)}(hqstruct damos_migrate_dests { unsigned int *node_id_arr; unsigned int *weight_arr; size_t nr_dests; };h]hqstruct damos_migrate_dests { unsigned int *node_id_arr; unsigned int *weight_arr; size_t nr_dests; };}hj.sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj.ubh)}(h **Members**h]j)}(hj.h]hMembers}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj.ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj.ubj7)}(hhh](j<)}(h9``node_id_arr`` Array of migration destination node ids. h](jB)}(h``node_id_arr``h]h)}(hj.h]h node_id_arr}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj.ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj.ubj\)}(hhh]h)}(h(Array of migration destination node ids.h]h(Array of migration destination node ids.}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj.hMhj.ubah}(h]h ]h"]h$]h&]uh1j[hj.ubeh}(h]h ]h"]h$]h&]uh1j;hj.hMhj.ubj<)}(h?``weight_arr`` Array of migration weights for **node_id_arr**. h](jB)}(h``weight_arr``h]h)}(hj/h]h weight_arr}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj/ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj/ubj\)}(hhh]h)}(h/Array of migration weights for **node_id_arr**.h](hArray of migration weights for }(hj./hhhNhNubj)}(h**node_id_arr**h]h node_id_arr}(hj6/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj./ubh.}(hj./hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj*/hMhj+/ubah}(h]h ]h"]h$]h&]uh1j[hj/ubeh}(h]h ]h"]h$]h&]uh1j;hj*/hMhj.ubj<)}(hE``nr_dests`` Length of the **node_id_arr** and **weight_arr** arrays.h](jB)}(h ``nr_dests``h]h)}(hj`/h]hnr_dests}(hjb/hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^/ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjZ/ubj\)}(hhh]h)}(h8Length of the **node_id_arr** and **weight_arr** arrays.h](hLength of the }(hjy/hhhNhNubj)}(h**node_id_arr**h]h node_id_arr}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjy/ubh and }(hjy/hhhNhNubj)}(h**weight_arr**h]h weight_arr}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjy/ubh arrays.}(hjy/hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjv/ubah}(h]h ]h"]h$]h&]uh1j[hjZ/ubeh}(h]h ]h"]h$]h&]uh1j;hju/hMhj.ubeh}(h]h ]h"]h$]h&]uh1j6hj.ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj/h]h Description}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(h**node_id_arr** is an array of the ids of migration destination nodes. **weight_arr** is an array of the weights for those. The weights in **weight_arr** are for nodes in **node_id_arr** of same array index.h](j)}(h**node_id_arr**h]h node_id_arr}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubh8 is an array of the ids of migration destination nodes. }(hj/hhhNhNubj)}(h**weight_arr**h]h weight_arr}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubh7 is an array of the weights for those. The weights in }(hj/hhhNhNubj)}(h**weight_arr**h]h weight_arr}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubh are for nodes in }(hj/hhhNhNubj)}(h**node_id_arr**h]h node_id_arr}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubh of same array index.}(hj/hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos (C struct)c.damoshNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamosh]jB)}(h struct damosh](jH)}(hjKh]hstruct}(hjI0hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjE0hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hjW0hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjE0hhhjV0hMubjk)}(hdamosh]jq)}(hjC0h]hdamos}(hji0hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphje0ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjE0hhhjV0hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjA0hhhjV0hMubah}(h]j<0ah ](jjeh"]h$]h&]jj)jhuh1j;hjV0hMhj>0hhubj)}(hhh]h)}(h;Represents a Data Access Monitoring-based Operation Scheme.h]h;Represents a Data Access Monitoring-based Operation Scheme.}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj0hhubah}(h]h ]h"]h$]h&]uh1jhj>0hhhjV0hMubeh}(h]h ](jstructeh"]h$]h&]jjjj0jj0jjjuh1j6hhhjhj5hNubj)}(hX5**Definition**:: struct damos { struct damos_access_pattern pattern; enum damos_action action; unsigned long apply_interval_us; struct damos_quota quota; struct damos_watermarks wmarks; union { struct { int target_nid; struct damos_migrate_dests migrate_dests; }; }; struct damos_stat stat; unsigned long max_nr_snapshots; }; **Members** ``pattern`` Access pattern of target regions. ``action`` :c:type:`damos_action` to be applied to the target regions. ``apply_interval_us`` The time between applying the **action**. ``quota`` Control the aggressiveness of this scheme. ``wmarks`` Watermarks for automated (in)activation of this scheme. ``{unnamed_union}`` anonymous ``{unnamed_struct}`` anonymous ``target_nid`` Destination node if **action** is "migrate_{hot,cold}". ``migrate_dests`` Destination nodes if **action** is "migrate_{hot,cold}". ``stat`` Statistics of this scheme. ``max_nr_snapshots`` Upper limit of nr_snapshots stat.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0ubh:}(hj0hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj0ubj)}(hXstruct damos { struct damos_access_pattern pattern; enum damos_action action; unsigned long apply_interval_us; struct damos_quota quota; struct damos_watermarks wmarks; union { struct { int target_nid; struct damos_migrate_dests migrate_dests; }; }; struct damos_stat stat; unsigned long max_nr_snapshots; };h]hXstruct damos { struct damos_access_pattern pattern; enum damos_action action; unsigned long apply_interval_us; struct damos_quota quota; struct damos_watermarks wmarks; union { struct { int target_nid; struct damos_migrate_dests migrate_dests; }; }; struct damos_stat stat; unsigned long max_nr_snapshots; };}hj0sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hj0ubh)}(h **Members**h]j)}(hj0h]hMembers}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj0ubj7)}(hhh](j<)}(h.``pattern`` Access pattern of target regions. h](jB)}(h ``pattern``h]h)}(hj0h]hpattern}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj0ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj0ubj\)}(hhh]h)}(h!Access pattern of target regions.h]h!Access pattern of target regions.}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj 1hMhj1ubah}(h]h ]h"]h$]h&]uh1j[hj0ubeh}(h]h ]h"]h$]h&]uh1j;hj 1hMhj0ubj<)}(hG``action`` :c:type:`damos_action` to be applied to the target regions. h](jB)}(h ``action``h]h)}(hj11h]haction}(hj31hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj/1ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj+1ubj\)}(hhh]h)}(h;:c:type:`damos_action` to be applied to the target regions.h](h)}(h:c:type:`damos_action`h]h)}(hjP1h]h damos_action}(hjR1hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjN1ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damos_actionuh1hhjF1hMhjJ1ubh% to be applied to the target regions.}(hjJ1hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjF1hMhjG1ubah}(h]h ]h"]h$]h&]uh1j[hj+1ubeh}(h]h ]h"]h$]h&]uh1j;hjF1hMhj0ubj<)}(h@``apply_interval_us`` The time between applying the **action**. h](jB)}(h``apply_interval_us``h]h)}(hj1h]happly_interval_us}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj1ubj\)}(hhh]h)}(h)The time between applying the **action**.h](hThe time between applying the }(hj1hhhNhNubj)}(h **action**h]haction}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj1ubh.}(hj1hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj1hMhj1ubah}(h]h ]h"]h$]h&]uh1j[hj1ubeh}(h]h ]h"]h$]h&]uh1j;hj1hMhj0ubj<)}(h5``quota`` Control the aggressiveness of this scheme. h](jB)}(h ``quota``h]h)}(hj1h]hquota}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hj1ubj\)}(hhh]h)}(h*Control the aggressiveness of this scheme.h]h*Control the aggressiveness of this scheme.}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1hM hj1ubah}(h]h ]h"]h$]h&]uh1j[hj1ubeh}(h]h ]h"]h$]h&]uh1j;hj1hM hj0ubj<)}(hC``wmarks`` Watermarks for automated (in)activation of this scheme. h](jB)}(h ``wmarks``h]h)}(hj 2h]hwmarks}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj 2ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hj2ubj\)}(hhh]h)}(h7Watermarks for automated (in)activation of this scheme.h]h7Watermarks for automated (in)activation of this scheme.}(hj&2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj"2hM hj#2ubah}(h]h ]h"]h$]h&]uh1j[hj2ubeh}(h]h ]h"]h$]h&]uh1j;hj"2hM hj0ubj<)}(h``{unnamed_union}`` anonymous h](jB)}(h``{unnamed_union}``h]h)}(hjF2h]h{unnamed_union}}(hjH2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjD2ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhj@2ubj\)}(hhh]h)}(h anonymoush]h anonymous}(hj_2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj[2hKhj\2ubah}(h]h ]h"]h$]h&]uh1j[hj@2ubeh}(h]h ]h"]h$]h&]uh1j;hj[2hKhj0ubj<)}(h``{unnamed_struct}`` anonymous h](jB)}(h``{unnamed_struct}``h]h)}(hj2h]h{unnamed_struct}}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj}2ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhKhjy2ubj\)}(hhh]h)}(h anonymoush]h anonymous}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj2hKhj2ubah}(h]h ]h"]h$]h&]uh1j[hjy2ubeh}(h]h ]h"]h$]h&]uh1j;hj2hKhj0ubj<)}(hG``target_nid`` Destination node if **action** is "migrate_{hot,cold}". h](jB)}(h``target_nid``h]h)}(hj2h]h target_nid}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj2ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hj2ubj\)}(hhh]h)}(h7Destination node if **action** is "migrate_{hot,cold}".h](hDestination node if }(hj2hhhNhNubj)}(h **action**h]haction}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj2ubh is “migrate_{hot,cold}”.}(hj2hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj2hM hj2ubah}(h]h ]h"]h$]h&]uh1j[hj2ubeh}(h]h ]h"]h$]h&]uh1j;hj2hM hj0ubj<)}(hK``migrate_dests`` Destination nodes if **action** is "migrate_{hot,cold}". h](jB)}(h``migrate_dests``h]h)}(hj3h]h migrate_dests}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj3ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hj2ubj\)}(hhh]h)}(h8Destination nodes if **action** is "migrate_{hot,cold}".h](hDestination nodes if }(hj3hhhNhNubj)}(h **action**h]haction}(hj$3hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj3ubh is “migrate_{hot,cold}”.}(hj3hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj3hM hj3ubah}(h]h ]h"]h$]h&]uh1j[hj2ubeh}(h]h ]h"]h$]h&]uh1j;hj3hM hj0ubj<)}(h$``stat`` Statistics of this scheme. h](jB)}(h``stat``h]h)}(hjN3h]hstat}(hjP3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjL3ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hjH3ubj\)}(hhh]h)}(hStatistics of this scheme.h]hStatistics of this scheme.}(hjg3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjc3hM hjd3ubah}(h]h ]h"]h$]h&]uh1j[hjH3ubeh}(h]h ]h"]h$]h&]uh1j;hjc3hM hj0ubj<)}(h6``max_nr_snapshots`` Upper limit of nr_snapshots stat.h](jB)}(h``max_nr_snapshots``h]h)}(hj3h]hmax_nr_snapshots}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj3ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hj3ubj\)}(hhh]h)}(h!Upper limit of nr_snapshots stat.h]h!Upper limit of nr_snapshots stat.}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj3ubah}(h]h ]h"]h$]h&]uh1j[hj3ubeh}(h]h ]h"]h$]h&]uh1j;hj3hM hj0ubeh}(h]h ]h"]h$]h&]uh1j6hj0ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj3h]h Description}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj3ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hFor each **apply_interval_us**, DAMON finds regions which fit in the :c:type:`pattern` and applies :c:type:`action` to those. To avoid consuming too much CPU time or IO resources for the :c:type:`action`, :c:type:`quota` is used.h](h For each }(hj3hhhNhNubj)}(h**apply_interval_us**h]happly_interval_us}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj3ubh', DAMON finds regions which fit in the }(hj3hhhNhNubh)}(h:c:type:`pattern`h]h)}(hj3h]hpattern}(hj3hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj3ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjpatternuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj3ubh and applies }(hj3hhhNhNubh)}(h:c:type:`action`h]h)}(hj 4h]haction}(hj"4hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj4ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjactionuh1hhj4hMhj3ubhH to those. To avoid consuming too much CPU time or IO resources for the }(hj3hhhNhNubh)}(h:c:type:`action`h]h)}(hjC4h]haction}(hjE4hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjA4ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjactionuh1hhj4hMhj3ubh, }(hj3hhhNhNubh)}(h:c:type:`quota`h]h)}(hjf4h]hquota}(hjh4hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjd4ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjquotauh1hhj4hMhj3ubh is used.}(hj3hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj4hMhjhhubh)}(heIf **apply_interval_us** is zero, :c:type:`damon_attrs->aggr_interval ` is used instead.h](hIf }(hj4hhhNhNubj)}(h**apply_interval_us**h]happly_interval_us}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj4ubh is zero, }(hj4hhhNhNubh)}(h2:c:type:`damon_attrs->aggr_interval `h]h)}(hj4h]hdamon_attrs->aggr_interval}(hj4hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj4ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj4ubh is used instead.}(hj4hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj4hMhjhhubh)}(hXTo do the work only when needed, schemes can be activated for specific system situations using :c:type:`wmarks`. If all schemes that registered to the monitoring context are inactive, DAMON stops monitoring either, and just repeatedly checks the watermarks.h](h_To do the work only when needed, schemes can be activated for specific system situations using }(hj4hhhNhNubh)}(h:c:type:`wmarks`h]h)}(hj4h]hwmarks}(hj4hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj4ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjwmarksuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj4ubh. If all schemes that registered to the monitoring context are inactive, DAMON stops monitoring either, and just repeatedly checks the watermarks.}(hj4hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj4hMhjhhubh)}(h**migrate_dests** specifies multiple migration target nodes with different weights for migrate_hot or migrate_cold actions. **target_nid** is ignored if this is set.h](j)}(h**migrate_dests**h]h migrate_dests}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj5ubhl specifies multiple migration target nodes with different weights for migrate_hot or migrate_cold actions. }(hj5hhhNhNubj)}(h**target_nid**h]h target_nid}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj5ubh is ignored if this is set.}(hj5hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(h**target_nid** is used to set the migration target node for migrate_hot or migrate_cold actions, and **migrate_dests** is unset.h](j)}(h**target_nid**h]h target_nid}(hj65hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj25ubhW is used to set the migration target node for migrate_hot or migrate_cold actions, and }(hj25hhhNhNubj)}(h**migrate_dests**h]h migrate_dests}(hjH5hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj25ubh is unset.}(hj25hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hBefore applying the :c:type:`action` to a memory region, :c:type:`struct damon_operations ` implementation could check pages of the region and skip :c:type:`action` to respect :c:type:`struct damos_filter `.h](hBefore applying the }(hja5hhhNhNubh)}(h:c:type:`action`h]h)}(hjk5h]haction}(hjm5hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhji5ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjactionuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM hja5ubh to a memory region, }(hja5hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj5h]hstruct damon_operations}(hj5hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj5ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhj5hM hja5ubh9 implementation could check pages of the region and skip }(hja5hhhNhNubh)}(h:c:type:`action`h]h)}(hj5h]haction}(hj5hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj5ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjactionuh1hhj5hM hja5ubh to respect }(hja5hhhNhNubh)}(h,:c:type:`struct damos_filter `h]h)}(hj5h]hstruct damos_filter}(hj5hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj5ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damos_filteruh1hhj5hM hja5ubh.}(hja5hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj5hM hjhhubh)}(hNAfter applying the :c:type:`action` to each region, :c:type:`stat` is updated.h](hAfter applying the }(hj5hhhNhNubh)}(h:c:type:`action`h]h)}(hj6h]haction}(hj6hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj6ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjactionuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM$hj5ubh to each region, }(hj5hhhNhNubh)}(h:c:type:`stat`h]h)}(hj*6h]hstat}(hj,6hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj(6ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjstatuh1hhj#6hM$hj5ubh is updated.}(hj5hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj#6hM$hjhhubh)}(hIf :c:type:`max_nr_snapshots` is set as non-zero and :c:type:`stat.nr_snapshots ` be same to or greater than it, the scheme is deactivated.h](hIf }(hjQ6hhhNhNubh)}(h:c:type:`max_nr_snapshots`h]h)}(hj[6h]hmax_nr_snapshots}(hj]6hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjY6ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjmax_nr_snapshotsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM&hjQ6ubh is set as non-zero and }(hjQ6hhhNhNubh)}(h":c:type:`stat.nr_snapshots `h]h)}(hj6h]hstat.nr_snapshots}(hj6hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj}6ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjstatuh1hhjx6hM&hjQ6ubh: be same to or greater than it, the scheme is deactivated.}(hjQ6hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjx6hM&hjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_ops_id (C enum)c.damon_ops_idhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damon_ops_idh]jB)}(henum damon_ops_idh](jH)}(hjh]henum}(hj6hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj6hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM,ubjZ)}(h h]h }(hj6hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj6hhhj6hM,ubjk)}(h damon_ops_idh]jq)}(hj6h]h damon_ops_id}(hj6hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj6ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj6hhhj6hM,ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj6hhhj6hM,ubah}(h]j6ah ](jjeh"]h$]h&]jj)jhuh1j;hj6hM,hj6hhubj)}(hhh]h)}(h8Identifier for each monitoring operations implementationh]h8Identifier for each monitoring operations implementation}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM_hj6hhubah}(h]h ]h"]h$]h&]uh1jhj6hhhj6hM,ubeh}(h]h ](jenumeh"]h$]h&]jjjj7jj7jjjuh1j6hhhjhj5hNubj)}(hXE**Constants** ``DAMON_OPS_VADDR`` Monitoring operations for virtual address spaces ``DAMON_OPS_FVADDR`` Monitoring operations for only fixed ranges of virtual address spaces ``DAMON_OPS_PADDR`` Monitoring operations for the physical address space ``NR_DAMON_OPS`` Number of monitoring operations implementationsh](h)}(h **Constants**h]j)}(hj#7h]h Constants}(hj%7hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj!7ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMchj7ubj7)}(hhh](j<)}(hE``DAMON_OPS_VADDR`` Monitoring operations for virtual address spaces h](jB)}(h``DAMON_OPS_VADDR``h]h)}(hjB7h]hDAMON_OPS_VADDR}(hjD7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj@7ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMfhj<7ubj\)}(hhh]h)}(h0Monitoring operations for virtual address spacesh]h0Monitoring operations for virtual address spaces}(hj[7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjW7hMfhjX7ubah}(h]h ]h"]h$]h&]uh1j[hj<7ubeh}(h]h ]h"]h$]h&]uh1j;hjW7hMfhj97ubj<)}(h[``DAMON_OPS_FVADDR`` Monitoring operations for only fixed ranges of virtual address spaces h](jB)}(h``DAMON_OPS_FVADDR``h]h)}(hj{7h]hDAMON_OPS_FVADDR}(hj}7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjy7ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMjhju7ubj\)}(hhh]h)}(hEMonitoring operations for only fixed ranges of virtual address spacesh]hEMonitoring operations for only fixed ranges of virtual address spaces}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMihj7ubah}(h]h ]h"]h$]h&]uh1j[hju7ubeh}(h]h ]h"]h$]h&]uh1j;hj7hMjhj97ubj<)}(hI``DAMON_OPS_PADDR`` Monitoring operations for the physical address space h](jB)}(h``DAMON_OPS_PADDR``h]h)}(hj7h]hDAMON_OPS_PADDR}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMmhj7ubj\)}(hhh]h)}(h4Monitoring operations for the physical address spaceh]h4Monitoring operations for the physical address space}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7hMmhj7ubah}(h]h ]h"]h$]h&]uh1j[hj7ubeh}(h]h ]h"]h$]h&]uh1j;hj7hMmhj97ubj<)}(h@``NR_DAMON_OPS`` Number of monitoring operations implementationsh](jB)}(h``NR_DAMON_OPS``h]h)}(hj7h]h NR_DAMON_OPS}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMohj7ubj\)}(hhh]h)}(h/Number of monitoring operations implementationsh]h/Number of monitoring operations implementations}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMphj8ubah}(h]h ]h"]h$]h&]uh1j[hj7ubeh}(h]h ]h"]h$]h&]uh1j;hj8hMohj97ubeh}(h]h ]h"]h$]h&]uh1j6hj7ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_operations (C struct)c.damon_operationshNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamon_operationsh]jB)}(hstruct damon_operationsh](jH)}(hjKh]hstruct}(hjH8hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjD8hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMuubjZ)}(h h]h }(hjV8hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjD8hhhjU8hMuubjk)}(hdamon_operationsh]jq)}(hjB8h]hdamon_operations}(hjh8hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjd8ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjD8hhhjU8hMuubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj@8hhhjU8hMuubah}(h]j;8ah ](jjeh"]h$]h&]jj)jhuh1j;hjU8hMuhj=8hhubj)}(hhh]h)}(h*Monitoring operations for given use cases.h]h*Monitoring operations for given use cases.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMohj8hhubah}(h]h ]h"]h$]h&]uh1jhj=8hhhjU8hMuubeh}(h]h ](jstructeh"]h$]h&]jjjj8jj8jjjuh1j6hhhjhj5hNubj)}(hXe**Definition**:: struct damon_operations { enum damon_ops_id id; void (*init)(struct damon_ctx *context); void (*update)(struct damon_ctx *context); void (*prepare_access_checks)(struct damon_ctx *context); unsigned int (*check_accesses)(struct damon_ctx *context); unsigned int (*apply_probes)(struct damon_ctx *context, bool set_samples, bool return_max_wsum); int (*get_scheme_score)(struct damon_ctx *context, struct damon_region *r, struct damos *scheme); unsigned long (*apply_scheme)(struct damon_ctx *context, struct damon_target *t, struct damon_region *r, struct damos *scheme, unsigned long *sz_filter_passed); bool (*target_valid)(struct damon_target *t); void (*cleanup_target)(struct damon_target *t); }; **Members** ``id`` Identifier of this operations set. ``init`` Initialize operations-related data structures. ``update`` Update operations-related data structures. ``prepare_access_checks`` Prepare next access check of target regions. ``check_accesses`` Check the accesses to target regions. ``apply_probes`` Apply probes for each region. ``get_scheme_score`` Get the score of a region for a scheme. ``apply_scheme`` Apply a DAMON-based operation scheme. ``target_valid`` Determine if the target is valid. ``cleanup_target`` Clean up each target before deallocation.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8ubh:}(hj8hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMshj8ubj)}(hXstruct damon_operations { enum damon_ops_id id; void (*init)(struct damon_ctx *context); void (*update)(struct damon_ctx *context); void (*prepare_access_checks)(struct damon_ctx *context); unsigned int (*check_accesses)(struct damon_ctx *context); unsigned int (*apply_probes)(struct damon_ctx *context, bool set_samples, bool return_max_wsum); int (*get_scheme_score)(struct damon_ctx *context, struct damon_region *r, struct damos *scheme); unsigned long (*apply_scheme)(struct damon_ctx *context, struct damon_target *t, struct damon_region *r, struct damos *scheme, unsigned long *sz_filter_passed); bool (*target_valid)(struct damon_target *t); void (*cleanup_target)(struct damon_target *t); };h]hXstruct damon_operations { enum damon_ops_id id; void (*init)(struct damon_ctx *context); void (*update)(struct damon_ctx *context); void (*prepare_access_checks)(struct damon_ctx *context); unsigned int (*check_accesses)(struct damon_ctx *context); unsigned int (*apply_probes)(struct damon_ctx *context, bool set_samples, bool return_max_wsum); int (*get_scheme_score)(struct damon_ctx *context, struct damon_region *r, struct damos *scheme); unsigned long (*apply_scheme)(struct damon_ctx *context, struct damon_target *t, struct damon_region *r, struct damos *scheme, unsigned long *sz_filter_passed); bool (*target_valid)(struct damon_target *t); void (*cleanup_target)(struct damon_target *t); };}hj8sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMuhj8ubh)}(h **Members**h]j)}(hj8h]hMembers}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj8ubj7)}(hhh](j<)}(h*``id`` Identifier of this operations set. h](jB)}(h``id``h]h)}(hj8h]hid}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj8ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMrhj8ubj\)}(hhh]h)}(h"Identifier of this operations set.h]h"Identifier of this operations set.}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj 9hMrhj 9ubah}(h]h ]h"]h$]h&]uh1j[hj8ubeh}(h]h ]h"]h$]h&]uh1j;hj 9hMrhj8ubj<)}(h8``init`` Initialize operations-related data structures. h](jB)}(h``init``h]h)}(hj09h]hinit}(hj29hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj.9ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMshj*9ubj\)}(hhh]h)}(h.Initialize operations-related data structures.h]h.Initialize operations-related data structures.}(hjI9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjE9hMshjF9ubah}(h]h ]h"]h$]h&]uh1j[hj*9ubeh}(h]h ]h"]h$]h&]uh1j;hjE9hMshj8ubj<)}(h6``update`` Update operations-related data structures. h](jB)}(h ``update``h]h)}(hji9h]hupdate}(hjk9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjg9ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMthjc9ubj\)}(hhh]h)}(h*Update operations-related data structures.h]h*Update operations-related data structures.}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj~9hMthj9ubah}(h]h ]h"]h$]h&]uh1j[hjc9ubeh}(h]h ]h"]h$]h&]uh1j;hj~9hMthj8ubj<)}(hG``prepare_access_checks`` Prepare next access check of target regions. h](jB)}(h``prepare_access_checks``h]h)}(hj9h]hprepare_access_checks}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMuhj9ubj\)}(hhh]h)}(h,Prepare next access check of target regions.h]h,Prepare next access check of target regions.}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9hMuhj9ubah}(h]h ]h"]h$]h&]uh1j[hj9ubeh}(h]h ]h"]h$]h&]uh1j;hj9hMuhj8ubj<)}(h9``check_accesses`` Check the accesses to target regions. h](jB)}(h``check_accesses``h]h)}(hj9h]hcheck_accesses}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMvhj9ubj\)}(hhh]h)}(h%Check the accesses to target regions.h]h%Check the accesses to target regions.}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9hMvhj9ubah}(h]h ]h"]h$]h&]uh1j[hj9ubeh}(h]h ]h"]h$]h&]uh1j;hj9hMvhj8ubj<)}(h/``apply_probes`` Apply probes for each region. h](jB)}(h``apply_probes``h]h)}(hj:h]h apply_probes}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMwhj:ubj\)}(hhh]h)}(hApply probes for each region.h]hApply probes for each region.}(hj-:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj):hMwhj*:ubah}(h]h ]h"]h$]h&]uh1j[hj:ubeh}(h]h ]h"]h$]h&]uh1j;hj):hMwhj8ubj<)}(h=``get_scheme_score`` Get the score of a region for a scheme. h](jB)}(h``get_scheme_score``h]h)}(hjM:h]hget_scheme_score}(hjO:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjK:ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMxhjG:ubj\)}(hhh]h)}(h'Get the score of a region for a scheme.h]h'Get the score of a region for a scheme.}(hjf:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjb:hMxhjc:ubah}(h]h ]h"]h$]h&]uh1j[hjG:ubeh}(h]h ]h"]h$]h&]uh1j;hjb:hMxhj8ubj<)}(h7``apply_scheme`` Apply a DAMON-based operation scheme. h](jB)}(h``apply_scheme``h]h)}(hj:h]h apply_scheme}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMyhj:ubj\)}(hhh]h)}(h%Apply a DAMON-based operation scheme.h]h%Apply a DAMON-based operation scheme.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:hMyhj:ubah}(h]h ]h"]h$]h&]uh1j[hj:ubeh}(h]h ]h"]h$]h&]uh1j;hj:hMyhj8ubj<)}(h3``target_valid`` Determine if the target is valid. h](jB)}(h``target_valid``h]h)}(hj:h]h target_valid}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMzhj:ubj\)}(hhh]h)}(h!Determine if the target is valid.h]h!Determine if the target is valid.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:hMzhj:ubah}(h]h ]h"]h$]h&]uh1j[hj:ubeh}(h]h ]h"]h$]h&]uh1j;hj:hMzhj8ubj<)}(h<``cleanup_target`` Clean up each target before deallocation.h](jB)}(h``cleanup_target``h]h)}(hj:h]hcleanup_target}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMzhj:ubj\)}(hhh]h)}(h)Clean up each target before deallocation.h]h)Clean up each target before deallocation.}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM{hj;ubah}(h]h ]h"]h$]h&]uh1j[hj:ubeh}(h]h ]h"]h$]h&]uh1j;hj ;hMzhj8ubeh}(h]h ]h"]h$]h&]uh1j6hj8ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj;;h]h Description}(hj=;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj9;ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM~hjhhubh)}(hX8DAMON can be extended for various address spaces and usages. For this, users should register the low level operations for their target address space and usecase via the :c:type:`damon_ctx.ops `. Then, the monitoring thread (:c:type:`damon_ctx.kdamond `) calls **init** and **prepare_access_checks** before starting the monitoring, **update** after each :c:type:`damon_attrs.ops_update_interval `, and **check_accesses**, **target_valid** and **prepare_access_checks** after each :c:type:`damon_attrs.sample_interval `.h](hDAMON can be extended for various address spaces and usages. For this, users should register the low level operations for their target address space and usecase via the }(hjQ;hhhNhNubh)}(h#:c:type:`damon_ctx.ops `h]h)}(hj[;h]h damon_ctx.ops}(hj];hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjY;ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_ctxuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM{hjQ;ubh . Then, the monitoring thread (}(hjQ;hhhNhNubh)}(h':c:type:`damon_ctx.kdamond `h]h)}(hj;h]hdamon_ctx.kdamond}(hj;hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj};ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_ctxuh1hhjx;hM{hjQ;ubh) calls }(hjQ;hhhNhNubj)}(h**init**h]hinit}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQ;ubh and }(hjQ;hhhNhNubj)}(h**prepare_access_checks**h]hprepare_access_checks}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQ;ubh! before starting the monitoring, }(hjQ;hhhNhNubj)}(h **update**h]hupdate}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQ;ubh after each }(hjQ;hhhNhNubh)}(h7:c:type:`damon_attrs.ops_update_interval `h]h)}(hj;h]hdamon_attrs.ops_update_interval}(hj;hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj;ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhjx;hM{hjQ;ubh, and }(hjQ;hhhNhNubj)}(h**check_accesses**h]hcheck_accesses}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQ;ubh, }(hjQ;hhhNhNubj)}(h**target_valid**h]h target_valid}(hj <hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQ;ubh and }hjQ;sbj)}(h**prepare_access_checks**h]hprepare_access_checks}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQ;ubh after each }(hjQ;hhhNhNubh)}(h3:c:type:`damon_attrs.sample_interval `h]h)}(hj1<h]hdamon_attrs.sample_interval}(hj3<hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj/<ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhjx;hM{hjQ;ubh.}(hjQ;hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjx;hM{hjhhubh)}(hXEach :c:type:`struct damon_operations ` instance having valid **id** can be registered via damon_register_ops() and selected by damon_select_ops() later. **init** should initialize operations-related data structures. For example, this could be used to construct proper monitoring target regions and link those to **damon_ctx.adaptive_targets**. **update** should update the operations-related data structures. For example, this could be used to update monitoring target regions for current status. **prepare_access_checks** should manipulate the monitoring regions to be prepared for the next access check. **check_accesses** should check the accesses to each region that made after the last preparation and update the number of observed accesses of each region. It should also return max number of observed accesses that made as a result of its update. The value will be used for regions adjustment threshold. **apply_probes** should apply the data attribute probes to each region and accordingly update the probe hits counter of the region. It should also set :c:type:`damon_region->sampling_addr ` of each region if ``set_samples`` is true. It should also return maximum probe hits weighted sum of regions if ``return_max_wsum`` is true. **get_scheme_score** should return the priority score of a region for a scheme as an integer in [0, :c:type:`DAMOS_MAX_SCORE`]. **apply_scheme** is called from **kdamond** when a region for user provided DAMON-based operation scheme is found. It should apply the scheme's action to the region and return bytes of the region that the action is successfully applied. It should also report how many bytes of the region has passed filters (:c:type:`struct damos_filter `) that handled by itself. **target_valid** should check whether the target is still valid for the monitoring. **cleanup_target** is called before the target will be deallocated.h](hEach }(hjX<hhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hjb<h]hstruct damon_operations}(hjd<hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj`<ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjX<ubh instance having valid }(hjX<hhhNhNubj)}(h**id**h]hid}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubhV can be registered via damon_register_ops() and selected by damon_select_ops() later. }(hjX<hhhNhNubj)}(h**init**h]hinit}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubh should initialize operations-related data structures. For example, this could be used to construct proper monitoring target regions and link those to }(hjX<hhhNhNubj)}(h**damon_ctx.adaptive_targets**h]hdamon_ctx.adaptive_targets}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubh. }(hjX<hhhNhNubj)}(h **update**h]hupdate}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubh should update the operations-related data structures. For example, this could be used to update monitoring target regions for current status. }(hjX<hhhNhNubj)}(h**prepare_access_checks**h]hprepare_access_checks}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubhT should manipulate the monitoring regions to be prepared for the next access check. }(hjX<hhhNhNubj)}(h**check_accesses**h]hcheck_accesses}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubhX should check the accesses to each region that made after the last preparation and update the number of observed accesses of each region. It should also return max number of observed accesses that made as a result of its update. The value will be used for regions adjustment threshold. }(hjX<hhhNhNubj)}(h**apply_probes**h]h apply_probes}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubh should apply the data attribute probes to each region and accordingly update the probe hits counter of the region. It should also set }(hjX<hhhNhNubh)}(h4:c:type:`damon_region->sampling_addr `h]h)}(hj=h]hdamon_region->sampling_addr}(hj=hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj=ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_regionuh1hhj<hMhjX<ubh of each region if }(hjX<hhhNhNubh)}(h``set_samples``h]h set_samples}(hj%=hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjX<ubhN is true. It should also return maximum probe hits weighted sum of regions if }(hjX<hhhNhNubh)}(h``return_max_wsum``h]hreturn_max_wsum}(hj7=hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjX<ubh is true. }(hjX<hhhNhNubj)}(h**get_scheme_score**h]hget_scheme_score}(hjI=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubhP should return the priority score of a region for a scheme as an integer in [0, }(hjX<hhhNhNubh)}(h:c:type:`DAMOS_MAX_SCORE`h]h)}(hj]=h]hDAMOS_MAX_SCORE}(hj_=hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj[=ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjDAMOS_MAX_SCOREuh1hhj<hMhjX<ubh]. }(hjX<hhhNhNubj)}(h**apply_scheme**h]h apply_scheme}(hj~=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubh is called from }(hjX<hhhNhNubj)}(h **kdamond**h]hkdamond}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubhX  when a region for user provided DAMON-based operation scheme is found. It should apply the scheme’s action to the region and return bytes of the region that the action is successfully applied. It should also report how many bytes of the region has passed filters (}(hjX<hhhNhNubh)}(h,:c:type:`struct damos_filter `h]h)}(hj=h]hstruct damos_filter}(hj=hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj=ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damos_filteruh1hhj<hMhjX<ubh) that handled by itself. }(hjX<hhhNhNubj)}(h**target_valid**h]h target_valid}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubhD should check whether the target is still valid for the monitoring. }(hjX<hhhNhNubj)}(h**cleanup_target**h]hcleanup_target}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjX<ubh1 is called before the target will be deallocated.}(hjX<hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj<hMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_intervals_goal (C struct)c.damon_intervals_goalhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamon_intervals_goalh]jB)}(hstruct damon_intervals_goalh](jH)}(hjKh]hstruct}(hj>hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj>hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj>hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj>hhhj>hMubjk)}(hdamon_intervals_goalh]jq)}(hj>h]hdamon_intervals_goal}(hj(>hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj$>ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj>hhhj>hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj>hhhj>hMubah}(h]j=ah ](jjeh"]h$]h&]jj)jhuh1j;hj>hMhj=hhubj)}(hhh]h)}(h&Monitoring intervals auto-tuning goal.h]h&Monitoring intervals auto-tuning goal.}(hjJ>hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjG>hhubah}(h]h ]h"]h$]h&]uh1jhj=hhhj>hMubeh}(h]h ](jstructeh"]h$]h&]jjjjb>jjb>jjjuh1j6hhhjhj5hNubj)}(hX**Definition**:: struct damon_intervals_goal { unsigned long access_bp; unsigned long aggrs; unsigned long min_sample_us; unsigned long max_sample_us; }; **Members** ``access_bp`` Access events observation ratio to achieve in bp. ``aggrs`` Number of aggregations to achieve **access_bp** within. ``min_sample_us`` Minimum resulting sampling interval in microseconds. ``max_sample_us`` Maximum resulting sampling interval in microseconds.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjn>hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjj>ubh:}(hjj>hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjf>ubj)}(hstruct damon_intervals_goal { unsigned long access_bp; unsigned long aggrs; unsigned long min_sample_us; unsigned long max_sample_us; };h]hstruct damon_intervals_goal { unsigned long access_bp; unsigned long aggrs; unsigned long min_sample_us; unsigned long max_sample_us; };}hj>sbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjf>ubh)}(h **Members**h]j)}(hj>h]hMembers}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj>ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjf>ubj7)}(hhh](j<)}(h@``access_bp`` Access events observation ratio to achieve in bp. h](jB)}(h ``access_bp``h]h)}(hj>h]h access_bp}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj>ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj>ubj\)}(hhh]h)}(h1Access events observation ratio to achieve in bp.h]h1Access events observation ratio to achieve in bp.}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj>hMhj>ubah}(h]h ]h"]h$]h&]uh1j[hj>ubeh}(h]h ]h"]h$]h&]uh1j;hj>hMhj>ubj<)}(hB``aggrs`` Number of aggregations to achieve **access_bp** within. h](jB)}(h ``aggrs``h]h)}(hj>h]haggrs}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj>ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj>ubj\)}(hhh]h)}(h7Number of aggregations to achieve **access_bp** within.h](h"Number of aggregations to achieve }(hj ?hhhNhNubj)}(h **access_bp**h]h access_bp}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ?ubh within.}(hj ?hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj?hMhj?ubah}(h]h ]h"]h$]h&]uh1j[hj>ubeh}(h]h ]h"]h$]h&]uh1j;hj?hMhj>ubj<)}(hG``min_sample_us`` Minimum resulting sampling interval in microseconds. h](jB)}(h``min_sample_us``h]h)}(hj;?h]h min_sample_us}(hj=?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9?ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj5?ubj\)}(hhh]h)}(h4Minimum resulting sampling interval in microseconds.h]h4Minimum resulting sampling interval in microseconds.}(hjT?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjP?hMhjQ?ubah}(h]h ]h"]h$]h&]uh1j[hj5?ubeh}(h]h ]h"]h$]h&]uh1j;hjP?hMhj>ubj<)}(hF``max_sample_us`` Maximum resulting sampling interval in microseconds.h](jB)}(h``max_sample_us``h]h)}(hjt?h]h max_sample_us}(hjv?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjr?ubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjn?ubj\)}(hhh]h)}(h4Maximum resulting sampling interval in microseconds.h]h4Maximum resulting sampling interval in microseconds.}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj?ubah}(h]h ]h"]h$]h&]uh1j[hjn?ubeh}(h]h ]h"]h$]h&]uh1j;hj?hMhj>ubeh}(h]h ]h"]h$]h&]uh1j6hjf>ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj?h]h Description}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubh)}(hX'DAMON automatically tunes :c:type:`damon_attrs->sample_interval ` and :c:type:`damon_attrs->aggr_interval ` aiming the ratio in bp (1/10,000) of DAMON-observed access events to theoretical maximum amount within **aggrs** aggregations be same to **access_bp**. The logic increases :c:type:`damon_attrs->aggr_interval ` and :c:type:`damon_attrs->sampling_interval ` in same ratio if the current access events observation ratio is lower than the target for each **aggrs** aggregations, and vice versa.h](hDAMON automatically tunes }(hj?hhhNhNubh)}(h4:c:type:`damon_attrs->sample_interval `h]h)}(hj?h]hdamon_attrs->sample_interval}(hj?hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj?ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj?ubh and }(hj?hhhNhNubh)}(h2:c:type:`damon_attrs->aggr_interval `h]h)}(hj?h]hdamon_attrs->aggr_interval}(hj?hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj?ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhj?hMhj?ubhh aiming the ratio in bp (1/10,000) of DAMON-observed access events to theoretical maximum amount within }(hj?hhhNhNubj)}(h **aggrs**h]haggrs}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubh aggregations be same to }(hj?hhhNhNubj)}(h **access_bp**h]h access_bp}(hj.@hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubh. The logic increases }(hj?hhhNhNubh)}(h2:c:type:`damon_attrs->aggr_interval `h]h)}(hjB@h]hdamon_attrs->aggr_interval}(hjD@hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj@@ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhj?hMhj?ubh and }(hj?hhhNhNubh)}(h6:c:type:`damon_attrs->sampling_interval `h]h)}(hje@h]hdamon_attrs->sampling_interval}(hjg@hhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjc@ubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhj?hMhj?ubh` in same ratio if the current access events observation ratio is lower than the target for each }(hj?hhhNhNubj)}(h **aggrs**h]haggrs}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubh aggregations, and vice versa.}(hj?hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj?hMhjhhubh)}(hNIf **aggrs** is zero, the tuning is disabled and hence this struct is ignored.h](hIf }(hj@hhhNhNubj)}(h **aggrs**h]haggrs}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj@ubhB is zero, the tuning is disabled and hence this struct is ignored.}(hj@hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_filter_type (C enum)c.damon_filter_typehNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(hdamon_filter_typeh]jB)}(henum damon_filter_typeh](jH)}(hjh]henum}(hj@hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj@hhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj@hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj@hhhj@hMubjk)}(hdamon_filter_typeh]jq)}(hj@h]hdamon_filter_type}(hj@hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj@ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj@hhhj@hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj@hhhj@hMubah}(h]j@ah ](jjeh"]h$]h&]jj)jhuh1j;hj@hMhj@hhubj)}(hhh]h)}(h4Type of :c:type:`struct damon_filter `h](hType of }(hjAhhhNhNubh)}(h,:c:type:`struct damon_filter `h]h)}(hj$Ah]hstruct damon_filter}(hj&AhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj"Aubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjj)}j]j4#)}j7#j@sbc.damon_filter_typeasbj damon_filteruh1hhj;#hKhjAubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjAhhubah}(h]h ]h"]h$]h&]uh1jhj@hhhj@hMubeh}(h]h ](jenumeh"]h$]h&]jjjjXAjjXAjjjuh1j6hhhjhj5hNubj)}(hs**Constants** ``DAMON_FILTER_TYPE_ANON`` Anonymous pages. ``DAMON_FILTER_TYPE_MEMCG`` Specific memcg's pages.h](h)}(h **Constants**h]j)}(hjbAh]h Constants}(hjdAhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj`Aubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj\Aubj7)}(hhh](j<)}(h,``DAMON_FILTER_TYPE_ANON`` Anonymous pages. h](jB)}(h``DAMON_FILTER_TYPE_ANON``h]h)}(hjAh]hDAMON_FILTER_TYPE_ANON}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjAubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj{Aubj\)}(hhh]h)}(hAnonymous pages.h]hAnonymous pages.}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjAhMhjAubah}(h]h ]h"]h$]h&]uh1j[hj{Aubeh}(h]h ]h"]h$]h&]uh1j;hjAhMhjxAubj<)}(h3``DAMON_FILTER_TYPE_MEMCG`` Specific memcg's pages.h](jB)}(h``DAMON_FILTER_TYPE_MEMCG``h]h)}(hjAh]hDAMON_FILTER_TYPE_MEMCG}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjAubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjAubj\)}(hhh]h)}(hSpecific memcg's pages.h]hSpecific memcg’s pages.}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjAubah}(h]h ]h"]h$]h&]uh1j[hjAubeh}(h]h ]h"]h$]h&]uh1j;hjAhMhjxAubeh}(h]h ]h"]h$]h&]uh1j6hj\Aubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_filter (C struct)c.damon_filterhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damon_filterh]jB)}(hstruct damon_filterh](jH)}(hjKh]hstruct}(hjBhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjBhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMubjZ)}(h h]h }(hj"BhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjBhhhj!BhMubjk)}(h damon_filterh]jq)}(hjBh]h damon_filter}(hj4BhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj0Bubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjBhhhj!BhMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj Bhhhj!BhMubah}(h]jBah ](jjeh"]h$]h&]jj)jhuh1j;hj!BhMhj Bhhubj)}(hhh]h)}(hCDAMON region filter for :c:type:`struct damon_probe `.h](hDAMON region filter for }(hjVBhhhNhNubh)}(h*:c:type:`struct damon_probe `h]h)}(hj`Bh]hstruct damon_probe}(hjbBhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj^Bubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjj)}j]j4#)}j7#jBsbc.damon_filterasbj damon_probeuh1hhj;#hKhjVBubh.}(hjVBhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjSBhhubah}(h]h ]h"]h$]h&]uh1jhj Bhhhj!BhMubeh}(h]h ](jstructeh"]h$]h&]jjjjBjjBjjjuh1j6hhhjhj5hNubj)}(hX**Definition**:: struct damon_filter { enum damon_filter_type type; bool matching; bool allow; union { u64 memcg_id; }; }; **Members** ``type`` Type of the region. ``matching`` Whether this filter is for the type-matching ones. ``allow`` Whether the **type**-**matching** ones should pass this filter. ``{unnamed_union}`` anonymous ``memcg_id`` Memcg id of the question if **type** is DAMON_FILTER_MEMCG.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjBubh:}(hjBhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjBubj)}(hstruct damon_filter { enum damon_filter_type type; bool matching; bool allow; union { u64 memcg_id; }; };h]hstruct damon_filter { enum damon_filter_type type; bool matching; bool allow; union { u64 memcg_id; }; };}hjBsbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjBubh)}(h **Members**h]j)}(hjBh]hMembers}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjBubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjBubj7)}(hhh](j<)}(h``type`` Type of the region. h](jB)}(h``type``h]h)}(hjBh]htype}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjBubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjBubj\)}(hhh]h)}(hType of the region.h]hType of the region.}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1hhjChMhjCubah}(h]h ]h"]h$]h&]uh1j[hjBubeh}(h]h ]h"]h$]h&]uh1j;hjChMhjBubj<)}(h@``matching`` Whether this filter is for the type-matching ones. h](jB)}(h ``matching``h]h)}(hj&Ch]hmatching}(hj(ChhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$Cubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhj Cubj\)}(hhh]h)}(h2Whether this filter is for the type-matching ones.h]h2Whether this filter is for the type-matching ones.}(hj?ChhhNhNubah}(h]h ]h"]h$]h&]uh1hhj;ChMhjnr_accesses ` for **aggr_interval** time. For each **aggr_interval**, the count is reset. DAMON also checks whether the target memory regions need update (e.g., by ``mmap()`` calls from the application, in case of virtual memory monitoring) and applies the changes for each **ops_update_interval**. All time intervals are in micro-seconds. Please refer to :c:type:`struct damon_operations ` and :c:type:`struct damon_call_control ` for more detail.h](h For each }(hjGhhhNhNubj)}(h**sample_interval**h]hsample_interval}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubhF, DAMON checks whether each region is accessed or not during the last }(hjGhhhNhNubj)}(h**sample_interval**h]hsample_interval}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubhK. If such access is found, DAMON aggregates the information by increasing }(hjGhhhNhNubh)}(h2:c:type:`damon_region->nr_accesses `h]h)}(hjGh]hdamon_region->nr_accesses}(hjGhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjGubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_regionuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMhjGubh for }(hjGhhhNhNubj)}(h**aggr_interval**h]h aggr_interval}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubh time. For each }(hjGhhhNhNubj)}(h**aggr_interval**h]h aggr_interval}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubha, the count is reset. DAMON also checks whether the target memory regions need update (e.g., by }(hjGhhhNhNubh)}(h ``mmap()``h]hmmap()}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjGubhd calls from the application, in case of virtual memory monitoring) and applies the changes for each }(hjGhhhNhNubj)}(h**ops_update_interval**h]hops_update_interval}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubh=. All time intervals are in micro-seconds. Please refer to }(hjGhhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hj)Hh]hstruct damon_operations}(hj+HhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj'Hubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhjGhMhjGubh and }(hjGhhhNhNubh)}(h8:c:type:`struct damon_call_control `h]h)}(hjLHh]hstruct damon_call_control}(hjNHhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjJHubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_call_controluh1hhjGhMhjGubh for more detail.}(hjGhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjGhMhjhhubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_ctx (C struct) c.damon_ctxhNtauh1j$hjhhhj5hNubj7)}(hhh](j<)}(h damon_ctxh]jB)}(hstruct damon_ctxh](jH)}(hjKh]hstruct}(hjHhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjHhhhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM+ubjZ)}(h h]h }(hjHhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjHhhhjHhM+ubjk)}(h damon_ctxh]jq)}(hjHh]h damon_ctx}(hjHhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjHubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjHhhhjHhM+ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjHhhhjHhM+ubah}(h]jHah ](jjeh"]h$]h&]jj)jhuh1j;hjHhM+hjHhhubj)}(hhh]h)}(hRepresents a context for each monitoring. This is the main interface that allows users to set the attributes and get the results of the monitoring.h]hRepresents a context for each monitoring. This is the main interface that allows users to set the attributes and get the results of the monitoring.}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhM>hjHhhubah}(h]h ]h"]h$]h&]uh1jhjHhhhjHhM+ubeh}(h]h ](jstructeh"]h$]h&]jjjjHjjHjjjuh1j6hhhjhj5hNubj)}(hX**Definition**:: struct damon_ctx { struct damon_attrs attrs; unsigned long addr_unit; unsigned long min_region_sz; bool pause; }; **Members** ``attrs`` Monitoring attributes for accuracy/overhead control. ``addr_unit`` Scale factor for core to ops address conversion. ``min_region_sz`` Minimum region size. ``pause`` Pause kdamond main loop.h](h)}(h**Definition**::h](j)}(h**Definition**h]h Definition}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjHubh:}(hjHhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMBhjHubj)}(hstruct damon_ctx { struct damon_attrs attrs; unsigned long addr_unit; unsigned long min_region_sz; bool pause; };h]hstruct damon_ctx { struct damon_attrs attrs; unsigned long addr_unit; unsigned long min_region_sz; bool pause; };}hj Isbah}(h]h ]h"]h$]h&]hhuh1j hR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMDhjHubh)}(h **Members**h]j)}(hjIh]hMembers}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMKhjHubj7)}(hhh](j<)}(h?``attrs`` Monitoring attributes for accuracy/overhead control. h](jB)}(h ``attrs``h]h)}(hj;Ih]hattrs}(hj=IhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj9Iubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMChj5Iubj\)}(hhh]h)}(h4Monitoring attributes for accuracy/overhead control.h]h4Monitoring attributes for accuracy/overhead control.}(hjTIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjPIhMChjQIubah}(h]h ]h"]h$]h&]uh1j[hj5Iubeh}(h]h ]h"]h$]h&]uh1j;hjPIhMChj2Iubj<)}(h?``addr_unit`` Scale factor for core to ops address conversion. h](jB)}(h ``addr_unit``h]h)}(hjtIh]h addr_unit}(hjvIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjrIubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMShjnIubj\)}(hhh]h)}(h0Scale factor for core to ops address conversion.h]h0Scale factor for core to ops address conversion.}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjIhMShjIubah}(h]h ]h"]h$]h&]uh1j[hjnIubeh}(h]h ]h"]h$]h&]uh1j;hjIhMShj2Iubj<)}(h'``min_region_sz`` Minimum region size. h](jB)}(h``min_region_sz``h]h)}(hjIh]h min_region_sz}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjIubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMThjIubj\)}(hhh]h)}(hMinimum region size.h]hMinimum region size.}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjIhMThjIubah}(h]h ]h"]h$]h&]uh1j[hjIubeh}(h]h ]h"]h$]h&]uh1j;hjIhMThj2Iubj<)}(h"``pause`` Pause kdamond main loop.h](jB)}(h ``pause``h]h)}(hjIh]hpause}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjIubah}(h]h ]h"]h$]h&]uh1jAhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMThjIubj\)}(hhh]h)}(hPause kdamond main loop.h]hPause kdamond main loop.}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMUhjIubah}(h]h ]h"]h$]h&]uh1j[hjIubeh}(h]h ]h"]h$]h&]uh1j;hjIhMThj2Iubeh}(h]h ]h"]h$]h&]uh1j6hjHubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjhhhj5hNubh)}(h**Description**h]j)}(hj)Jh]h Description}(hj+JhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj'Jubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMXhjhhubh)}(hFor each monitoring context, one kernel thread for the monitoring, namely kdamond, is created. The pid of kdamond can be retrieved using damon_kdamond_pid().h]hFor each monitoring context, one kernel thread for the monitoring, namely kdamond, is created. The pid of kdamond can be retrieved using damon_kdamond_pid().}(hj?JhhhNhNubah}(h]h ]h"]h$]h&]uh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMChjhhubh)}(hXpOnce started, kdamond runs until explicitly required to be terminated or every monitoring target is invalid. The validity of the targets is checked via the :c:type:`damon_operations.target_valid ` of **ops**. The termination can also be explicitly requested by calling damon_stop(). To know if a kdamond is running, damon_is_running() can be used.h](hOnce started, kdamond runs until explicitly required to be terminated or every monitoring target is invalid. The validity of the targets is checked via the }(hjNJhhhNhNubh)}(h::c:type:`damon_operations.target_valid `h]h)}(hjXJh]hdamon_operations.target_valid}(hjZJhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjVJubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMGhjNJubh of }(hjNJhhhNhNubj)}(h**ops**h]hops}(hjzJhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNJubh. The termination can also be explicitly requested by calling damon_stop(). To know if a kdamond is running, damon_is_running() can be used.}(hjNJhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjuJhMGhjhhubh)}(hWhile the kdamond is running, all accesses to :c:type:`struct damon_ctx ` from a thread other than the kdamond should be made using safe DAMON APIs, including damon_call() and damos_walk().h](h.While the kdamond is running, all accesses to }(hjJhhhNhNubh)}(h&:c:type:`struct damon_ctx `h]h)}(hjJh]hstruct damon_ctx}(hjJhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjJubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_ctxuh1hhR/var/lib/git/docbuild/linux/Documentation/mm/damon/api:14: ./include/linux/damon.hhMMhjJubht from a thread other than the kdamond should be made using safe DAMON APIs, including damon_call() and damos_walk().}(hjJhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjJhMMhjhhubeh}(h] structuresah ]h"] structuresah$]h&]uh1hhhhhhhhK ubh)}(hhh](h)}(h Functionsh]h Functions}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjJhhhhhKubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1$damon_is_registered_ops (C function)c.damon_is_registered_opshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h3bool damon_is_registered_ops (enum damon_ops_id id)h]jB)}(h2bool damon_is_registered_ops(enum damon_ops_id id)h](hdesc_sig_keyword_type)}(hboolh]hbool}(hjJhhhNhNubah}(h]h ]ktah"]h$]h&]uh1jJhjJhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK-ubjZ)}(h h]h }(hjKhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjJhhhjKhK-ubjk)}(hdamon_is_registered_opsh]jq)}(hdamon_is_registered_opsh]hdamon_is_registered_ops}(hjKhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjKubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjJhhhjKhK-ubhdesc_parameterlist)}(h(enum damon_ops_id id)h]hdesc_parameter)}(henum damon_ops_id idh](jH)}(hjh]henum}(hj:KhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj6KubjZ)}(h h]h }(hjGKhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj6Kubh)}(hhh]jq)}(h damon_ops_idh]h damon_ops_id}(hjXKhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjUKubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjZKmodnameN classnameNjj)}j]j4#)}j7#jKsbc.damon_is_registered_opsasbuh1hhj6KubjZ)}(h h]h }(hjxKhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj6Kubjq)}(hidh]hid}(hjKhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj6Kubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj0Kubah}(h]h ]h"]h$]h&]hhuh1j.KhjJhhhjKhK-ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjJhhhjKhK-ubah}(h]jJah ](jjeh"]h$]h&]jj)jhuh1j;hjKhK-hjJhhubj)}(hhh]h)}(h0Check if a given damon_operations is registered.h]h0Check if a given damon_operations is registered.}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK-hjKhhubah}(h]h ]h"]h$]h&]uh1jhjJhhhjKhK-ubeh}(h]h ](jfunctioneh"]h$]h&]jjjjKjjKjjjuh1j6hhhjJhNhNubj)}(h**Parameters** ``enum damon_ops_id id`` Id of the damon_operations to check if registered. **Return** true if the ops is set, false otherwise.h](h)}(h**Parameters**h]j)}(hjKh]h Parameters}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjKubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK1hjKubj7)}(hhh]j<)}(hL``enum damon_ops_id id`` Id of the damon_operations to check if registered. h](jB)}(h``enum damon_ops_id id``h]h)}(hjKh]henum damon_ops_id id}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjKubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK.hjKubj\)}(hhh]h)}(h2Id of the damon_operations to check if registered.h]h2Id of the damon_operations to check if registered.}(hj LhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjLhK.hjLubah}(h]h ]h"]h$]h&]uh1j[hjKubeh}(h]h ]h"]h$]h&]uh1j;hjLhK.hjKubah}(h]h ]h"]h$]h&]uh1j6hjKubh)}(h **Return**h]j)}(hj,Lh]hReturn}(hj.LhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*Lubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK0hjKubh)}(h(true if the ops is set, false otherwise.h]h(true if the ops is set, false otherwise.}(hjBLhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK0hjKubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_register_ops (C function)c.damon_register_opshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h5int damon_register_ops (struct damon_operations *ops)h]jB)}(h4int damon_register_ops(struct damon_operations *ops)h](jJ)}(hinth]hint}(hjqLhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjmLhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK?ubjZ)}(h h]h }(hjLhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjmLhhhjLhK?ubjk)}(hdamon_register_opsh]jq)}(hdamon_register_opsh]hdamon_register_ops}(hjLhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjLubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjmLhhhjLhK?ubj/K)}(h(struct damon_operations *ops)h]j5K)}(hstruct damon_operations *opsh](jH)}(hjKh]hstruct}(hjLhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjLubjZ)}(h h]h }(hjLhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjLubh)}(hhh]jq)}(hdamon_operationsh]hdamon_operations}(hjLhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjLubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjLmodnameN classnameNjj)}j]j4#)}j7#jLsbc.damon_register_opsasbuh1hhjLubjZ)}(h h]h }(hjLhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjLubhdesc_sig_punctuation)}(h*h]h*}(hjLhhhNhNubah}(h]h ]pah"]h$]h&]uh1jLhjLubjq)}(hopsh]hops}(hj MhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjLubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjLubah}(h]h ]h"]h$]h&]hhuh1j.KhjmLhhhjLhK?ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjiLhhhjLhK?ubah}(h]jdLah ](jjeh"]h$]h&]jj)jhuh1j;hjLhK?hjfLhhubj)}(hhh]h)}(h.Register a monitoring operations set to DAMON.h]h.Register a monitoring operations set to DAMON.}(hj5MhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK?hj2Mhhubah}(h]h ]h"]h$]h&]uh1jhjfLhhhjLhK?ubeh}(h]h ](jfunctioneh"]h$]h&]jjjjMMjjMMjjjuh1j6hhhjJhNhNubj)}(hXG**Parameters** ``struct damon_operations *ops`` monitoring operations set to register. **Description** This function registers a monitoring operations set of valid :c:type:`struct damon_operations `->id so that others can find and use them later. **Return** 0 on success, negative error code otherwise.h](h)}(h**Parameters**h]j)}(hjWMh]h Parameters}(hjYMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjUMubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKChjQMubj7)}(hhh]j<)}(hH``struct damon_operations *ops`` monitoring operations set to register. h](jB)}(h ``struct damon_operations *ops``h]h)}(hjvMh]hstruct damon_operations *ops}(hjxMhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjtMubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chK@hjpMubj\)}(hhh]h)}(h&monitoring operations set to register.h]h&monitoring operations set to register.}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjMhK@hjMubah}(h]h ]h"]h$]h&]uh1j[hjpMubeh}(h]h ]h"]h$]h&]uh1j;hjMhK@hjmMubah}(h]h ]h"]h$]h&]uh1j6hjQMubh)}(h**Description**h]j)}(hjMh]h Description}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjMubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKBhjQMubh)}(hThis function registers a monitoring operations set of valid :c:type:`struct damon_operations `->id so that others can find and use them later.h](h=This function registers a monitoring operations set of valid }(hjMhhhNhNubh)}(h4:c:type:`struct damon_operations `h]h)}(hjMh]hstruct damon_operations}(hjMhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjMubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKAhjMubh0->id so that others can find and use them later.}(hjMhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjMhKAhjQMubh)}(h **Return**h]j)}(hjMh]hReturn}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjMubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKDhjQMubh)}(h,0 on success, negative error code otherwise.h]h,0 on success, negative error code otherwise.}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKEhjQMubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_select_ops (C function)c.damon_select_opshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hBint damon_select_ops (struct damon_ctx *ctx, enum damon_ops_id id)h]jB)}(hAint damon_select_ops(struct damon_ctx *ctx, enum damon_ops_id id)h](jJ)}(hinth]hint}(hj@NhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjaggr_interval `) the region was found to be accessed. Hence the value can be interpreted as the relative access frequency score of the region (**r**). The value is calculated as a pseudo moving sum, and hence it is not an exact value but just a best-effort reasonable estimation. **Return** the pseudo moving sum access frequency score.h](h)}(h**Parameters**h]j)}(hjRh]h Parameters}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKhjRubj7)}(hhh](j<)}(hB``struct damon_region *r`` Region to get the access frequency of. h](jB)}(h``struct damon_region *r``h]h)}(hj5Rh]hstruct damon_region *r}(hj7RhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj3Rubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKhj/Rubj\)}(hhh]h)}(h&Region to get the access frequency of.h]h&Region to get the access frequency of.}(hjNRhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjJRhKhjKRubah}(h]h ]h"]h$]h&]uh1j[hj/Rubeh}(h]h ]h"]h$]h&]uh1j;hjJRhKhj,Rubj<)}(h2``struct damon_ctx *ctx`` DAMON context of **r**. h](jB)}(h``struct damon_ctx *ctx``h]h)}(hjnRh]hstruct damon_ctx *ctx}(hjpRhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjlRubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKhjhRubj\)}(hhh]h)}(hDAMON context of **r**.h](hDAMON context of }(hjRhhhNhNubj)}(h**r**h]hr}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRubh.}(hjRhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjRhKhjRubah}(h]h ]h"]h$]h&]uh1j[hjhRubeh}(h]h ]h"]h$]h&]uh1j;hjRhKhj,Rubeh}(h]h ]h"]h$]h&]uh1j6hjRubh)}(h**Description**h]j)}(hjRh]h Description}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKhjRubh)}(hXThis function returns for how many sampling iterations in the last aggregation interval (:c:type:`damon_attrs->aggr_interval `) the region was found to be accessed. Hence the value can be interpreted as the relative access frequency score of the region (**r**). The value is calculated as a pseudo moving sum, and hence it is not an exact value but just a best-effort reasonable estimation.h](hYThis function returns for how many sampling iterations in the last aggregation interval (}(hjRhhhNhNubh)}(h2:c:type:`damon_attrs->aggr_interval `h]h)}(hjRh]hdamon_attrs->aggr_interval}(hjRhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjRubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_attrsuh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKhjRubh) the region was found to be accessed. Hence the value can be interpreted as the relative access frequency score of the region (}(hjRhhhNhNubj)}(h**r**h]hr}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRubh). The value is calculated as a pseudo moving sum, and hence it is not an exact value but just a best-effort reasonable estimation.}(hjRhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjRhKhjRubh)}(h **Return**h]j)}(hjSh]hReturn}(hjShhhNhNubah}(h]h ]h"]h$]h&]uh1jhjSubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjRubh)}(h-the pseudo moving sum access frequency score.h]h-the pseudo moving sum access frequency score.}(hj-ShhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjRubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1"damon_probe_hits_wsum (C function)c.damon_probe_hits_wsumhNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h]unsigned int damon_probe_hits_wsum (struct damon_region *r, bool last, struct damon_ctx *ctx)h]jB)}(h\unsigned int damon_probe_hits_wsum(struct damon_region *r, bool last, struct damon_ctx *ctx)h](jJ)}(hunsignedh]hunsigned}(hj\ShhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjXShhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hjkShhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjXShhhjjShMubjJ)}(hinth]hint}(hjyShhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjXShhhjjShMubjZ)}(h h]h }(hjShhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjXShhhjjShMubjk)}(hdamon_probe_hits_wsumh]jq)}(hdamon_probe_hits_wsumh]hdamon_probe_hits_wsum}(hjShhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjSubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjXShhhjjShMubj/K)}(h:(struct damon_region *r, bool last, struct damon_ctx *ctx)h](j5K)}(hstruct damon_region *rh](jH)}(hjKh]hstruct}(hjShhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjSubjZ)}(h h]h }(hjShhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjSubh)}(hhh]jq)}(h damon_regionh]h damon_region}(hjShhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjSubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjSmodnameN classnameNjj)}j]j4#)}j7#jSsbc.damon_probe_hits_wsumasbuh1hhjSubjZ)}(h h]h }(hjShhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjSubjL)}(hjLh]h*}(hjThhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjSubjq)}(hj\Qh]hr}(hjThhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjSubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjSubj5K)}(h bool lasth](jJ)}(hjJh]hbool}(hj&ThhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj"TubjZ)}(h h]h }(hj3ThhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj"Tubjq)}(hlasth]hlast}(hjAThhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj"Tubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjSubj5K)}(hstruct damon_ctx *ctxh](jH)}(hjKh]hstruct}(hjZThhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjVTubjZ)}(h h]h }(hjgThhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjVTubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hjxThhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjuTubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjzTmodnameN classnameNjj)}j]jSc.damon_probe_hits_wsumasbuh1hhjVTubjZ)}(h h]h }(hjThhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjVTubjL)}(hjLh]h*}(hjThhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjVTubjq)}(hctxh]hctx}(hjThhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjVTubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjSubeh}(h]h ]h"]h$]h&]hhuh1j.KhjXShhhjjShMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjTShhhjjShMubah}(h]jOSah ](jjeh"]h$]h&]jj)jhuh1j;hjjShMhjQShhubj)}(hhh]h)}(h,Returns probe hits weighted sum of a region.h]h,Returns probe hits weighted sum of a region.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjThhubah}(h]h ]h"]h$]h&]uh1jhjQShhhjjShMubeh}(h]h ](jfunctioneh"]h$]h&]jjjjTjjTjjjuh1j6hhhjJhNhNubj)}(hX **Parameters** ``struct damon_region *r`` region to get the weighted sum of. ``bool last`` if the request is for last-window aggregated probe hits. ``struct damon_ctx *ctx`` context of :c:type:`r`. **Return** the weighted sum of probe hits of the region.h](h)}(h**Parameters**h]j)}(hjTh]h Parameters}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1jhjTubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjTubj7)}(hhh](j<)}(h>``struct damon_region *r`` region to get the weighted sum of. h](jB)}(h``struct damon_region *r``h]h)}(hjUh]hstruct damon_region *r}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjUubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjUubj\)}(hhh]h)}(h"region to get the weighted sum of.h]h"region to get the weighted sum of.}(hj5UhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1UhMhj2Uubah}(h]h ]h"]h$]h&]uh1j[hjUubeh}(h]h ]h"]h$]h&]uh1j;hj1UhMhjUubj<)}(hG``bool last`` if the request is for last-window aggregated probe hits. h](jB)}(h ``bool last``h]h)}(hjUUh]h bool last}(hjWUhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjSUubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjOUubj\)}(hhh]h)}(h8if the request is for last-window aggregated probe hits.h]h8if the request is for last-window aggregated probe hits.}(hjnUhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjjUhMhjkUubah}(h]h ]h"]h$]h&]uh1j[hjOUubeh}(h]h ]h"]h$]h&]uh1j;hjjUhMhjUubj<)}(h2``struct damon_ctx *ctx`` context of :c:type:`r`. h](jB)}(h``struct damon_ctx *ctx``h]h)}(hjUh]hstruct damon_ctx *ctx}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjUubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjUubj\)}(hhh]h)}(hcontext of :c:type:`r`.h](h context of }(hjUhhhNhNubh)}(h :c:type:`r`h]h)}(hjUh]hr}(hjUhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjUubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjj\Quh1hhjUhMhjUubh.}(hjUhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjUhMhjUubah}(h]h ]h"]h$]h&]uh1j[hjUubeh}(h]h ]h"]h$]h&]uh1j;hjUhMhjUubeh}(h]h ]h"]h$]h&]uh1j6hjTubh)}(h **Return**h]j)}(hjUh]hReturn}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjUubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjTubh)}(h-the weighted sum of probe hits of the region.h]h-the weighted sum of probe hits of the region.}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjTubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1!damos_filter_for_ops (C function)c.damos_filter_for_opshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h7bool damos_filter_for_ops (enum damos_filter_type type)h]jB)}(h6bool damos_filter_for_ops(enum damos_filter_type type)h](jJ)}(hjJh]hbool}(hj0VhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj,VhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMIubjZ)}(h h]h }(hj>VhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj,Vhhhj=VhMIubjk)}(hdamos_filter_for_opsh]jq)}(hdamos_filter_for_opsh]hdamos_filter_for_ops}(hjPVhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjLVubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj,Vhhhj=VhMIubj/K)}(h(enum damos_filter_type type)h]j5K)}(henum damos_filter_type typeh](jH)}(hjh]henum}(hjlVhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhVubjZ)}(h h]h }(hjyVhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhVubh)}(hhh]jq)}(hdamos_filter_typeh]hdamos_filter_type}(hjVhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjVubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjVmodnameN classnameNjj)}j]j4#)}j7#jRVsbc.damos_filter_for_opsasbuh1hhjhVubjZ)}(h h]h }(hjVhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhVubjq)}(htypeh]htype}(hjVhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjhVubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjdVubah}(h]h ]h"]h$]h&]hhuh1j.Khj,Vhhhj=VhMIubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj(Vhhhj=VhMIubah}(h]j#Vah ](jjeh"]h$]h&]jj)jhuh1j;hj=VhMIhj%Vhhubj)}(hhh]h)}(h(Return if the filter is ops-handled one.h]h(Return if the filter is ops-handled one.}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMIhjVhhubah}(h]h ]h"]h$]h&]uh1jhj%Vhhhj=VhMIubeh}(h]h ](jfunctioneh"]h$]h&]jjjjVjjVjjjuh1j6hhhjJhNhNubj)}(h**Parameters** ``enum damos_filter_type type`` type of the filter. **Return** true if the filter of **type** needs to be handled by ops layer, false otherwise.h](h)}(h**Parameters**h]j)}(hjWh]h Parameters}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjWubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMMhjVubj7)}(hhh]j<)}(h4``enum damos_filter_type type`` type of the filter. h](jB)}(h``enum damos_filter_type type``h]h)}(hj#Wh]henum damos_filter_type type}(hj%WhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!Wubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMJhjWubj\)}(hhh]h)}(htype of the filter.h]htype of the filter.}(hjXhhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjWubjq)}(hctxh]hctx}(hjKXhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjWubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjWubj5K)}(hstruct damon_attrs *attrsh](jH)}(hjKh]hstruct}(hjdXhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj`XubjZ)}(h h]h }(hjqXhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj`Xubh)}(hhh]jq)}(h damon_attrsh]h damon_attrs}(hjXhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjXubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjXmodnameN classnameNjj)}j]j,Xc.damon_set_attrsasbuh1hhj`XubjZ)}(h h]h }(hjXhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj`XubjL)}(hjLh]h*}(hjXhhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj`Xubjq)}(hattrsh]hattrs}(hjXhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj`Xubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjWubeh}(h]h ]h"]h$]h&]hhuh1j.KhjWhhhjWhMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjWhhhjWhMubah}(h]jWah ](jjeh"]h$]h&]jj)jhuh1j;hjWhMhjWhhubj)}(hhh]h)}(h"Set attributes for the monitoring.h]h"Set attributes for the monitoring.}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjXhhubah}(h]h ]h"]h$]h&]uh1jhjWhhhjWhMubeh}(h]h ](jfunctioneh"]h$]h&]jjjjXjjXjjjuh1j6hhhjJhNhNubj)}(hX_**Parameters** ``struct damon_ctx *ctx`` monitoring context ``struct damon_attrs *attrs`` monitoring attributes **Description** This function updates monitoring results and next monitoring/damos operation schedules. Because those are periodically updated by kdamond, this should be called from a safe contexts. Such contexts include damon_ctx setup time while the kdamond is not yet started, and inside of kdamond_fn(). In detail, all DAMON API callers directly call this function for initial setup of damon_ctx before calling damon_start(). Some of the API callers also indirectly call this function via damon_call() -> damon_commit() for online parameters updates. Finally, kdamond_fn() itself use this for applying auto-tuned monitoring intervals. Every time interval is in micro-seconds. **Return** 0 on success, negative error code otherwise.h](h)}(h**Parameters**h]j)}(hjYh]h Parameters}(hj YhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjYubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM hjYubj7)}(hhh](j<)}(h-``struct damon_ctx *ctx`` monitoring context h](jB)}(h``struct damon_ctx *ctx``h]h)}(hj&Yh]hstruct damon_ctx *ctx}(hj(YhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$Yubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj Yubj\)}(hhh]h)}(hmonitoring contexth]hmonitoring context}(hj?YhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj;YhMhj damon_commit() for online parameters updates. Finally, kdamond_fn() itself use this for applying auto-tuned monitoring intervals.h]hXLIn detail, all DAMON API callers directly call this function for initial setup of damon_ctx before calling damon_start(). Some of the API callers also indirectly call this function via damon_call() -> damon_commit() for online parameters updates. Finally, kdamond_fn() itself use this for applying auto-tuned monitoring intervals.}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM hjYubh)}(h(Every time interval is in micro-seconds.h]h(Every time interval is in micro-seconds.}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjYubh)}(h **Return**h]j)}(hjYh]hReturn}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjYubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjYubh)}(h,0 on success, negative error code otherwise.h]h,0 on success, negative error code otherwise.}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjYubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_set_schemes (C function)c.damon_set_schemeshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hZvoid damon_set_schemes (struct damon_ctx *ctx, struct damos **schemes, ssize_t nr_schemes)h]jB)}(hYvoid damon_set_schemes(struct damon_ctx *ctx, struct damos **schemes, ssize_t nr_schemes)h](jJ)}(hvoidh]hvoid}(hj$ZhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj ZhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM@ubjZ)}(h h]h }(hj3ZhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj Zhhhj2ZhM@ubjk)}(hdamon_set_schemesh]jq)}(hdamon_set_schemesh]hdamon_set_schemes}(hjEZhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjAZubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj Zhhhj2ZhM@ubj/K)}(hC(struct damon_ctx *ctx, struct damos **schemes, ssize_t nr_schemes)h](j5K)}(hstruct damon_ctx *ctxh](jH)}(hjKh]hstruct}(hjaZhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj]ZubjZ)}(h h]h }(hjnZhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj]Zubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hjZhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj|Zubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjZmodnameN classnameNjj)}j]j4#)}j7#jGZsbc.damon_set_schemesasbuh1hhj]ZubjZ)}(h h]h }(hjZhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj]ZubjL)}(hjLh]h*}(hjZhhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj]Zubjq)}(hctxh]hctx}(hjZhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj]Zubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjYZubj5K)}(hstruct damos **schemesh](jH)}(hjKh]hstruct}(hjZhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjZubjZ)}(h h]h }(hjZhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjZubh)}(hhh]jq)}(hdamosh]hdamos}(hjZhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjZubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjZmodnameN classnameNjj)}j]jZc.damon_set_schemesasbuh1hhjZubjZ)}(h h]h }(hj[hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjZubjL)}(hjLh]h*}(hj[hhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjZubjL)}(hjLh]h*}(hj*[hhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjZubjq)}(hschemesh]hschemes}(hj7[hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjZubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjYZubj5K)}(hssize_t nr_schemesh](h)}(hhh]jq)}(hssize_th]hssize_t}(hjS[hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjP[ubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjU[modnameN classnameNjj)}j]jZc.damon_set_schemesasbuh1hhjL[ubjZ)}(h h]h }(hjq[hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjL[ubjq)}(h nr_schemesh]h nr_schemes}(hj[hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjL[ubeh}(h]h ]h"]h$]h&]noemphhhuh1j4KhjYZubeh}(h]h ]h"]h$]h&]hhuh1j.Khj Zhhhj2ZhM@ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjZhhhj2ZhM@ubah}(h]jZah ](jjeh"]h$]h&]jj)jhuh1j;hj2ZhM@hjZhhubj)}(hhh]h)}(h3Set data access monitoring based operation schemes.h]h3Set data access monitoring based operation schemes.}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM@hj[hhubah}(h]h ]h"]h$]h&]uh1jhjZhhhj2ZhM@ubeh}(h]h ](jfunctioneh"]h$]h&]jjjj[jj[jjjuh1j6hhhjJhNhNubj)}(hX**Parameters** ``struct damon_ctx *ctx`` monitoring context ``struct damos **schemes`` array of the schemes ``ssize_t nr_schemes`` number of entries in **schemes** **Description** This function should not be called while the kdamond of the context is running.h](h)}(h**Parameters**h]j)}(hj[h]h Parameters}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj[ubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMDhj[ubj7)}(hhh](j<)}(h-``struct damon_ctx *ctx`` monitoring context h](jB)}(h``struct damon_ctx *ctx``h]h)}(hj[h]hstruct damon_ctx *ctx}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj[ubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMAhj[ubj\)}(hhh]h)}(hmonitoring contexth]hmonitoring context}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj[hMAhj\ubah}(h]h ]h"]h$]h&]uh1j[hj[ubeh}(h]h ]h"]h$]h&]uh1j;hj[hMAhj[ubj<)}(h0``struct damos **schemes`` array of the schemes h](jB)}(h``struct damos **schemes``h]h)}(hj#\h]hstruct damos **schemes}(hj%\hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!\ubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMBhj\ubj\)}(hhh]h)}(harray of the schemesh]harray of the schemes}(hj<\hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj8\hMBhj9\ubah}(h]h ]h"]h$]h&]uh1j[hj\ubeh}(h]h ]h"]h$]h&]uh1j;hj8\hMBhj[ubj<)}(h8``ssize_t nr_schemes`` number of entries in **schemes** h](jB)}(h``ssize_t nr_schemes``h]h)}(hj\\h]hssize_t nr_schemes}(hj^\hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZ\ubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMChjV\ubj\)}(hhh]h)}(h number of entries in **schemes**h](hnumber of entries in }(hju\hhhNhNubj)}(h **schemes**h]hschemes}(hj}\hhhNhNubah}(h]h ]h"]h$]h&]uh1jhju\ubeh}(h]h ]h"]h$]h&]uh1hhjq\hMChjr\ubah}(h]h ]h"]h$]h&]uh1j[hjV\ubeh}(h]h ]h"]h$]h&]uh1j;hjq\hMChj[ubeh}(h]h ]h"]h$]h&]uh1j6hj[ubh)}(h**Description**h]j)}(hj\h]h Description}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMEhj[ubh)}(hOThis function should not be called while the kdamond of the context is running.h]hOThis function should not be called while the kdamond of the context is running.}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMDhj[ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1%damos_commit_quota_goals (C function)c.damos_commit_quota_goalshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hOint damos_commit_quota_goals (struct damos_quota *dst, struct damos_quota *src)h]jB)}(hNint damos_commit_quota_goals(struct damos_quota *dst, struct damos_quota *src)h](jJ)}(hinth]hint}(hj\hhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj\hhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hj\hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj\hhhj\hMubjk)}(hdamos_commit_quota_goalsh]jq)}(hdamos_commit_quota_goalsh]hdamos_commit_quota_goals}(hj ]hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj]ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj\hhhj\hMubj/K)}(h2(struct damos_quota *dst, struct damos_quota *src)h](j5K)}(hstruct damos_quota *dsth](jH)}(hjKh]hstruct}(hj']hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj#]ubjZ)}(h h]h }(hj4]hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj#]ubh)}(hhh]jq)}(h damos_quotah]h damos_quota}(hjE]hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjB]ubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjG]modnameN classnameNjj)}j]j4#)}j7#j ]sbc.damos_commit_quota_goalsasbuh1hhj#]ubjZ)}(h h]h }(hje]hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj#]ubjL)}(hjLh]h*}(hjs]hhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj#]ubjq)}(hdsth]hdst}(hj]hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj#]ubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj]ubj5K)}(hstruct damos_quota *srch](jH)}(hjKh]hstruct}(hj]hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj]ubjZ)}(h h]h }(hj]hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj]ubh)}(hhh]jq)}(h damos_quotah]h damos_quota}(hj]hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj]ubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetj]modnameN classnameNjj)}j]ja]c.damos_commit_quota_goalsasbuh1hhj]ubjZ)}(h h]h }(hj]hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj]ubjL)}(hjLh]h*}(hj]hhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj]ubjq)}(hsrch]hsrc}(hj]hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj]ubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj]ubeh}(h]h ]h"]h$]h&]hhuh1j.Khj\hhhj\hMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj\hhhj\hMubah}(h]j\ah ](jjeh"]h$]h&]jj)jhuh1j;hj\hMhj\hhubj)}(hhh]h)}(h*Commit DAMOS quota goals to another quota.h]h*Commit DAMOS quota goals to another quota.}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj^hhubah}(h]h ]h"]h$]h&]uh1jhj\hhhj\hMubeh}(h]h ](jfunctioneh"]h$]h&]jjjj2^jj2^jjjuh1j6hhhjJhNhNubj)}(hX**Parameters** ``struct damos_quota *dst`` The commit destination DAMOS quota. ``struct damos_quota *src`` The commit source DAMOS quota. **Description** Copies user-specified parameters for quota goals from **src** to **dst**. Users should use this function for quota goals-level parameters update of running DAMON contexts, instead of manual in-place updates. This function should be called from parameters-update safe context, like damon_call().h](h)}(h**Parameters**h]j)}(hj<^h]h Parameters}(hj>^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj:^ubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj6^ubj7)}(hhh](j<)}(h@``struct damos_quota *dst`` The commit destination DAMOS quota. h](jB)}(h``struct damos_quota *dst``h]h)}(hj[^h]hstruct damos_quota *dst}(hj]^hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjY^ubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjU^ubj\)}(hhh]h)}(h#The commit destination DAMOS quota.h]h#The commit destination DAMOS quota.}(hjt^hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjp^hMhjq^ubah}(h]h ]h"]h$]h&]uh1j[hjU^ubeh}(h]h ]h"]h$]h&]uh1j;hjp^hMhjR^ubj<)}(h;``struct damos_quota *src`` The commit source DAMOS quota. h](jB)}(h``struct damos_quota *src``h]h)}(hj^h]hstruct damos_quota *src}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^ubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj^ubj\)}(hhh]h)}(hThe commit source DAMOS quota.h]hThe commit source DAMOS quota.}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^hMhj^ubah}(h]h ]h"]h$]h&]uh1j[hj^ubeh}(h]h ]h"]h$]h&]uh1j;hj^hMhjR^ubeh}(h]h ]h"]h$]h&]uh1j6hj6^ubh)}(h**Description**h]j)}(hj^h]h Description}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj^ubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj6^ubh)}(hCopies user-specified parameters for quota goals from **src** to **dst**. Users should use this function for quota goals-level parameters update of running DAMON contexts, instead of manual in-place updates.h](h6Copies user-specified parameters for quota goals from }(hj^hhhNhNubj)}(h**src**h]hsrc}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj^ubh to }(hj^hhhNhNubj)}(h**dst**h]hdst}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj^ubh. Users should use this function for quota goals-level parameters update of running DAMON contexts, instead of manual in-place updates.}(hj^hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj6^ubh)}(hVThis function should be called from parameters-update safe context, like damon_call().h]hVThis function should be called from parameters-update safe context, like damon_call().}(hj_hhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj6^ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1)damos_filters_default_reject (C function)c.damos_filters_default_rejecthNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h=bool damos_filters_default_reject (struct list_head *filters)h]jB)}(h`ubah}(h]h ]h"]h$]h&]uh1j6hj"`ubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_commit_ctx (C function)c.damon_commit_ctxhNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hCint damon_commit_ctx (struct damon_ctx *dst, struct damon_ctx *src)h]jB)}(hBint damon_commit_ctx(struct damon_ctx *dst, struct damon_ctx *src)h](jJ)}(hinth]hint}(hj`hhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj`hhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM"ubjZ)}(h h]h }(hj`hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj`hhhj`hM"ubjk)}(hdamon_commit_ctxh]jq)}(hdamon_commit_ctxh]hdamon_commit_ctx}(hj`hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj`ubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj`hhhj`hM"ubj/K)}(h.(struct damon_ctx *dst, struct damon_ctx *src)h](j5K)}(hstruct damon_ctx *dsth](jH)}(hjKh]hstruct}(hj`hhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj`ubjZ)}(h h]h }(hj`hhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj`ubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hj`hhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj`ubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetj`modnameN classnameNjj)}j]j4#)}j7#j`sbc.damon_commit_ctxasbuh1hhj`ubjZ)}(h h]h }(hjahhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj`ubjL)}(hjLh]h*}(hj*ahhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj`ubjq)}(hdsth]hdst}(hj7ahhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj`ubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj`ubj5K)}(hstruct damon_ctx *srch](jH)}(hjKh]hstruct}(hjPahhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjLaubjZ)}(h h]h }(hj]ahhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjLaubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hjnahhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjkaubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjpamodnameN classnameNjj)}j]jac.damon_commit_ctxasbuh1hhjLaubjZ)}(h h]h }(hjahhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjLaubjL)}(hjLh]h*}(hjahhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjLaubjq)}(hsrch]hsrc}(hjahhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjLaubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj`ubeh}(h]h ]h"]h$]h&]hhuh1j.Khj`hhhj`hM"ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhj`hhhj`hM"ubah}(h]j`ah ](jjeh"]h$]h&]jj)jhuh1j;hj`hM"hj`hhubj)}(hhh]h)}(h0Commit parameters of a DAMON context to another.h]h0Commit parameters of a DAMON context to another.}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM"hjahhubah}(h]h ]h"]h$]h&]uh1jhj`hhhj`hM"ubeh}(h]h ](jfunctioneh"]h$]h&]jjjjajjajjjuh1j6hhhjJhNhNubj)}(hX**Parameters** ``struct damon_ctx *dst`` The commit destination DAMON context. ``struct damon_ctx *src`` The commit source DAMON context. **Description** This function copies user-specified parameters from **src** to **dst** and update the internal status and results accordingly. Users should use this function for context-level parameters update of running context, instead of manual in-place updates. This function should be called from parameters-update safe context, like damon_call().h](h)}(h**Parameters**h]j)}(hjah]h Parameters}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1jhjaubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM&hjaubj7)}(hhh](j<)}(h@``struct damon_ctx *dst`` The commit destination DAMON context. h](jB)}(h``struct damon_ctx *dst``h]h)}(hjbh]hstruct damon_ctx *dst}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjbubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM#hj bubj\)}(hhh]h)}(h%The commit destination DAMON context.h]h%The commit destination DAMON context.}(hj+bhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj'bhM#hj(bubah}(h]h ]h"]h$]h&]uh1j[hj bubeh}(h]h ]h"]h$]h&]uh1j;hj'bhM#hj bubj<)}(h;``struct damon_ctx *src`` The commit source DAMON context. h](jB)}(h``struct damon_ctx *src``h]h)}(hjKbh]hstruct damon_ctx *src}(hjMbhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjIbubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM$hjEbubj\)}(hhh]h)}(h The commit source DAMON context.h]h The commit source DAMON context.}(hjdbhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj`bhM$hjabubah}(h]h ]h"]h$]h&]uh1j[hjEbubeh}(h]h ]h"]h$]h&]uh1j;hj`bhM$hj bubeh}(h]h ]h"]h$]h&]uh1j6hjaubh)}(h**Description**h]j)}(hjbh]h Description}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjbubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM&hjaubh)}(hThis function copies user-specified parameters from **src** to **dst** and update the internal status and results accordingly. Users should use this function for context-level parameters update of running context, instead of manual in-place updates.h](h4This function copies user-specified parameters from }(hjbhhhNhNubj)}(h**src**h]hsrc}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjbubh to }(hjbhhhNhNubj)}(h**dst**h]hdst}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjbubh and update the internal status and results accordingly. Users should use this function for context-level parameters update of running context, instead of manual in-place updates.}(hjbhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM%hjaubh)}(hVThis function should be called from parameters-update safe context, like damon_call().h]hVThis function should be called from parameters-update safe context, like damon_call().}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM*hjaubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1"damon_nr_running_ctxs (C function)c.damon_nr_running_ctxshNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h int damon_nr_running_ctxs (void)h]jB)}(hint damon_nr_running_ctxs(void)h](jJ)}(hinth]hint}(hjbhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjbhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM@ubjZ)}(h h]h }(hj chhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjbhhhj chM@ubjk)}(hdamon_nr_running_ctxsh]jq)}(hdamon_nr_running_ctxsh]hdamon_nr_running_ctxs}(hjchhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjcubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjbhhhj chM@ubj/K)}(h(void)h]j5K)}(hvoidh]jJ)}(hvoidh]hvoid}(hj;chhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj7cubah}(h]h ]h"]h$]h&]noemphhhuh1j4Khj3cubah}(h]h ]h"]h$]h&]hhuh1j.Khjbhhhj chM@ubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjbhhhj chM@ubah}(h]jbah ](jjeh"]h$]h&]jj)jhuh1j;hj chM@hjbhhubj)}(hhh]h)}(h,Return number of currently running contexts.h]h,Return number of currently running contexts.}(hjechhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM@hjbchhubah}(h]h ]h"]h$]h&]uh1jhjbhhhj chM@ubeh}(h]h ](jfunctioneh"]h$]h&]jjjj}cjj}cjjjuh1j6hhhjJhNhNubj)}(h'**Parameters** ``void`` no argumentsh](h)}(h**Parameters**h]j)}(hjch]h Parameters}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1jhjcubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMDhjcubj7)}(hhh]j<)}(h``void`` no argumentsh](jB)}(h``void``h]h)}(hjch]hvoid}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhjcubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMFhjcubj\)}(hhh]h)}(h no argumentsh]h no arguments}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chKhjcubah}(h]h ]h"]h$]h&]uh1j[hjcubeh}(h]h ]h"]h$]h&]uh1j;hjchMFhjcubah}(h]h ]h"]h$]h&]uh1j6hjcubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_start (C function) c.damon_starthNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hFint damon_start (struct damon_ctx **ctxs, int nr_ctxs, bool exclusive)h]jB)}(hEint damon_start(struct damon_ctx **ctxs, int nr_ctxs, bool exclusive)h](jJ)}(hinth]hint}(hjdhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjchhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hjdhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjchhhjdhMubjk)}(h damon_starth]jq)}(h damon_starth]h damon_start}(hj!dhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjdubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjchhhjdhMubj/K)}(h6(struct damon_ctx **ctxs, int nr_ctxs, bool exclusive)h](j5K)}(hstruct damon_ctx **ctxsh](jH)}(hjKh]hstruct}(hj=dhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj9dubjZ)}(h h]h }(hjJdhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj9dubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hj[dhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjXdubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetj]dmodnameN classnameNjj)}j]j4#)}j7#j#dsb c.damon_startasbuh1hhj9dubjZ)}(h h]h }(hj{dhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj9dubjL)}(hjLh]h*}(hjdhhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj9dubjL)}(hjLh]h*}(hjdhhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj9dubjq)}(hctxsh]hctxs}(hjdhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj9dubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj5dubj5K)}(h int nr_ctxsh](jJ)}(hinth]hint}(hjdhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjdubjZ)}(h h]h }(hjdhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjdubjq)}(hnr_ctxsh]hnr_ctxs}(hjdhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjdubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj5dubj5K)}(hbool exclusiveh](jJ)}(hjJh]hbool}(hjdhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjdubjZ)}(h h]h }(hjdhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjdubjq)}(h exclusiveh]h exclusive}(hj ehhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjdubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj5dubeh}(h]h ]h"]h$]h&]hhuh1j.KhjchhhjdhMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjchhhjdhMubah}(h]jcah ](jjeh"]h$]h&]jj)jhuh1j;hjdhMhjchhubj)}(hhh]h)}(h5Starts the monitorings for a given group of contexts.h]h5Starts the monitorings for a given group of contexts.}(hj6ehhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj3ehhubah}(h]h ]h"]h$]h&]uh1jhjchhhjdhMubeh}(h]h ](jfunctioneh"]h$]h&]jjjjNejjNejjjuh1j6hhhjJhNhNubj)}(hX**Parameters** ``struct damon_ctx **ctxs`` an array of the pointers for contexts to start monitoring ``int nr_ctxs`` size of **ctxs** ``bool exclusive`` exclusiveness of this contexts group **Description** This function starts a group of monitoring threads for a group of monitoring contexts. One thread per each context is created and run in parallel. The caller should handle synchronization between the threads by itself. If **exclusive** is true and a group of threads that created by other 'damon_start()' call is currently running, this function does nothing but returns -EBUSY. **Return** 0 on success, negative error code otherwise.h](h)}(h**Parameters**h]j)}(hjXeh]h Parameters}(hjZehhhNhNubah}(h]h ]h"]h$]h&]uh1jhjVeubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjReubj7)}(hhh](j<)}(hV``struct damon_ctx **ctxs`` an array of the pointers for contexts to start monitoring h](jB)}(h``struct damon_ctx **ctxs``h]h)}(hjweh]hstruct damon_ctx **ctxs}(hjyehhhNhNubah}(h]h ]h"]h$]h&]uh1hhjueubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjqeubj\)}(hhh]h)}(h9an array of the pointers for contexts to start monitoringh]h9an array of the pointers for contexts to start monitoring}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1hhjehMhjeubah}(h]h ]h"]h$]h&]uh1j[hjqeubeh}(h]h ]h"]h$]h&]uh1j;hjehMhjneubj<)}(h!``int nr_ctxs`` size of **ctxs** h](jB)}(h``int nr_ctxs``h]h)}(hjeh]h int nr_ctxs}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1hhjeubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjeubj\)}(hhh]h)}(hsize of **ctxs**h](hsize of }(hjehhhNhNubj)}(h**ctxs**h]hctxs}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1jhjeubeh}(h]h ]h"]h$]h&]uh1hhjehMhjeubah}(h]h ]h"]h$]h&]uh1j[hjeubeh}(h]h ]h"]h$]h&]uh1j;hjehMhjneubj<)}(h8``bool exclusive`` exclusiveness of this contexts group h](jB)}(h``bool exclusive``h]h)}(hjeh]hbool exclusive}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1hhjeubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjeubj\)}(hhh]h)}(h$exclusiveness of this contexts grouph]h$exclusiveness of this contexts group}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj fhMhj fubah}(h]h ]h"]h$]h&]uh1j[hjeubeh}(h]h ]h"]h$]h&]uh1j;hj fhMhjneubeh}(h]h ]h"]h$]h&]uh1j6hjReubh)}(h**Description**h]j)}(hj2fh]h Description}(hj4fhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0fubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjReubh)}(hX}This function starts a group of monitoring threads for a group of monitoring contexts. One thread per each context is created and run in parallel. The caller should handle synchronization between the threads by itself. If **exclusive** is true and a group of threads that created by other 'damon_start()' call is currently running, this function does nothing but returns -EBUSY.h](hThis function starts a group of monitoring threads for a group of monitoring contexts. One thread per each context is created and run in parallel. The caller should handle synchronization between the threads by itself. If }(hjHfhhhNhNubj)}(h **exclusive**h]h exclusive}(hjPfhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjHfubh is true and a group of threads that created by other ‘damon_start()’ call is currently running, this function does nothing but returns -EBUSY.}(hjHfhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjReubh)}(h **Return**h]j)}(hjkfh]hReturn}(hjmfhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjifubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjReubh)}(h,0 on success, negative error code otherwise.h]h,0 on success, negative error code otherwise.}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjReubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_stop (C function) c.damon_stophNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h6void damon_stop (struct damon_ctx **ctxs, int nr_ctxs)h]jB)}(h5void damon_stop(struct damon_ctx **ctxs, int nr_ctxs)h](jJ)}(hvoidh]hvoid}(hjfhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjfhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hjfhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjfhhhjfhMubjk)}(h damon_stoph]jq)}(h damon_stoph]h damon_stop}(hjfhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjfubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjfhhhjfhMubj/K)}(h&(struct damon_ctx **ctxs, int nr_ctxs)h](j5K)}(hstruct damon_ctx **ctxsh](jH)}(hjKh]hstruct}(hjfhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjfubjZ)}(h h]h }(hjfhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjfubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hj ghhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjgubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetj gmodnameN classnameNjj)}j]j4#)}j7#jfsb c.damon_stopasbuh1hhjfubjZ)}(h h]h }(hj+ghhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjfubjL)}(hjLh]h*}(hj9ghhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjfubjL)}(hjLh]h*}(hjFghhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjfubjq)}(hctxsh]hctxs}(hjSghhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjfubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khjfubj5K)}(h int nr_ctxsh](jJ)}(hinth]hint}(hjlghhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjhgubjZ)}(h h]h }(hjzghhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhgubjq)}(hnr_ctxsh]hnr_ctxs}(hjghhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjhgubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khjfubeh}(h]h ]h"]h$]h&]hhuh1j.KhjfhhhjfhMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjfhhhjfhMubah}(h]jfah ](jjeh"]h$]h&]jj)jhuh1j;hjfhMhjfhhubj)}(hhh]h)}(h4Stops the monitorings for a given group of contexts.h]h4Stops the monitorings for a given group of contexts.}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjghhubah}(h]h ]h"]h$]h&]uh1jhjfhhhjfhMubeh}(h]h ](jfunctioneh"]h$]h&]jjjjgjjgjjjuh1j6hhhjJhNhNubj)}(h**Parameters** ``struct damon_ctx **ctxs`` an array of the pointers for contexts to stop monitoring ``int nr_ctxs`` size of **ctxs**h](h)}(h**Parameters**h]j)}(hjgh]h Parameters}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1jhjgubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjgubj7)}(hhh](j<)}(hU``struct damon_ctx **ctxs`` an array of the pointers for contexts to stop monitoring h](jB)}(h``struct damon_ctx **ctxs``h]h)}(hjgh]hstruct damon_ctx **ctxs}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1hhjgubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjgubj\)}(hhh]h)}(h8an array of the pointers for contexts to stop monitoringh]h8an array of the pointers for contexts to stop monitoring}(hj hhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhMhj hubah}(h]h ]h"]h$]h&]uh1j[hjgubeh}(h]h ]h"]h$]h&]uh1j;hjhhMhjgubj<)}(h ``int nr_ctxs`` size of **ctxs**h](jB)}(h``int nr_ctxs``h]h)}(hj,hh]h int nr_ctxs}(hj.hhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj*hubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj&hubj\)}(hhh]h)}(hsize of **ctxs**h](hsize of }(hjEhhhhNhNubj)}(h**ctxs**h]hctxs}(hjMhhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjEhubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjBhubah}(h]h ]h"]h$]h&]uh1j[hj&hubeh}(h]h ]h"]h$]h&]uh1j;hjAhhMhjgubeh}(h]h ]h"]h$]h&]uh1j6hjgubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_is_running (C function)c.damon_is_runninghNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h-bool damon_is_running (struct damon_ctx *ctx)h]jB)}(h,bool damon_is_running(struct damon_ctx *ctx)h](jJ)}(hjJh]hbool}(hjhhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjhhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hjhhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhhhhjhhMubjk)}(hdamon_is_runningh]jq)}(hdamon_is_runningh]hdamon_is_running}(hjhhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjhubah}(h]h ](jjeh"]h$]h&]hhuh1jjhjhhhhjhhMubj/K)}(h(struct damon_ctx *ctx)h]j5K)}(hstruct damon_ctx *ctxh](jH)}(hjKh]hstruct}(hjhhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhjhubjZ)}(h h]h }(hjhhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hjhhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjhubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjhmodnameN classnameNjj)}j]j4#)}j7#jhsbc.damon_is_runningasbuh1hhjhubjZ)}(h h]h }(hjihhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjhubjL)}(hjLh]h*}(hjihhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhjhubjq)}(hctxh]hctx}(hj)ihhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjhubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khjhubah}(h]h ]h"]h$]h&]hhuh1j.KhjhhhhjhhMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjhhhhjhhMubah}(h]jhah ](jjeh"]h$]h&]jj)jhuh1j;hjhhMhjhhhubj)}(hhh]h)}(h,Returns if a given DAMON context is running.h]h,Returns if a given DAMON context is running.}(hjSihhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjPihhubah}(h]h ]h"]h$]h&]uh1jhjhhhhjhhMubeh}(h]h ](jfunctioneh"]h$]h&]jjjjkijjkijjjuh1j6hhhjJhNhNubj)}(h**Parameters** ``struct damon_ctx *ctx`` The DAMON context to see if running. **Return** true if **ctx** is running, false otherwise.h](h)}(h**Parameters**h]j)}(hjuih]h Parameters}(hjwihhhNhNubah}(h]h ]h"]h$]h&]uh1jhjsiubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjoiubj7)}(hhh]j<)}(h?``struct damon_ctx *ctx`` The DAMON context to see if running. h](jB)}(h``struct damon_ctx *ctx``h]h)}(hjih]hstruct damon_ctx *ctx}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1hhjiubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjiubj\)}(hhh]h)}(h$The DAMON context to see if running.h]h$The DAMON context to see if running.}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1hhjihMhjiubah}(h]h ]h"]h$]h&]uh1j[hjiubeh}(h]h ]h"]h$]h&]uh1j;hjihMhjiubah}(h]h ]h"]h$]h&]uh1j6hjoiubh)}(h **Return**h]j)}(hjih]hReturn}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjoiubh)}(h,true if **ctx** is running, false otherwise.h](htrue if }(hjihhhNhNubj)}(h**ctx**h]hctx}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiubh is running, false otherwise.}(hjihhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjoiubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_kdamond_pid (C function)c.damon_kdamond_pidhNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(h-int damon_kdamond_pid (struct damon_ctx *ctx)h]jB)}(h,int damon_kdamond_pid(struct damon_ctx *ctx)h](jJ)}(hinth]hint}(hj&jhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhj"jhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hj5jhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj"jhhhj4jhMubjk)}(hdamon_kdamond_pidh]jq)}(hdamon_kdamond_pidh]hdamon_kdamond_pid}(hjGjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphjCjubah}(h]h ](jjeh"]h$]h&]hhuh1jjhj"jhhhj4jhMubj/K)}(h(struct damon_ctx *ctx)h]j5K)}(hstruct damon_ctx *ctxh](jH)}(hjKh]hstruct}(hjcjhhhNhNubah}(h]h ]jTah"]h$]h&]uh1jGhj_jubjZ)}(h h]h }(hjpjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj_jubh)}(hhh]jq)}(h damon_ctxh]h damon_ctx}(hjjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj~jubah}(h]h ]h"]h$]h&] refdomainjreftypej7# reftargetjjmodnameN classnameNjj)}j]j4#)}j7#jIjsbc.damon_kdamond_pidasbuh1hhj_jubjZ)}(h h]h }(hjjhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhj_jubjL)}(hjLh]h*}(hjjhhhNhNubah}(h]h ]jMah"]h$]h&]uh1jLhj_jubjq)}(hctxh]hctx}(hjjhhhNhNubah}(h]h ]j|ah"]h$]h&]uh1jphj_jubeh}(h]h ]h"]h$]h&]noemphhhuh1j4Khj[jubah}(h]h ]h"]h$]h&]hhuh1j.Khj"jhhhj4jhMubeh}(h]h ]h"]h$]h&]hhjuh1jAjjhjjhhhj4jhMubah}(h]jjah ](jjeh"]h$]h&]jj)jhuh1j;hj4jhMhjjhhubj)}(hhh]h)}(h4Return pid of a given DAMON context's worker thread.h]h6Return pid of a given DAMON context’s worker thread.}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjjhhubah}(h]h ]h"]h$]h&]uh1jhjjhhhj4jhMubeh}(h]h ](jfunctioneh"]h$]h&]jjjjjjjjjjjuh1j6hhhjJhNhNubj)}(h**Parameters** ``struct damon_ctx *ctx`` The DAMON context of the question. **Return** pid if **ctx** is running, negative error code otherwise.h](h)}(h**Parameters**h]j)}(hjkh]h Parameters}(hj khhhNhNubah}(h]h ]h"]h$]h&]uh1jhjkubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjkubj7)}(hhh]j<)}(h=``struct damon_ctx *ctx`` The DAMON context of the question. h](jB)}(h``struct damon_ctx *ctx``h]h)}(hj'kh]hstruct damon_ctx *ctx}(hj)khhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%kubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj!kubj\)}(hhh]h)}(h"The DAMON context of the question.h]h"The DAMON context of the question.}(hj@khhhNhNubah}(h]h ]h"]h$]h&]uh1hhjfn ` and :c:type:`damon_call_control->data ` of **control**. If :c:type:`damon_call_control->repeat ` of **control** is unset, further wait until the kdamond finishes handling of the request. Otherwise, return as soon as the request is made. The kdamond executes the function with the argument in the main loop, just after a sampling of the iteration is finished. The function can hence safely access the internal data of the :c:type:`struct damon_ctx ` without additional synchronization. The return value of the function will be saved in :c:type:`damon_call_control->return_code `. Note that this function should be called only after damon_start() with the **ctx** has succeeded. Otherwise, this function could fall into an indefinite wait. When this function is failed, the **ctx** is guaranteed to be stopped. **Return** 0 on success, negative error code otherwise.h](h)}(h**Parameters**h]j)}(hj mh]h Parameters}(hj mhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj mubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM&hjmubj7)}(hhh](j<)}(hB``struct damon_ctx *ctx`` DAMON context to call the function for. h](jB)}(h``struct damon_ctx *ctx``h]h)}(hj*mh]hstruct damon_ctx *ctx}(hj,mhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj(mubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM#hj$mubj\)}(hhh]h)}(h'DAMON context to call the function for.h]h'DAMON context to call the function for.}(hjCmhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj?mhM#hj@mubah}(h]h ]h"]h$]h&]uh1j[hj$mubeh}(h]h ]h"]h$]h&]uh1j;hj?mhM#hj!mubj<)}(hM``struct damon_call_control *control`` Control variable of the call request. h](jB)}(h&``struct damon_call_control *control``h]h)}(hjcmh]h"struct damon_call_control *control}(hjemhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjamubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM$hj]mubj\)}(hhh]h)}(h%Control variable of the call request.h]h%Control variable of the call request.}(hj|mhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjxmhM$hjymubah}(h]h ]h"]h$]h&]uh1j[hj]mubeh}(h]h ]h"]h$]h&]uh1j;hjxmhM$hj!mubeh}(h]h ]h"]h$]h&]uh1j6hjmubh)}(h**Description**h]j)}(hjmh]h Description}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjmubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM&hjmubh)}(hXAsk DAMON worker thread (kdamond) of **ctx** to call a function with an argument data that respectively passed via :c:type:`damon_call_control->fn ` and :c:type:`damon_call_control->data ` of **control**. If :c:type:`damon_call_control->repeat ` of **control** is unset, further wait until the kdamond finishes handling of the request. Otherwise, return as soon as the request is made.h](h%Ask DAMON worker thread (kdamond) of }(hjmhhhNhNubj)}(h**ctx**h]hctx}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjmubhG to call a function with an argument data that respectively passed via }(hjmhhhNhNubh)}(h5:c:type:`damon_call_control->fn `h]h)}(hjmh]hdamon_call_control->fn}(hjmhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjmubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_call_controluh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM%hjmubh and }(hjmhhhNhNubh)}(h7:c:type:`damon_call_control->data `h]h)}(hjmh]hdamon_call_control->data}(hjmhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjmubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_call_controluh1hhjmhM%hjmubh of }(hjmhhhNhNubj)}(h **control**h]hcontrol}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjmubh. If }(hjmhhhNhNubh)}(h9:c:type:`damon_call_control->repeat `h]h)}(hj)nh]hdamon_call_control->repeat}(hj+nhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhj'nubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_call_controluh1hhjmhM%hjmubh of }(hjmhhhNhNubj)}(h **control**h]hcontrol}(hjJnhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjmubh~ is unset, further wait until the kdamond finishes handling of the request. Otherwise, return as soon as the request is made.}(hjmhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjmhM%hjmubh)}(hXvThe kdamond executes the function with the argument in the main loop, just after a sampling of the iteration is finished. The function can hence safely access the internal data of the :c:type:`struct damon_ctx ` without additional synchronization. The return value of the function will be saved in :c:type:`damon_call_control->return_code `.h](hThe kdamond executes the function with the argument in the main loop, just after a sampling of the iteration is finished. The function can hence safely access the internal data of the }(hjbnhhhNhNubh)}(h&:c:type:`struct damon_ctx `h]h)}(hjlnh]hstruct damon_ctx}(hjnnhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjjnubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_ctxuh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM+hjbnubhX without additional synchronization. The return value of the function will be saved in }(hjbnhhhNhNubh)}(h>:c:type:`damon_call_control->return_code `h]h)}(hjnh]hdamon_call_control->return_code}(hjnhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjnubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_call_controluh1hhjnhM+hjbnubh.}(hjbnhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjnhM+hjmubh)}(hNote that this function should be called only after damon_start() with the **ctx** has succeeded. Otherwise, this function could fall into an indefinite wait.h](hKNote that this function should be called only after damon_start() with the }(hjnhhhNhNubj)}(h**ctx**h]hctx}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjnubhM has succeeded. Otherwise, this function could fall into an indefinite wait.}(hjnhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM1hjmubh)}(hFWhen this function is failed, the **ctx** is guaranteed to be stopped.h](h"When this function is failed, the }(hjnhhhNhNubj)}(h**ctx**h]hctx}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjnubh is guaranteed to be stopped.}(hjnhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM5hjmubh)}(h **Return**h]j)}(hjnh]hReturn}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjnubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM7hjmubh)}(h,0 on success, negative error code otherwise.h]h,0 on success, negative error code otherwise.}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM8hjmubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damos_walk (C function) c.damos_walkhNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hJint damos_walk (struct damon_ctx *ctx, struct damos_walk_control *control)h]jB)}(hIint damos_walk(struct damon_ctx *ctx, struct damos_walk_control *control)h](jJ)}(hinth]hint}(hj@ohhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjapply_interval_us ` since damos_walk() invocation, for each scheme. The given callback function can hence safely access the internal data of :c:type:`struct damon_ctx ` and :c:type:`struct damon_region ` that each of the scheme will apply the action for next interval, without additional synchronizations against the kdamond. If every scheme of **ctx** passed at least one :c:type:`damos->apply_interval_us `, kdamond marks the request as completed so that damos_walk() can wakeup and return. Note that this function should be called only after damon_start() with the **ctx** has succeeded. Otherwise, this function could fall into an indefinite wait. **Return** 0 on success, negative error code otherwise.h](h)}(h**Parameters**h]j)}(hjph]h Parameters}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1jhjpubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM[hjpubj7)}(hhh](j<)}(hC``struct damon_ctx *ctx`` DAMON context to call the functions for. h](jB)}(h``struct damon_ctx *ctx``h]h)}(hjph]hstruct damon_ctx *ctx}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1hhjpubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMXhjpubj\)}(hhh]h)}(h(DAMON context to call the functions for.h]h(DAMON context to call the functions for.}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1hhjphMXhjpubah}(h]h ]h"]h$]h&]uh1j[hjpubeh}(h]h ]h"]h$]h&]uh1j;hjphMXhjpubj<)}(hM``struct damos_walk_control *control`` Control variable of the walk request. h](jB)}(h&``struct damos_walk_control *control``h]h)}(hjph]h"struct damos_walk_control *control}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1hhjpubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMYhjpubj\)}(hhh]h)}(h%Control variable of the walk request.h]h%Control variable of the walk request.}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjphMYhjqubah}(h]h ]h"]h$]h&]uh1j[hjpubeh}(h]h ]h"]h$]h&]uh1j;hjphMYhjpubeh}(h]h ]h"]h$]h&]uh1j6hjpubh)}(h**Description**h]j)}(hj%qh]h Description}(hj'qhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj#qubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM[hjpubh)}(hAsk DAMON worker thread (kdamond) of **ctx** to call a function for each region that the kdamond will apply DAMOS action to, and wait until the kdamond finishes handling of the request.h](h%Ask DAMON worker thread (kdamond) of }(hj;qhhhNhNubj)}(h**ctx**h]hctx}(hjCqhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj;qubh to call a function for each region that the kdamond will apply DAMOS action to, and wait until the kdamond finishes handling of the request.}(hj;qhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMZhjpubh)}(hXThe kdamond executes the given function in the main loop, for each region just after it applied any DAMOS actions of **ctx** to it. The invocation is made only within one :c:type:`damos->apply_interval_us ` since damos_walk() invocation, for each scheme. The given callback function can hence safely access the internal data of :c:type:`struct damon_ctx ` and :c:type:`struct damon_region ` that each of the scheme will apply the action for next interval, without additional synchronizations against the kdamond. If every scheme of **ctx** passed at least one :c:type:`damos->apply_interval_us `, kdamond marks the request as completed so that damos_walk() can wakeup and return.h](huThe kdamond executes the given function in the main loop, for each region just after it applied any DAMOS actions of }(hj\qhhhNhNubj)}(h**ctx**h]hctx}(hjdqhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj\qubh0 to it. The invocation is made only within one }(hj\qhhhNhNubh)}(h*:c:type:`damos->apply_interval_us `h]h)}(hjxqh]hdamos->apply_interval_us}(hjzqhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjvqubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamosuh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chM^hj\qubh{ since damos_walk() invocation, for each scheme. The given callback function can hence safely access the internal data of }(hj\qhhhNhNubh)}(h&:c:type:`struct damon_ctx `h]h)}(hjqh]hstruct damon_ctx}(hjqhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjqubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_ctxuh1hhjqhM^hj\qubh and }(hj\qhhhNhNubh)}(h,:c:type:`struct damon_region `h]h)}(hjqh]hstruct damon_region}(hjqhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjqubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjj damon_regionuh1hhjqhM^hj\qubh that each of the scheme will apply the action for next interval, without additional synchronizations against the kdamond. If every scheme of }(hj\qhhhNhNubj)}(h**ctx**h]hctx}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj\qubh passed at least one }(hj\qhhhNhNubh)}(h*:c:type:`damos->apply_interval_us `h]h)}(hjqh]hdamos->apply_interval_us}(hjqhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjqubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamosuh1hhjqhM^hj\qubhT, kdamond marks the request as completed so that damos_walk() can wakeup and return.}(hj\qhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjqhM^hjpubh)}(hNote that this function should be called only after damon_start() with the **ctx** has succeeded. Otherwise, this function could fall into an indefinite wait.h](hKNote that this function should be called only after damon_start() with the }(hjrhhhNhNubj)}(h**ctx**h]hctx}(hj#rhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjrubhM has succeeded. Otherwise, this function could fall into an indefinite wait.}(hjrhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhhjpubh)}(h **Return**h]j)}(hj>rh]hReturn}(hj@rhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjcheck_accesses ` callback.h](h)}(h**Parameters**h]j)}(hjxh]h Parameters}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjxubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj xubj7)}(hhh](j<)}(hS``struct damon_region *r`` The DAMON region to update for its access check result. h](jB)}(h``struct damon_region *r``h]h)}(hj1xh]hstruct damon_region *r}(hj3xhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj/xubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj+xubj\)}(hhh]h)}(h7The DAMON region to update for its access check result.h]h7The DAMON region to update for its access check result.}(hjJxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjFxhMhjGxubah}(h]h ]h"]h$]h&]uh1j[hj+xubeh}(h]h ]h"]h$]h&]uh1j;hjFxhMhj(xubj<)}(hQ``bool accessed`` Whether the region has accessed during last sampling interval. h](jB)}(h``bool accessed``h]h)}(hjjxh]h bool accessed}(hjlxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhxubah}(h]h ]h"]h$]h&]uh1jAhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjdxubj\)}(hhh]h)}(h>Whether the region has accessed during last sampling interval.h]h>Whether the region has accessed during last sampling interval.}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjxhMhjxubah}(h]h ]h"]h$]h&]uh1j[hjdxubeh}(h]h ]h"]h$]h&]uh1j;hjxhMhj(xubeh}(h]h ]h"]h$]h&]uh1j6hj xubh)}(h**Description**h]j)}(hjxh]h Description}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjxubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj xubh)}(h`Update the access rate of a region with the region's last sampling interval access check result.h]hbUpdate the access rate of a region with the region’s last sampling interval access check result.}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhj xubh)}(hfUsually this will be called by :c:type:`damon_operations->check_accesses ` callback.h](hUsually this will be called by }(hjxhhhNhNubh)}(h=:c:type:`damon_operations->check_accesses `h]h)}(hjxh]h damon_operations->check_accesses}(hjxhhhNhNubah}(h]h ](jqjc-typeeh"]h$]h&]uh1hhjxubah}(h]h ]h"]h$]h&]refdocj} refdomainjreftypetype refexplicitrefwarnjjjdamon_operationsuh1hhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMhjxubh callback.}(hjxhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjxhMhj xubeh}(h]h ] kernelindentah"]h$]h&]uh1jhjJhhhNhNubj%)}(hhh]h}(h]h ]h"]h$]h&]entries](j1damon_initialized (C function)c.damon_initializedhNtauh1j$hjJhhhNhNubj7)}(hhh](j<)}(hbool damon_initialized (void)h]jB)}(hbool damon_initialized(void)h](jJ)}(hjJh]hbool}(hjyhhhNhNubah}(h]h ]jKah"]h$]h&]uh1jJhjyhhhL/var/lib/git/docbuild/linux/Documentation/mm/damon/api:20: ./mm/damon/core.chMubjZ)}(h h]h }(hj*yhhhNhNubah}(h]h ]jfah"]h$]h&]uh1jYhjyhhhj)yhMubjk)}(hdamon_initializedh]jq)}(hdamon_initializedh]hdamon_initialized}(hjj@j@jBj BjTDjYDj]EjbEjHjHj,zjJjJjJjdLjiLj3Nj8NjPjPjOSjTSj#Vj(VjWjWjZjZj\j\j:_j?_j`j`jbjbjcjcjfjfjhjhjjjjjkjkj3oj8ojvrj{rjvjvjyjyu footnote_refs} citation_refs} autofootnotes]autofootnote_refs]symbol_footnotes]symbol_footnote_refs] footnotes] citations]autofootnote_startKsymbol_footnote_startK id_counter collectionsCounter}Rparse_messages]transform_messages] transformerN include_log] decorationNhhub.