Linux-EROFS Archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype
@ 2023-04-09 11:56 Ahelenia Ziemiańska
  2023-04-09 11:56 ` [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing Ahelenia Ziemiańska
                   ` (4 more replies)
  0 siblings, 5 replies; 12+ messages in thread
From: Ahelenia Ziemiańska @ 2023-04-09 11:56 UTC (permalink / raw
  Cc: linux-erofs mailing list

[-- Attachment #1: Type: text/plain, Size: 1264 bytes --]

In file included from rb_tree.c:34:
./rb_tree.h:96:17: warning: a function declaration without a prototype
is deprecated in all versions of C and is treated as a zero-parameter
prototype in C2x, conflicting with a subsequent definition
[-Wdeprecated-non-prototype]
struct rb_iter *rb_iter_init            ();
                ^
rb_tree.c:422:1: note: conflicting prototype is here
rb_iter_init (struct rb_iter *self) {
^

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
---
 lib/rb_tree.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/rb_tree.h b/lib/rb_tree.h
index 5b35c74..67ec0a7 100644
--- a/lib/rb_tree.h
+++ b/lib/rb_tree.h
@@ -93,7 +93,7 @@ int             rb_tree_remove_with_cb  (struct rb_tree *self, void *value, rb_t
 int             rb_tree_test            (struct rb_tree *self, struct rb_node *root);
 
 struct rb_iter *rb_iter_alloc           ();
-struct rb_iter *rb_iter_init            ();
+struct rb_iter *rb_iter_init            (struct rb_iter *self);
 struct rb_iter *rb_iter_create          ();
 void            rb_iter_dealloc         (struct rb_iter *self);
 void           *rb_iter_first           (struct rb_iter *self, struct rb_tree *tree);
-- 
2.30.2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing
  2023-04-09 11:56 [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Ahelenia Ziemiańska
@ 2023-04-09 11:56 ` Ahelenia Ziemiańska
  2023-04-09 12:26   ` Gao Xiang
  2023-04-09 11:56 ` [PATCH 3/5] erofs-utils: man: mkfs.erofs: wording/formatting touchups Ahelenia Ziemiańska
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 12+ messages in thread
From: Ahelenia Ziemiańska @ 2023-04-09 11:56 UTC (permalink / raw
  Cc: linux-erofs mailing list

[-- Attachment #1: Type: text/plain, Size: 624 bytes --]

-z is specified as "z:".

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
---
 mkfs/main.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/mkfs/main.c b/mkfs/main.c
index 94f51df..d20147c 100644
--- a/mkfs/main.c
+++ b/mkfs/main.c
@@ -276,11 +276,6 @@ static int mkfs_parse_options_cfg(int argc, char *argv[])
 				  long_options, NULL)) != -1) {
 		switch (opt) {
 		case 'z':
-			if (!optarg) {
-				cfg.c_compr_alg[0] = "(default)";
-				cfg.c_compr_level[0] = -1;
-				break;
-			}
 			i = mkfs_parse_compress_algs(optarg);
 			if (i)
 				return i;
-- 
2.30.2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* [PATCH 3/5] erofs-utils: man: mkfs.erofs: wording/formatting touchups
  2023-04-09 11:56 [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Ahelenia Ziemiańska
  2023-04-09 11:56 ` [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing Ahelenia Ziemiańska
@ 2023-04-09 11:56 ` Ahelenia Ziemiańska
  2023-04-09 12:46   ` Gao Xiang
  2023-04-09 11:56 ` [PATCH 4/5] erofs-utils: man: fsck.erofs: " Ahelenia Ziemiańska
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 12+ messages in thread
From: Ahelenia Ziemiańska @ 2023-04-09 11:56 UTC (permalink / raw
  Cc: linux-erofs mailing list

[-- Attachment #1: Type: text/plain, Size: 7937 bytes --]

Some things that gave me pause or were weirdly formatted.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
---
 man/mkfs.erofs.1 | 100 +++++++++++++++++++++++++++--------------------
 1 file changed, 57 insertions(+), 43 deletions(-)

diff --git a/man/mkfs.erofs.1 b/man/mkfs.erofs.1
index 82ef138..1cfde28 100644
--- a/man/mkfs.erofs.1
+++ b/man/mkfs.erofs.1
@@ -20,25 +20,25 @@ mkfs.erofs is used to create such EROFS filesystem \fIDESTINATION\fR image file
 from \fISOURCE\fR directory.
 .SH OPTIONS
 .TP
-.BI "\-z " compression-algorithm " [" ",#" "]" " [:" " ... " "]"
+.BI "\-z " compression-algorithm \fR[\fP, # \fR][\fP: ... \fR]\fP
 Set a primary algorithm for data compression, which can be set with an optional
 compression level (1 to 12 for LZ4HC, 0 to 9 for LZMA and 100 to 109 for LZMA
 extreme compression) separated by a comma.  Alternative algorithms could be
 specified and separated by colons.
 .TP
 .BI "\-C " max-pcluster-size
-Specify the maximum size of compress physical cluster in bytes. It may enable
-big pcluster feature if needed (Linux v5.13+).
+Specify the maximum size of compress physical cluster in bytes.
+This may cause the big pcluster feature to be enabled (Linux v5.13+).
 .TP
 .BI "\-d " #
 Specify the level of debugging messages. The default is 2, which shows basic
 warning messages.
 .TP
 .BI "\-x " #
-Specify the upper limit of an xattr which is still inlined. The default is 2.
-Disable storing xattrs if < 0.
+Limit how many xattrs will be inlined. The default is 2.
+Disables storing xattrs if < 0.
 .TP
-.BI "\-E " extended-option " [,...]"
+.BI "\-E " extended-option \fR[\fP, ... \fR]\fP
 Set extended options for the filesystem. Extended options are comma separated,
 and may take an extra argument using the equals ('=') sign.
 The following extended options are supported:
@@ -51,29 +51,30 @@ it may take an argument as the pcluster size of the packed inode in bytes.
 .TP
 .BI dedupe
 Enable global compressed data deduplication to minimize duplicated data in
-the filesystem. It may be used with \fI-Efragments\fR option together to
-further reduce image sizes. (Linux v6.1+)
+the filesystem. May further reduce image size when used with
+.BR -E\ fragments .
+(Linux v6.1+)
 .TP
 .BI force-inode-compact
-Forcely generate compact inodes (32-byte inodes) to output.
+Force generation of compact (32-byte) inodes.
 .TP
 .BI force-inode-extended
-Forcely generate extended inodes (64-byte inodes) to output.
+Force generation of extended (64-byte) inodes.
 .TP
 .BI force-inode-blockmap
-Forcely generate inode chunk format in 4-byte block address array.
+Force generation of inode chunk format as a 4-byte block address array.
 .TP
 .BI force-chunk-indexes
-Forcely generate inode chunk format in 8-byte chunk indexes (with device id).
+Forcely generate inode chunk format as an 8-byte chunk index (with device ID).
 .TP
-.BI fragments
-Pack the tail part (pcluster) of compressed files or the whole files into a
+.BI fragments\fR[\fP= size \fR]\fP
+Pack the tail part (pcluster) of compressed files, or entire files, into a
 special inode for smaller image sizes, and it may take an argument as the
 pcluster size of the packed inode in bytes. (Linux v6.1+)
 .TP
 .BI legacy-compress
-Drop "inplace decompression" and "compacted indexes" support, which is used
-to generate compatible EROFS images for Linux v4.19 - 5.3.
+Disable "inplace decompression" and "compacted indexes",
+for compatibility with Linux pre-v5.4.
 .TP
 .BI noinline_data
 Don't inline regular files to enable FSDAX for these files (Linux v5.15+).
@@ -89,8 +90,8 @@ Set the volume label for the filesystem to
 The maximum length of the volume label is 16 bytes.
 .TP
 .BI "\-T " #
-Set all files to the given UNIX timestamp. Reproducible builds requires setting
-all to a specific one.
+Set all files to the given UNIX timestamp. Reproducible builds require setting
+all to a specific one. By default, the source file's modification time is used.
 .TP
 .BI "\-U " UUID
 Set the universally unique identifier (UUID) of the filesystem to
@@ -102,64 +103,77 @@ like this: "c1b9d5a2-f162-11cf-9ece-0020afc76f16".
 Make all files owned by root.
 .TP
 .BI "\-\-blobdev " file
-Specify another extra blob device to store chunk-based data.
+Specify an extra blob device to store chunk-based data.
 .TP
 .BI "\-\-chunksize " #
 Generate chunk-based files with #-byte chunks.
 .TP
 .BI "\-\-compress-hints " file
-If the optional
-.BI "\-\-compress-hints " file
-argument is given,
-.B mkfs.erofs
-uses it to apply the per-file compression strategy. Each line is defined by
+Apply a per-file compression strategy. Each line in
+.I file
+is defined by
 tokens separated by spaces in the following form.  Optionally, instead of
-the given primary algorithm, alternative algorithms could be specified with
-\fIalgorithm-index\fR by hand:
+the given primary algorithm, alternative algorithms can be specified with
+\fIalgorithm-index\fR explicitly:
 .RS 1.2i
-<pcluster-in-bytes> [algorithm-index] <match-pattern>
+<pcluster-size-in-bytes> [algorithm-index] <match-pattern>
 .RE
+.IR match-pattern s
+are extended regular expressions, matched against absolute paths within
+the output filesystem, with no leading /.
 .TP
 .BI "\-\-exclude-path=" path
 Ignore file that matches the exact literal path.
-You may give multiple `--exclude-path' options.
+You may give multiple
+.B --exclude-path
+options.
 .TP
 .BI "\-\-exclude-regex=" regex
-Ignore files that match the given regular expression.
-You may give multiple `--exclude-regex` options.
+Ignore files that match the given extended regular expression.
+You may give multiple
+.B --exclude-regex
+options.
 .TP
 .BI "\-\-file-contexts=" file
-Specify a \fIfile_contexts\fR file to setup / override selinux labels.
+Read SELinux label configuration/overrides from \fIfile\fR in the
+.BR selinux_file (5)
+format.
 .TP
 .BI "\-\-force-uid=" UID
-Set all file uids to \fIUID\fR.
+Set all file UIDs to \fIUID\fR.
 .TP
 .BI "\-\-force-gid=" GID
-Set all file gids to \fIGID\fR.
+Set all file GIDs to \fIGID\fR.
 .TP
 .BI "\-\-gid-offset=" GIDOFFSET
-Add \fIGIDOFFSET\fR to all file gids.
-When this option is used together with --force-gid, the final file gids are
+Add \fIGIDOFFSET\fR to all file GIDs.
+When this option is used together with
+.BR --force-gid ,
+the final file gids are
 set to \fIGID\fR + \fIGID-OFFSET\fR.
 .TP
 .B \-\-help
-Display this help and exit.
+Display help string and exit.
 .TP
 .B "\-\-ignore-mtime"
-File modification time is ignored whenever it would cause \fBmkfs.erofs\fR to
+Ignore the file modification time whenever it would cause \fBmkfs.erofs\fR to
 use extended inodes over compact inodes. When not using a fixed timestamp, this
-can reduce total metadata size.
+can reduce total metadata size. Implied by
+.BR "-E force-inode-compact" .
 .TP
 .BI "\-\-max-extent-bytes " #
-Specify maximum decompressed extent size # in bytes.
+Specify maximum decompressed extent size in bytes.
 .TP
 .B "\-\-preserve-mtime"
-File modification time is preserved whenever \fBmkfs.erofs\fR decides to use
-extended inodes over compact inodes.
+Use extended inodes instead of compact inodes if the file modification time
+would overflow compact inodes. This is the default. Overrides
+.BR --ignore-mtime .
 .TP
 .BI "\-\-uid-offset=" UIDOFFSET
-Add \fIUIDOFFSET\fR to all file uids.
-When this option is used together with --force-uid, the final file uids are
+Add \fIUIDOFFSET\fR to all file UIDs.
+When this option is used together with
+.BR --force-uid ,
+the final file uids are
 set to \fIUID\fR + \fIUIDOFFSET\fR.
 .SH AUTHOR
 This version of \fBmkfs.erofs\fR is written by Li Guifu <blucerlee@gmail.com>,
-- 
2.30.2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* [PATCH 4/5] erofs-utils: man: fsck.erofs: wording/formatting touchups
  2023-04-09 11:56 [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Ahelenia Ziemiańska
  2023-04-09 11:56 ` [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing Ahelenia Ziemiańska
  2023-04-09 11:56 ` [PATCH 3/5] erofs-utils: man: mkfs.erofs: wording/formatting touchups Ahelenia Ziemiańska
@ 2023-04-09 11:56 ` Ahelenia Ziemiańska
  2023-04-09 12:48   ` Gao Xiang
  2023-04-09 11:56 ` [PATCH 5/5] erofs-utils: man: dump.erofs: " Ahelenia Ziemiańska
  2023-04-09 12:26 ` [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Gao Xiang
  4 siblings, 1 reply; 12+ messages in thread
From: Ahelenia Ziemiańska @ 2023-04-09 11:56 UTC (permalink / raw
  Cc: linux-erofs mailing list

[-- Attachment #1: Type: text/plain, Size: 1528 bytes --]

Some things that gave me pause or were weirdly formatted.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
---
 man/fsck.erofs.1 | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/man/fsck.erofs.1 b/man/fsck.erofs.1
index f3e9c3b..d53f36b 100644
--- a/man/fsck.erofs.1
+++ b/man/fsck.erofs.1
@@ -2,7 +2,7 @@
 .\"
 .TH FSCK.EROFS 1
 .SH NAME
-fsck.erofs \- tool to check the EROFS filesystem's integrity
+fsck.erofs \- tool to check an EROFS filesystem's integrity
 .SH SYNOPSIS
 \fBfsck.erofs\fR [\fIOPTIONS\fR] \fIIMAGE\fR
 .SH DESCRIPTION
@@ -22,15 +22,18 @@ Print total compression ratio of all files including compressed and
 non-compressed files.
 .TP
 .BI "\-\-device=" path
-Specify an extra device to be used together.
-You may give multiple `--device' options in the correct order.
+Specify an extra blob device to be used together.
+You may give multiple
+.B --device
+options in the correct order.
 .TP
 .B \-\-extract
-Check if all files are well encoded. This will induce more I/Os to read
-compressed file data, so it might take too much time depending on the image.
+Check if all files are well encoded. This read all compressed files,
+and hence create more I/O load,
+so it might take too much time depending on the image.
 .TP
 .B \-\-help
-Display this help and exit.
+Display help string exit.
 .SH AUTHOR
 This version of \fBfsck.erofs\fR is written by
 Daeho Jeong <daehojeong@google.com>.
-- 
2.30.2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* [PATCH 5/5] erofs-utils: man: dump.erofs: wording/formatting touchups
  2023-04-09 11:56 [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Ahelenia Ziemiańska
                   ` (2 preceding siblings ...)
  2023-04-09 11:56 ` [PATCH 4/5] erofs-utils: man: fsck.erofs: " Ahelenia Ziemiańska
@ 2023-04-09 11:56 ` Ahelenia Ziemiańska
  2023-04-09 12:51   ` Gao Xiang
  2023-04-09 12:26 ` [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Gao Xiang
  4 siblings, 1 reply; 12+ messages in thread
From: Ahelenia Ziemiańska @ 2023-04-09 11:56 UTC (permalink / raw
  Cc: linux-erofs mailing list

[-- Attachment #1: Type: text/plain, Size: 2144 bytes --]

Some things that gave me pause or were weirdly formatted.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
---
 man/dump.erofs.1 | 25 ++++++++++++++++++++-----
 1 file changed, 20 insertions(+), 5 deletions(-)

diff --git a/man/dump.erofs.1 b/man/dump.erofs.1
index 209e5f9..7316f4b 100644
--- a/man/dump.erofs.1
+++ b/man/dump.erofs.1
@@ -9,18 +9,28 @@ or overall disk statistics information from an EROFS-formatted image.
 .SH DESCRIPTION
 .B dump.erofs
 is used to retrieve erofs metadata from \fIIMAGE\fP and demonstrate
+.br
 1) overall disk statistics,
+.br
 2) superblock information,
+.br
 3) file information of the given inode NID,
+.br
 4) file extent information of the given inode NID.
 .SH OPTIONS
 .TP
 .BI "\-\-device=" path
 Specify an extra device to be used together.
-You may give multiple `--device' options in the correct order.
+You may give multiple
+.B --device
+options in the correct order.
 .TP
 .BI "\-\-ls"
-List directory contents. An inode should be specified together.
+List directory contents.
+.I NID
+or
+.I path
+required.
 .TP
 .BI "\-\-nid=" NID
 Specify an inode NID in order to print its file information.
@@ -29,16 +39,21 @@ Specify an inode NID in order to print its file information.
 Specify an inode path in order to print its file information.
 .TP
 .BI \-e
-Show the file extent information. An inode should be specified together.
+Show the file extent information.
+.I NID
+or
+.I path
+required.
 .TP
 .BI \-V
 Print the version number and exit.
 .TP
 .BI \-s
-Show superblock information of the an EROFS-formatted image.
+Show superblock information.
+This is the default if no options are specified.
 .TP
 .BI \-S
-Show EROFS disk statistics, including file type/size distribution, number of (un)compressed files, compression ratio of the whole image, etc.
+Show image statistics, including file type/size distribution, number of (un)compressed files, compression ratio, etc.
 .SH AUTHOR
 Initial code was written by Wang Qi <mpiglet@outlook.com>, Guo Xuenan <guoxuenan@huawei.com>.
 .PP
-- 
2.30.2

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype
  2023-04-09 11:56 [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Ahelenia Ziemiańska
                   ` (3 preceding siblings ...)
  2023-04-09 11:56 ` [PATCH 5/5] erofs-utils: man: dump.erofs: " Ahelenia Ziemiańska
@ 2023-04-09 12:26 ` Gao Xiang
  4 siblings, 0 replies; 12+ messages in thread
From: Gao Xiang @ 2023-04-09 12:26 UTC (permalink / raw
  To: Ahelenia Ziemiańska; +Cc: linux-erofs mailing list



On 2023/4/9 19:56, Ahelenia Ziemiańska wrote:
> In file included from rb_tree.c:34:
> ./rb_tree.h:96:17: warning: a function declaration without a prototype
> is deprecated in all versions of C and is treated as a zero-parameter
> prototype in C2x, conflicting with a subsequent definition
> [-Wdeprecated-non-prototype]
> struct rb_iter *rb_iter_init            ();
>                  ^
> rb_tree.c:422:1: note: conflicting prototype is here
> rb_iter_init (struct rb_iter *self) {
> ^
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>

Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> ---
>   lib/rb_tree.h | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/lib/rb_tree.h b/lib/rb_tree.h
> index 5b35c74..67ec0a7 100644
> --- a/lib/rb_tree.h
> +++ b/lib/rb_tree.h
> @@ -93,7 +93,7 @@ int             rb_tree_remove_with_cb  (struct rb_tree *self, void *value, rb_t
>   int             rb_tree_test            (struct rb_tree *self, struct rb_node *root);
>   
>   struct rb_iter *rb_iter_alloc           ();
> -struct rb_iter *rb_iter_init            ();
> +struct rb_iter *rb_iter_init            (struct rb_iter *self);
>   struct rb_iter *rb_iter_create          ();
>   void            rb_iter_dealloc         (struct rb_iter *self);
>   void           *rb_iter_first           (struct rb_iter *self, struct rb_tree *tree);

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

* Re: [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing
  2023-04-09 11:56 ` [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing Ahelenia Ziemiańska
@ 2023-04-09 12:26   ` Gao Xiang
  0 siblings, 0 replies; 12+ messages in thread
From: Gao Xiang @ 2023-04-09 12:26 UTC (permalink / raw
  To: Ahelenia Ziemiańska; +Cc: linux-erofs mailing list



On 2023/4/9 19:56, Ahelenia Ziemiańska wrote:
> -z is specified as "z:".
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>

Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> ---
>   mkfs/main.c | 5 -----
>   1 file changed, 5 deletions(-)
> 
> diff --git a/mkfs/main.c b/mkfs/main.c
> index 94f51df..d20147c 100644
> --- a/mkfs/main.c
> +++ b/mkfs/main.c
> @@ -276,11 +276,6 @@ static int mkfs_parse_options_cfg(int argc, char *argv[])
>   				  long_options, NULL)) != -1) {
>   		switch (opt) {
>   		case 'z':
> -			if (!optarg) {
> -				cfg.c_compr_alg[0] = "(default)";
> -				cfg.c_compr_level[0] = -1;
> -				break;
> -			}
>   			i = mkfs_parse_compress_algs(optarg);
>   			if (i)
>   				return i;

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

* Re: [PATCH 3/5] erofs-utils: man: mkfs.erofs: wording/formatting touchups
  2023-04-09 11:56 ` [PATCH 3/5] erofs-utils: man: mkfs.erofs: wording/formatting touchups Ahelenia Ziemiańska
@ 2023-04-09 12:46   ` Gao Xiang
  0 siblings, 0 replies; 12+ messages in thread
From: Gao Xiang @ 2023-04-09 12:46 UTC (permalink / raw
  To: Ahelenia Ziemiańska; +Cc: linux-erofs mailing list



On 2023/4/9 19:56, Ahelenia Ziemiańska wrote:
> Some things that gave me pause or were weirdly formatted.
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>

Thanks, it looks much better than the current status.

Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> ---
>   man/mkfs.erofs.1 | 100 +++++++++++++++++++++++++++--------------------
>   1 file changed, 57 insertions(+), 43 deletions(-)
> 
> diff --git a/man/mkfs.erofs.1 b/man/mkfs.erofs.1
> index 82ef138..1cfde28 100644
> --- a/man/mkfs.erofs.1
> +++ b/man/mkfs.erofs.1
> @@ -20,25 +20,25 @@ mkfs.erofs is used to create such EROFS filesystem \fIDESTINATION\fR image file
>   from \fISOURCE\fR directory.
>   .SH OPTIONS
>   .TP
> -.BI "\-z " compression-algorithm " [" ",#" "]" " [:" " ... " "]"
> +.BI "\-z " compression-algorithm \fR[\fP, # \fR][\fP: ... \fR]\fP
>   Set a primary algorithm for data compression, which can be set with an optional
>   compression level (1 to 12 for LZ4HC, 0 to 9 for LZMA and 100 to 109 for LZMA
>   extreme compression) separated by a comma.  Alternative algorithms could be
>   specified and separated by colons.
>   .TP
>   .BI "\-C " max-pcluster-size
> -Specify the maximum size of compress physical cluster in bytes. It may enable
> -big pcluster feature if needed (Linux v5.13+).
> +Specify the maximum size of compress physical cluster in bytes.
> +This may cause the big pcluster feature to be enabled (Linux v5.13+).
>   .TP
>   .BI "\-d " #
>   Specify the level of debugging messages. The default is 2, which shows basic
>   warning messages.
>   .TP
>   .BI "\-x " #
> -Specify the upper limit of an xattr which is still inlined. The default is 2.
> -Disable storing xattrs if < 0.
> +Limit how many xattrs will be inlined. The default is 2.
> +Disables storing xattrs if < 0.
>   .TP
> -.BI "\-E " extended-option " [,...]"
> +.BI "\-E " extended-option \fR[\fP, ... \fR]\fP
>   Set extended options for the filesystem. Extended options are comma separated,
>   and may take an extra argument using the equals ('=') sign.
>   The following extended options are supported:
> @@ -51,29 +51,30 @@ it may take an argument as the pcluster size of the packed inode in bytes.
>   .TP
>   .BI dedupe
>   Enable global compressed data deduplication to minimize duplicated data in
> -the filesystem. It may be used with \fI-Efragments\fR option together to
> -further reduce image sizes. (Linux v6.1+)
> +the filesystem. May further reduce image size when used with
> +.BR -E\ fragments .
> +(Linux v6.1+)
>   .TP
>   .BI force-inode-compact
> -Forcely generate compact inodes (32-byte inodes) to output.
> +Force generation of compact (32-byte) inodes.
>   .TP
>   .BI force-inode-extended
> -Forcely generate extended inodes (64-byte inodes) to output.
> +Force generation of extended (64-byte) inodes.
>   .TP
>   .BI force-inode-blockmap
> -Forcely generate inode chunk format in 4-byte block address array.
> +Force generation of inode chunk format as a 4-byte block address array.
>   .TP
>   .BI force-chunk-indexes
> -Forcely generate inode chunk format in 8-byte chunk indexes (with device id).
> +Forcely generate inode chunk format as an 8-byte chunk index (with device ID).
>   .TP
> -.BI fragments
> -Pack the tail part (pcluster) of compressed files or the whole files into a
> +.BI fragments\fR[\fP= size \fR]\fP
> +Pack the tail part (pcluster) of compressed files, or entire files, into a
>   special inode for smaller image sizes, and it may take an argument as the
>   pcluster size of the packed inode in bytes. (Linux v6.1+)
>   .TP
>   .BI legacy-compress
> -Drop "inplace decompression" and "compacted indexes" support, which is used
> -to generate compatible EROFS images for Linux v4.19 - 5.3.
> +Disable "inplace decompression" and "compacted indexes",
> +for compatibility with Linux pre-v5.4.
>   .TP
>   .BI noinline_data
>   Don't inline regular files to enable FSDAX for these files (Linux v5.15+).
> @@ -89,8 +90,8 @@ Set the volume label for the filesystem to
>   The maximum length of the volume label is 16 bytes.
>   .TP
>   .BI "\-T " #
> -Set all files to the given UNIX timestamp. Reproducible builds requires setting
> -all to a specific one.
> +Set all files to the given UNIX timestamp. Reproducible builds require setting
> +all to a specific one. By default, the source file's modification time is used.
>   .TP
>   .BI "\-U " UUID
>   Set the universally unique identifier (UUID) of the filesystem to
> @@ -102,64 +103,77 @@ like this: "c1b9d5a2-f162-11cf-9ece-0020afc76f16".
>   Make all files owned by root.
>   .TP
>   .BI "\-\-blobdev " file
> -Specify another extra blob device to store chunk-based data.
> +Specify an extra blob device to store chunk-based data.
>   .TP
>   .BI "\-\-chunksize " #
>   Generate chunk-based files with #-byte chunks.
>   .TP
>   .BI "\-\-compress-hints " file
> -If the optional
> -.BI "\-\-compress-hints " file
> -argument is given,
> -.B mkfs.erofs
> -uses it to apply the per-file compression strategy. Each line is defined by
> +Apply a per-file compression strategy. Each line in
> +.I file
> +is defined by
>   tokens separated by spaces in the following form.  Optionally, instead of
> -the given primary algorithm, alternative algorithms could be specified with
> -\fIalgorithm-index\fR by hand:
> +the given primary algorithm, alternative algorithms can be specified with
> +\fIalgorithm-index\fR explicitly:
>   .RS 1.2i
> -<pcluster-in-bytes> [algorithm-index] <match-pattern>
> +<pcluster-size-in-bytes> [algorithm-index] <match-pattern>
>   .RE
> +.IR match-pattern s
> +are extended regular expressions, matched against absolute paths within
> +the output filesystem, with no leading /.
>   .TP
>   .BI "\-\-exclude-path=" path
>   Ignore file that matches the exact literal path.
> -You may give multiple `--exclude-path' options.
> +You may give multiple
> +.B --exclude-path
> +options.
>   .TP
>   .BI "\-\-exclude-regex=" regex
> -Ignore files that match the given regular expression.
> -You may give multiple `--exclude-regex` options.
> +Ignore files that match the given extended regular expression.
> +You may give multiple
> +.B --exclude-regex
> +options.
>   .TP
>   .BI "\-\-file-contexts=" file
> -Specify a \fIfile_contexts\fR file to setup / override selinux labels.
> +Read SELinux label configuration/overrides from \fIfile\fR in the
> +.BR selinux_file (5)
> +format.
>   .TP
>   .BI "\-\-force-uid=" UID
> -Set all file uids to \fIUID\fR.
> +Set all file UIDs to \fIUID\fR.
>   .TP
>   .BI "\-\-force-gid=" GID
> -Set all file gids to \fIGID\fR.
> +Set all file GIDs to \fIGID\fR.
>   .TP
>   .BI "\-\-gid-offset=" GIDOFFSET
> -Add \fIGIDOFFSET\fR to all file gids.
> -When this option is used together with --force-gid, the final file gids are
> +Add \fIGIDOFFSET\fR to all file GIDs.
> +When this option is used together with
> +.BR --force-gid ,
> +the final file gids are
>   set to \fIGID\fR + \fIGID-OFFSET\fR.
>   .TP
>   .B \-\-help
> -Display this help and exit.
> +Display help string and exit.
>   .TP
>   .B "\-\-ignore-mtime"
> -File modification time is ignored whenever it would cause \fBmkfs.erofs\fR to
> +Ignore the file modification time whenever it would cause \fBmkfs.erofs\fR to
>   use extended inodes over compact inodes. When not using a fixed timestamp, this
> -can reduce total metadata size.
> +can reduce total metadata size. Implied by
> +.BR "-E force-inode-compact" .
>   .TP
>   .BI "\-\-max-extent-bytes " #
> -Specify maximum decompressed extent size # in bytes.
> +Specify maximum decompressed extent size in bytes.
>   .TP
>   .B "\-\-preserve-mtime"
> -File modification time is preserved whenever \fBmkfs.erofs\fR decides to use
> -extended inodes over compact inodes.
> +Use extended inodes instead of compact inodes if the file modification time
> +would overflow compact inodes. This is the default. Overrides
> +.BR --ignore-mtime .
>   .TP
>   .BI "\-\-uid-offset=" UIDOFFSET
> -Add \fIUIDOFFSET\fR to all file uids.
> -When this option is used together with --force-uid, the final file uids are
> +Add \fIUIDOFFSET\fR to all file UIDs.
> +When this option is used together with
> +.BR --force-uid ,
> +the final file uids are
>   set to \fIUID\fR + \fIUIDOFFSET\fR.
>   .SH AUTHOR
>   This version of \fBmkfs.erofs\fR is written by Li Guifu <blucerlee@gmail.com>,

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

* Re: [PATCH 4/5] erofs-utils: man: fsck.erofs: wording/formatting touchups
  2023-04-09 11:56 ` [PATCH 4/5] erofs-utils: man: fsck.erofs: " Ahelenia Ziemiańska
@ 2023-04-09 12:48   ` Gao Xiang
  2023-04-09 13:41     ` [PATCH v2 " Ahelenia Ziemiańska
  0 siblings, 1 reply; 12+ messages in thread
From: Gao Xiang @ 2023-04-09 12:48 UTC (permalink / raw
  To: Ahelenia Ziemiańska; +Cc: linux-erofs mailing list



On 2023/4/9 19:56, Ahelenia Ziemiańska wrote:
> Some things that gave me pause or were weirdly formatted.
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
> ---
>   man/fsck.erofs.1 | 15 +++++++++------
>   1 file changed, 9 insertions(+), 6 deletions(-)
> 
> diff --git a/man/fsck.erofs.1 b/man/fsck.erofs.1
> index f3e9c3b..d53f36b 100644
> --- a/man/fsck.erofs.1
> +++ b/man/fsck.erofs.1
> @@ -2,7 +2,7 @@
>   .\"
>   .TH FSCK.EROFS 1
>   .SH NAME
> -fsck.erofs \- tool to check the EROFS filesystem's integrity
> +fsck.erofs \- tool to check an EROFS filesystem's integrity
>   .SH SYNOPSIS
>   \fBfsck.erofs\fR [\fIOPTIONS\fR] \fIIMAGE\fR
>   .SH DESCRIPTION
> @@ -22,15 +22,18 @@ Print total compression ratio of all files including compressed and
>   non-compressed files.
>   .TP
>   .BI "\-\-device=" path
> -Specify an extra device to be used together.
> -You may give multiple `--device' options in the correct order.
> +Specify an extra blob device to be used together.
> +You may give multiple
> +.B --device
> +options in the correct order.
>   .TP
>   .B \-\-extract
> -Check if all files are well encoded. This will induce more I/Os to read
> -compressed file data, so it might take too much time depending on the image.
> +Check if all files are well encoded. This read all compressed files,
> +and hence create more I/O load,
> +so it might take too much time depending on the image.
>   .TP
>   .B \-\-help
> -Display this help and exit.
> +Display help string exit.

Display help string and exit.  ?

Thanks,
Gao Xiang

>   .SH AUTHOR
>   This version of \fBfsck.erofs\fR is written by
>   Daeho Jeong <daehojeong@google.com>.

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

* Re: [PATCH 5/5] erofs-utils: man: dump.erofs: wording/formatting touchups
  2023-04-09 11:56 ` [PATCH 5/5] erofs-utils: man: dump.erofs: " Ahelenia Ziemiańska
@ 2023-04-09 12:51   ` Gao Xiang
  0 siblings, 0 replies; 12+ messages in thread
From: Gao Xiang @ 2023-04-09 12:51 UTC (permalink / raw
  To: Ahelenia Ziemiańska; +Cc: linux-erofs mailing list



On 2023/4/9 19:56, Ahelenia Ziemiańska wrote:
> Some things that gave me pause or were weirdly formatted.
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>

Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> ---
>   man/dump.erofs.1 | 25 ++++++++++++++++++++-----
>   1 file changed, 20 insertions(+), 5 deletions(-)
> 
> diff --git a/man/dump.erofs.1 b/man/dump.erofs.1
> index 209e5f9..7316f4b 100644
> --- a/man/dump.erofs.1
> +++ b/man/dump.erofs.1
> @@ -9,18 +9,28 @@ or overall disk statistics information from an EROFS-formatted image.
>   .SH DESCRIPTION
>   .B dump.erofs
>   is used to retrieve erofs metadata from \fIIMAGE\fP and demonstrate
> +.br
>   1) overall disk statistics,
> +.br
>   2) superblock information,
> +.br
>   3) file information of the given inode NID,
> +.br
>   4) file extent information of the given inode NID.
>   .SH OPTIONS
>   .TP
>   .BI "\-\-device=" path
>   Specify an extra device to be used together.
> -You may give multiple `--device' options in the correct order.
> +You may give multiple
> +.B --device
> +options in the correct order.
>   .TP
>   .BI "\-\-ls"
> -List directory contents. An inode should be specified together.
> +List directory contents.
> +.I NID
> +or
> +.I path
> +required.
>   .TP
>   .BI "\-\-nid=" NID
>   Specify an inode NID in order to print its file information.
> @@ -29,16 +39,21 @@ Specify an inode NID in order to print its file information.
>   Specify an inode path in order to print its file information.
>   .TP
>   .BI \-e
> -Show the file extent information. An inode should be specified together.
> +Show the file extent information.
> +.I NID
> +or
> +.I path
> +required.
>   .TP
>   .BI \-V
>   Print the version number and exit.
>   .TP
>   .BI \-s
> -Show superblock information of the an EROFS-formatted image.
> +Show superblock information.
> +This is the default if no options are specified.
>   .TP
>   .BI \-S
> -Show EROFS disk statistics, including file type/size distribution, number of (un)compressed files, compression ratio of the whole image, etc.
> +Show image statistics, including file type/size distribution, number of (un)compressed files, compression ratio, etc.
>   .SH AUTHOR
>   Initial code was written by Wang Qi <mpiglet@outlook.com>, Guo Xuenan <guoxuenan@huawei.com>.
>   .PP

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

* [PATCH v2 4/5] erofs-utils: man: fsck.erofs: wording/formatting touchups
  2023-04-09 12:48   ` Gao Xiang
@ 2023-04-09 13:41     ` Ahelenia Ziemiańska
  2023-04-09 13:53       ` Gao Xiang
  0 siblings, 1 reply; 12+ messages in thread
From: Ahelenia Ziemiańska @ 2023-04-09 13:41 UTC (permalink / raw
  To: Gao Xiang; +Cc: linux-erofs mailing list

[-- Attachment #1: Type: text/plain, Size: 1540 bytes --]

Some things that gave me pause or were weirdly formatted.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
---
Yep :)

 man/fsck.erofs.1 | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/man/fsck.erofs.1 b/man/fsck.erofs.1
index f3e9c3b..364219a 100644
--- a/man/fsck.erofs.1
+++ b/man/fsck.erofs.1
@@ -2,7 +2,7 @@
 .\"
 .TH FSCK.EROFS 1
 .SH NAME
-fsck.erofs \- tool to check the EROFS filesystem's integrity
+fsck.erofs \- tool to check an EROFS filesystem's integrity
 .SH SYNOPSIS
 \fBfsck.erofs\fR [\fIOPTIONS\fR] \fIIMAGE\fR
 .SH DESCRIPTION
@@ -22,15 +22,18 @@ Print total compression ratio of all files including compressed and
 non-compressed files.
 .TP
 .BI "\-\-device=" path
-Specify an extra device to be used together.
-You may give multiple `--device' options in the correct order.
+Specify an extra blob device to be used together.
+You may give multiple
+.B --device
+options in the correct order.
 .TP
 .B \-\-extract
-Check if all files are well encoded. This will induce more I/Os to read
-compressed file data, so it might take too much time depending on the image.
+Check if all files are well encoded. This read all compressed files,
+and hence create more I/O load,
+so it might take too much time depending on the image.
 .TP
 .B \-\-help
-Display this help and exit.
+Display help string and exit.
 .SH AUTHOR
 This version of \fBfsck.erofs\fR is written by
 Daeho Jeong <daehojeong@google.com>.
-- 
2.30.2

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH v2 4/5] erofs-utils: man: fsck.erofs: wording/formatting touchups
  2023-04-09 13:41     ` [PATCH v2 " Ahelenia Ziemiańska
@ 2023-04-09 13:53       ` Gao Xiang
  0 siblings, 0 replies; 12+ messages in thread
From: Gao Xiang @ 2023-04-09 13:53 UTC (permalink / raw
  To: Ahelenia Ziemiańska; +Cc: linux-erofs mailing list



On 2023/4/9 21:41, Ahelenia Ziemiańska wrote:
> Some things that gave me pause or were weirdly formatted.
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
> ---
> Yep :)

Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> 
>   man/fsck.erofs.1 | 15 +++++++++------
>   1 file changed, 9 insertions(+), 6 deletions(-)
> 
> diff --git a/man/fsck.erofs.1 b/man/fsck.erofs.1
> index f3e9c3b..364219a 100644
> --- a/man/fsck.erofs.1
> +++ b/man/fsck.erofs.1
> @@ -2,7 +2,7 @@
>   .\"
>   .TH FSCK.EROFS 1
>   .SH NAME
> -fsck.erofs \- tool to check the EROFS filesystem's integrity
> +fsck.erofs \- tool to check an EROFS filesystem's integrity
>   .SH SYNOPSIS
>   \fBfsck.erofs\fR [\fIOPTIONS\fR] \fIIMAGE\fR
>   .SH DESCRIPTION
> @@ -22,15 +22,18 @@ Print total compression ratio of all files including compressed and
>   non-compressed files.
>   .TP
>   .BI "\-\-device=" path
> -Specify an extra device to be used together.
> -You may give multiple `--device' options in the correct order.
> +Specify an extra blob device to be used together.
> +You may give multiple
> +.B --device
> +options in the correct order.
>   .TP
>   .B \-\-extract
> -Check if all files are well encoded. This will induce more I/Os to read
> -compressed file data, so it might take too much time depending on the image.
> +Check if all files are well encoded. This read all compressed files,
> +and hence create more I/O load,
> +so it might take too much time depending on the image.
>   .TP
>   .B \-\-help
> -Display this help and exit.
> +Display help string and exit.
>   .SH AUTHOR
>   This version of \fBfsck.erofs\fR is written by
>   Daeho Jeong <daehojeong@google.com>.

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

end of thread, other threads:[~2023-04-09 13:53 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-09 11:56 [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Ahelenia Ziemiańska
2023-04-09 11:56 ` [PATCH 2/5] erofs-utils: mkfs: drop dead code in -z parsing Ahelenia Ziemiańska
2023-04-09 12:26   ` Gao Xiang
2023-04-09 11:56 ` [PATCH 3/5] erofs-utils: man: mkfs.erofs: wording/formatting touchups Ahelenia Ziemiańska
2023-04-09 12:46   ` Gao Xiang
2023-04-09 11:56 ` [PATCH 4/5] erofs-utils: man: fsck.erofs: " Ahelenia Ziemiańska
2023-04-09 12:48   ` Gao Xiang
2023-04-09 13:41     ` [PATCH v2 " Ahelenia Ziemiańska
2023-04-09 13:53       ` Gao Xiang
2023-04-09 11:56 ` [PATCH 5/5] erofs-utils: man: dump.erofs: " Ahelenia Ziemiańska
2023-04-09 12:51   ` Gao Xiang
2023-04-09 12:26 ` [PATCH 1/5] erofs-utils: lib: rb_tree: fix broken rb_iter_init() prototype Gao Xiang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).