All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation
@ 2023-01-18  7:44 Naohiro Aota
  2023-01-18  7:44 ` [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry Naohiro Aota
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Naohiro Aota @ 2023-01-18  7:44 UTC (permalink / raw)
  To: linux-btrfs; +Cc: Naohiro Aota

This series adds a description for per-space_info bg_reclaim_threshold
and chunk_size. It also fixes a subtle typo.

Naohiro Aota (3):
  btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry
  btrfs-progs: docs: fix nodesize typo
  btrfs-progs: docs: add chunk_size description

 Documentation/ch-sysfs.rst | 18 ++++++++++++++++--
 1 file changed, 16 insertions(+), 2 deletions(-)

-- 
2.39.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry
  2023-01-18  7:44 [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation Naohiro Aota
@ 2023-01-18  7:44 ` Naohiro Aota
  2023-01-18 10:43   ` Johannes Thumshirn
  2023-01-18  7:44 ` [PATCH 2/3] btrfs-progs: docs: fix nodesize typo Naohiro Aota
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 6+ messages in thread
From: Naohiro Aota @ 2023-01-18  7:44 UTC (permalink / raw)
  To: linux-btrfs; +Cc: Naohiro Aota

There are two "bg_reclaim_threshold" under the sysfs directory. One is at
/sys/fs/btrfs/<UUID>/ and sets the threshold to start the auto reclaim
thread. The other one is
at/sys/fs/btrfs/<UUID>/allocations/{data,metadata,system} and sets the
threshold to reclaim a block group.

These two options have the same name but they are calculated against
different metrics. The former is a percentage of allocated (for a device
extent) space on total device space, and the latter is a percentage of
reclaimable space on a block group's zone capacity.

Add description for per-space_info bg_reclaim_threshold to distinguish
these two same name configurations.

Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com>
---
 Documentation/ch-sysfs.rst | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/Documentation/ch-sysfs.rst b/Documentation/ch-sysfs.rst
index 96fdaa34bff3..37fb49f945c7 100644
--- a/Documentation/ch-sysfs.rst
+++ b/Documentation/ch-sysfs.rst
@@ -29,7 +29,7 @@ Files in `/sys/fs/btrfs/<UUID>/` directory are:
 bg_reclaim_threshold
         (RW, since: 5.19)
 
-        Used space percentage to start auto block group claim.
+        Used space percentage of total device space to start auto block group claim.
         Mostly for zoned devices.
 
 checksum
@@ -117,6 +117,14 @@ global_rsv_size
         Space info accounting for the 3 chunk types.
         Mostly for debug purposes.
 
+Files in `/sys/fs/btrfs/<UUID>/allocations/{data,metadata,system}` directory are:
+
+bg_reclaim_threshold
+        (RW, since: 5.19)
+
+        Reclaimable space percentage of block group's size (excluding permanently unusable space) to reclaim the block group.
+        Used for zoned devices.
+
 Files in `/sys/fs/btrfs/<UUID>/devinfo/<DEVID>` directory are:
 
 error_stats:
-- 
2.39.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/3] btrfs-progs: docs: fix nodesize typo
  2023-01-18  7:44 [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation Naohiro Aota
  2023-01-18  7:44 ` [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry Naohiro Aota
@ 2023-01-18  7:44 ` Naohiro Aota
  2023-01-18  7:44 ` [PATCH 3/3] btrfs-progs: docs: add chunk_size description Naohiro Aota
  2023-01-18 20:07 ` [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation David Sterba
  3 siblings, 0 replies; 6+ messages in thread
From: Naohiro Aota @ 2023-01-18  7:44 UTC (permalink / raw)
  To: linux-btrfs; +Cc: Naohiro Aota

Fix the typo.

Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com>
---
 Documentation/ch-sysfs.rst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/ch-sysfs.rst b/Documentation/ch-sysfs.rst
index 37fb49f945c7..569879aadf27 100644
--- a/Documentation/ch-sysfs.rst
+++ b/Documentation/ch-sysfs.rst
@@ -75,7 +75,7 @@ metadata_uuid
         Shows the metadata uuid of the mounted filesystem.
         Check `metadata_uuid` feature for more details.
 
-nodeisze
+nodesize
         (RO, since: 3.14)
 
         Show the nodesize of the mounted filesystem.
-- 
2.39.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 3/3] btrfs-progs: docs: add chunk_size description
  2023-01-18  7:44 [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation Naohiro Aota
  2023-01-18  7:44 ` [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry Naohiro Aota
  2023-01-18  7:44 ` [PATCH 2/3] btrfs-progs: docs: fix nodesize typo Naohiro Aota
@ 2023-01-18  7:44 ` Naohiro Aota
  2023-01-18 20:07 ` [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation David Sterba
  3 siblings, 0 replies; 6+ messages in thread
From: Naohiro Aota @ 2023-01-18  7:44 UTC (permalink / raw)
  To: linux-btrfs; +Cc: Naohiro Aota

Add description for /sys/fs/btrfs/<uuid>/allocation/<type>/chunk_size.

Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com>
---
 Documentation/ch-sysfs.rst | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/Documentation/ch-sysfs.rst b/Documentation/ch-sysfs.rst
index 569879aadf27..09e409a41aa5 100644
--- a/Documentation/ch-sysfs.rst
+++ b/Documentation/ch-sysfs.rst
@@ -125,6 +125,12 @@ bg_reclaim_threshold
         Reclaimable space percentage of block group's size (excluding permanently unusable space) to reclaim the block group.
         Used for zoned devices.
 
+chunk_size
+        (RW, since: 6.0)
+
+        Shows the chunk size. Can be changed for data and metadata.
+        Cannot be set for zoned devices.
+
 Files in `/sys/fs/btrfs/<UUID>/devinfo/<DEVID>` directory are:
 
 error_stats:
-- 
2.39.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry
  2023-01-18  7:44 ` [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry Naohiro Aota
@ 2023-01-18 10:43   ` Johannes Thumshirn
  0 siblings, 0 replies; 6+ messages in thread
From: Johannes Thumshirn @ 2023-01-18 10:43 UTC (permalink / raw)
  To: Naohiro Aota, linux-btrfs

On 18.01.23 09:16, Naohiro Aota wrote:
> +Files in `/sys/fs/btrfs/<UUID>/allocations/{data,metadata,system}` directory are:
> +
> +bg_reclaim_threshold
> +        (RW, since: 5.19)
> +
> +        Reclaimable space percentage of block group's size (excluding permanently unusable space) to reclaim the block group.
> +        Used for zoned devices.

I'd discard the last sentence, as the bg_reclaim_threshold is 
used on non-zoned devices as well.

> +
>  Files in `/sys/fs/btrfs/<UUID>/devinfo/<DEVID>` directory are:


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation
  2023-01-18  7:44 [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation Naohiro Aota
                   ` (2 preceding siblings ...)
  2023-01-18  7:44 ` [PATCH 3/3] btrfs-progs: docs: add chunk_size description Naohiro Aota
@ 2023-01-18 20:07 ` David Sterba
  3 siblings, 0 replies; 6+ messages in thread
From: David Sterba @ 2023-01-18 20:07 UTC (permalink / raw)
  To: Naohiro Aota; +Cc: linux-btrfs

On Wed, Jan 18, 2023 at 04:44:55PM +0900, Naohiro Aota wrote:
> This series adds a description for per-space_info bg_reclaim_threshold
> and chunk_size. It also fixes a subtle typo.
> 
> Naohiro Aota (3):
>   btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry
>   btrfs-progs: docs: fix nodesize typo
>   btrfs-progs: docs: add chunk_size description

Added to devel, thanks. For the bg_reclaim I've added that it can be
used for regular devices too.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-01-18 20:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-18  7:44 [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation Naohiro Aota
2023-01-18  7:44 ` [PATCH 1/3] btrfs-progs: docs: add per-space_info bg_reclaim_threshold entry Naohiro Aota
2023-01-18 10:43   ` Johannes Thumshirn
2023-01-18  7:44 ` [PATCH 2/3] btrfs-progs: docs: fix nodesize typo Naohiro Aota
2023-01-18  7:44 ` [PATCH 3/3] btrfs-progs: docs: add chunk_size description Naohiro Aota
2023-01-18 20:07 ` [PATCH 0/3] btrfs-progs: docs: add entries to sysfs documentation David Sterba

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.