Commit e93b81a3 authored by SeongJae Park's avatar SeongJae Park Committed by Andrew Morton

Docs/admin-guide/mm/damon/usage: use a list for 'state' sysfs file input commands

There are eight command inputs for 'state' DAMON sysfs file, and those are
verbosely explained in multiple paragraphs.  It is not easy to find
explanation of specific command, and getting whole picture of supported
commands.  Replace the paragraphs with a list.

Link: https://lkml.kernel.org/r/20231213190338.54146-7-sj@kernel.orgSigned-off-by: default avatarSeongJae Park <sj@kernel.org>
Cc: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 9c8c315d
...@@ -130,30 +130,29 @@ In each kdamond directory, two files (``state`` and ``pid``) and one directory ...@@ -130,30 +130,29 @@ In each kdamond directory, two files (``state`` and ``pid``) and one directory
(``contexts``) exist. (``contexts``) exist.
Reading ``state`` returns ``on`` if the kdamond is currently running, or Reading ``state`` returns ``on`` if the kdamond is currently running, or
``off`` if it is not running. Writing ``on`` or ``off`` makes the kdamond be ``off`` if it is not running.
in the state.
Users can write below commands for the kdamond to the ``state`` file.
Writing ``commit`` to the ``state`` file makes kdamond reads the
user inputs in the sysfs files except ``state`` file again. Writing - ``on``: Start running.
``commit_schemes_quota_goals`` to the ``state`` file makes kdamond reads the - ``off``: Stop running.
DAMON-based operation schemes' :ref:`quota goals <sysfs_schemes_quota_goals>` - ``commit``: Read the user inputs in the sysfs files except ``state`` file
of the kdamond. again.
- ``commit_schemes_quota_goals``: Read the DAMON-based operation schemes'
Writing ``update_schemes_stats`` to ``state`` file updates the :ref:`quota goals <sysfs_schemes_quota_goals>`.
contents of stats files for each DAMON-based operation scheme of the kdamond. - ``update_schemes_stats``: Update the contents of stats files for each
For details of the stats, please refer to :ref:`stats section DAMON-based operation scheme of the kdamond. For details of the stats,
<sysfs_schemes_stats>`. please refer to :ref:`stats section <sysfs_schemes_stats>`.
- ``update_schemes_tried_regions``: Update the DAMON-based operation scheme
Writing ``update_schemes_tried_regions`` to ``state`` file updates the action tried regions directory for each DAMON-based operation scheme of the
DAMON-based operation scheme action tried regions directory for each kdamond. For details of the DAMON-based operation scheme action tried
DAMON-based operation scheme of the kdamond. Writing regions directory, please refer to
``update_schemes_tried_bytes`` to ``state`` file updates only :ref:`tried_regions section <sysfs_schemes_tried_regions>`.
``.../tried_regions/total_bytes`` files. Writing - ``update_schemes_tried_bytes``: Update only ``.../tried_regions/total_bytes``
``clear_schemes_tried_regions`` to ``state`` file clears the DAMON-based files.
operating scheme action tried regions directory for each DAMON-based operation - ``clear_schemes_tried_regions``: Clear the DAMON-based operating scheme
scheme of the kdamond. For details of the DAMON-based operation scheme action action tried regions directory for each DAMON-based operation scheme of the
tried regions directory, please refer to :ref:`tried_regions section kdamond.
<sysfs_schemes_tried_regions>`.
If the state is ``on``, reading ``pid`` shows the pid of the kdamond thread. If the state is ``on``, reading ``pid`` shows the pid of the kdamond thread.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment