All of lore.kernel.org
 help / color / mirror / Atom feed
From: Damien Le Moal <damien.lemoal@opensource.wdc.com>
To: linux-fsdevel@vger.kernel.org
Cc: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Subject: [PATCH 8/8] documentation: zonefs: Document sysfs attributes
Date: Mon, 18 Apr 2022 10:12:07 +0900	[thread overview]
Message-ID: <20220418011207.2385416-9-damien.lemoal@opensource.wdc.com> (raw)
In-Reply-To: <20220418011207.2385416-1-damien.lemoal@opensource.wdc.com>

Document the max_wro_seq_files, nr_wro_seq_files, max_active_seq_files
and nr_active_seq_files sysfs attributes.

Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
---
 Documentation/filesystems/zonefs.rst | 38 ++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/Documentation/filesystems/zonefs.rst b/Documentation/filesystems/zonefs.rst
index 72d4baba0b6a..394b9f15dce0 100644
--- a/Documentation/filesystems/zonefs.rst
+++ b/Documentation/filesystems/zonefs.rst
@@ -351,6 +351,44 @@ guaranteed that write requests can be processed. Conversely, the
 to the device on the last close() of a zone file if the zone is not full nor
 empty.
 
+Runtime sysfs attributes
+------------------------
+
+zonefs defines several sysfs attributes for mounted devices.  All attributes
+are user readable and can be found in the directory /sys/fs/zonefs/<dev>/,
+where <dev> is the name of the mounted zoned block device.
+
+The attributes defined are as follows.
+
+* **max_wro_seq_files**:  This attribute reports the maximum number of
+  sequential zone files that can be open for writing.  This number corresponds
+  to the maximum number of explicitly or implicitly open zones that the device
+  supports.  A value of 0 means that the device has no limit and that any zone
+  (any file) can be open for writing and written at any time, regardless of the
+  state of other zones.  When the *explicit-open* mount option is used, zonefs
+  will fail any open() system call requesting to open a sequential zone file for
+  writing when the number of sequential zone files already open for writing has
+  reached the *max_wro_seq_files* limit.
+* **nr_wro_seq_files**:  This attribute reports the current number of sequential
+  zone files open for writing.  When the "explicit-open" mount option is used,
+  this number can never exceed *max_wro_seq_files*.  If the *explicit-open*
+  mount option is not used, the reported number can be greater than
+  *max_wro_seq_files*.  In such case, it is the responsibility of the
+  application to not write simultaneously more than *max_wro_seq_files*
+  sequential zone files.  Failure to do so can result in write errors.
+* **max_active_seq_files**:  This attribute reports the maximum number of
+  sequential zone files that are in an active state, that is, sequential zone
+  files that are partially writen (not empty nor full) or that have a zone that
+  is explicitly open (which happens only if the *explicit-open* mount option is
+  used).  This number is always equal to the maximum number of active zones that
+  the device supports.  A value of 0 means that the mounted device has no limit
+  on the number of sequential zone files that can be active.
+* **nr_active_seq_files**:  This attributes reports the current number of
+  sequential zone files that are active. If *max_active_seq_files* is not 0,
+  then the value of *nr_active_seq_files* can never exceed the value of
+  *nr_active_seq_files*, regardless of the use of the *explicit-open* mount
+  option.
+
 Zonefs User Space Tools
 =======================
 
-- 
2.35.1


  parent reply	other threads:[~2022-04-18  1:12 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-18  1:11 [PATCH 0/8] zonefs improvements Damien Le Moal
2022-04-18  1:12 ` [PATCH 1/8] zonefs: Clear inode information flags on inode creation Damien Le Moal
2022-04-19  9:27   ` Johannes Thumshirn
2022-04-18  1:12 ` [PATCH 2/8] zonefs: Fix management of open zones Damien Le Moal
2022-04-19  9:38   ` Johannes Thumshirn
2022-04-18  1:12 ` [PATCH 3/8] zonefs: Rename super block information fields Damien Le Moal
2022-04-19  9:29   ` Johannes Thumshirn
2022-04-18  1:12 ` [PATCH 4/8] zonefs: Always do seq file write open accounting Damien Le Moal
2022-04-19  9:55   ` Johannes Thumshirn
2022-04-18  1:12 ` [PATCH 5/8] zonefs: Export open zone resource information through sysfs Damien Le Moal
2022-04-19 10:06   ` Johannes Thumshirn
2022-04-18  1:12 ` [PATCH 6/8] zonefs: Add active seq file accounting Damien Le Moal
2022-04-19 10:59   ` Johannes Thumshirn
2022-04-19 11:02     ` Damien Le Moal
2022-04-19 11:06       ` Johannes Thumshirn
2022-04-19 11:26         ` Damien Le Moal
2022-04-18  1:12 ` [PATCH 7/8] documentation: zonefs: Cleanup the mount options section Damien Le Moal
2022-04-19 10:14   ` Johannes Thumshirn
2022-04-18  1:12 ` Damien Le Moal [this message]
2022-04-19 10:14   ` [PATCH 8/8] documentation: zonefs: Document sysfs attributes Johannes Thumshirn

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220418011207.2385416-9-damien.lemoal@opensource.wdc.com \
    --to=damien.lemoal@opensource.wdc.com \
    --cc=johannes.thumshirn@wdc.com \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.