Skip to contentSkip to conversation

Add some option descriptions to help and man page

PATCH In review Masayoshi Mizuma 2 participants 6 messages Dec 18, 2019 – Jan 10, 2020

lore
Share & tools
lore
#0 lore raw

cover Add some option descriptions to help and man page

From: Masayoshi Mizuma <[email protected]>

Add some options to the help message and man page so that users can set them.

Masayoshi Mizuma (3):
virtiofsd: add some options to the help message
virtiofsd: add some options to the man page
virtiofsd: remove --writeback option from the man page

 tools/virtiofsd/helper.c       | 26 +++++++++++++++++++++++---
 tools/virtiofsd/virtiofsd.texi | 24 ++++++++++++++++++++++--
 2 files changed, 45 insertions(+), 5 deletions(-)
Signature · 1 line
2.18.1
#1 lore raw

PATCH 1/3 virtiofsd: add some options to the help message

From: Masayoshi Mizuma <[email protected]>

Add following options to the help message:
- cache
- flock|no_flock
- norace
- posix_lock|no_posix_lock
- readdirplus|no_readdirplus
- timeout
- writeback|no_writeback
- xattr|no_xattr

---
 tools/virtiofsd/helper.c | 26 +++++++++++++++++++++++---
 1 file changed, 23 insertions(+), 3 deletions(-)
tools/virtiofsd/helper.c +23 -3
index bcb8c05063..339d806e7c 100644
@@ -147,15 +147,35 @@ void fuse_cmdline_help(void)
            "    -f                         foreground operation\n"
            "    --daemonize                run in background\n"
            "    -s                         disable multi-threaded operation\n"
+           "    -o cache=<mode>            cache mode. could be one of \"auto, "
+           "always, none\"\n"
+           "                               default: auto\n"
            "    -o clone_fd                use separate fuse device fd for "
            "each thread\n"
            "                               (may improve performance)\n"
+           "    -o flock|no_flock          enable/disable flock\n"
+           "                               default: no_flock\n"
+           "    -o log_level=<level>       log level, default to \"info\"\n"
+           "                               level could be one of \"debug, "
+           "info, warn, err\"\n"
            "    -o max_idle_threads        the maximum number of idle worker "
            "threads\n"
            "                               allowed (default: 10)\n"
-           "    -o log_level=<level>       log level, default to \"info\"\n"
-           "                               level could be one of \"debug, "
-           "info, warn, err\"\n");
+           "    -o norace                  disable racy fallback\n"
+           "                               default: false\n"
+           "    -o posix_lock|no_posix_lock\n"
+           "                               enable/disable remote posix lock\n"
+           "                               default: posix_lock\n"
+           "    -o readdirplus|no_readdirplus\n"
+           "                               enable/disable readirplus\n"
+           "                               default: readdirplus\n"
+           "    -o timeout=<number>        I/O timeout (second)\n"
+           "                               default: depends on cache= option.\n"
+           "    -o writeback|no_writeback  enable/disable writeback cache\n"
+           "                               default: no_writeback\n"
+           "    -o xattr|no_xattr          enable/disable xattr\n"
+           "                               default: no_xattr\n"
+           );
 }
 
 static int fuse_helper_opt_proc(void *data, const char *arg, int key,
Signature · 1 line
2.18.1
Reviewed-by on v1 1/3
#2 lore raw

Re: [Virtio-fs] [PATCH 1/3] virtiofsd: add some options to the help message

Quoted 12 lines · * Masayoshi Mizuma ([email protected]) wrote:

From: Masayoshi Mizuma <[email protected]>

Add following options to the help message:
- cache
- flock|no_flock
- norace
- posix_lock|no_posix_lock
- readdirplus|no_readdirplus
- timeout
- writeback|no_writeback
- xattr|no_xattr

Quoted 1 line

Thanks, I've split this up, so where the option was added by one of our own patches, that patch now includes the update to this function. Which leaves just flock, timeout, writeback, and xattr in this patch.

Quoted 55 lines
---
 tools/virtiofsd/helper.c | 26 +++++++++++++++++++++++---
 1 file changed, 23 insertions(+), 3 deletions(-)
tools/virtiofsd/helper.c +23 -3
index bcb8c05063..339d806e7c 100644
@@ -147,15 +147,35 @@ void fuse_cmdline_help(void)
            "    -f                         foreground operation\n"
            "    --daemonize                run in background\n"
            "    -s                         disable multi-threaded operation\n"
+           "    -o cache=<mode>            cache mode. could be one of \"auto, "
+           "always, none\"\n"
+           "                               default: auto\n"
            "    -o clone_fd                use separate fuse device fd for "
            "each thread\n"
            "                               (may improve performance)\n"
+           "    -o flock|no_flock          enable/disable flock\n"
+           "                               default: no_flock\n"
+           "    -o log_level=<level>       log level, default to \"info\"\n"
+           "                               level could be one of \"debug, "
+           "info, warn, err\"\n"
            "    -o max_idle_threads        the maximum number of idle worker "
            "threads\n"
            "                               allowed (default: 10)\n"
-           "    -o log_level=<level>       log level, default to \"info\"\n"
-           "                               level could be one of \"debug, "
-           "info, warn, err\"\n");
+           "    -o norace                  disable racy fallback\n"
+           "                               default: false\n"
+           "    -o posix_lock|no_posix_lock\n"
+           "                               enable/disable remote posix lock\n"
+           "                               default: posix_lock\n"
+           "    -o readdirplus|no_readdirplus\n"
+           "                               enable/disable readirplus\n"
+           "                               default: readdirplus\n"
+           "    -o timeout=<number>        I/O timeout (second)\n"
+           "                               default: depends on cache= option.\n"
+           "    -o writeback|no_writeback  enable/disable writeback cache\n"
+           "                               default: no_writeback\n"
+           "    -o xattr|no_xattr          enable/disable xattr\n"
+           "                               default: no_xattr\n"
+           );
 }
 
 static int fuse_helper_opt_proc(void *data, const char *arg, int key,
Signature · 7 lines
2.18.1


_______________________________________________
Virtio-fs mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/virtio-fs

--
Dr. David Alan Gilbert / [email protected] / Manchester, UK

#3 lore raw

PATCH 2/3 virtiofsd: add some options to the man page

In reply to Masayoshi Mizuma

From: Masayoshi Mizuma <[email protected]>

Add following options to the man page:
- flock|no_flock
- norace
- posix_lock|no_posix_lock
- readdirplus|no_readdirplus
- timeout
- writeback|no_writeback
- xattr|no_xattr

---
 tools/virtiofsd/virtiofsd.texi | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
tools/virtiofsd/virtiofsd.texi +22 -0
index eec7fbf4e6..76eb219676 100644
@@ -34,12 +34,34 @@ Print version.
 Enable debug output.
 @item --syslog
 Print log messages to syslog instead of stderr.
+@item -o flock|no_flock
+enable/disable flock.
+The default is @var{no_flock}.
 @item -o log_level=@var{level}
 Print only log messages matching @var{level} or more severe.  @var{level} is
 one of @code{err}, @code{warn}, @code{info}, or @code{debug}.  The default is
 @var{info}.
+@item -o norace
+Disable racy fallback.
+The default is false.
+@item -o posix_lock|no_posix_lock
+Enable/Disable remote posix lock.
+The default is @var{posix_lock}.
+@item -o readdirplus|no_readdirplus
+Enable/Disable readdirplus.
+The default is @var{readdirplus}
 @item -o source=@var{path}
 Share host directory tree located at @var{path}.  This option is required.
+@item -o timeout=<number>
+I/O timeout (second).
+The default depends on cache= option.
+@item -o writeback|no_writeback
+Enable/Disable writeback cache. The cache alows the FUSE client
+to buffer and merge write requests.
+The default is @var{no_writeback}.
+@item -o xattr|no_xattr
+Enable/Disable Extended attributes (xattr) of the files and directories.
+The default is @var{no_xattr}.
 @item --socket-path=@var{path}, -o vhost_user_socket=@var{path}
 Listen on vhost-user UNIX domain socket at @var{path}.
 @item --fd=@var{fdnum}
Signature · 1 line
2.18.1
Reviewed-by on v1 2/3
#4 lore raw

Re: [Virtio-fs] [PATCH 2/3] virtiofsd: add some options to the man page

Quoted 11 lines · * Masayoshi Mizuma ([email protected]) wrote:

From: Masayoshi Mizuma <[email protected]>

Add following options to the man page:
- flock|no_flock
- norace
- posix_lock|no_posix_lock
- readdirplus|no_readdirplus
- timeout
- writeback|no_writeback
- xattr|no_xattr

Quoted 1 line

Thanks, I've squashed this one and the next one down into the
'add man page' commit.

Dave

Quoted 51 lines
---
 tools/virtiofsd/virtiofsd.texi | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
tools/virtiofsd/virtiofsd.texi +22 -0
index eec7fbf4e6..76eb219676 100644
@@ -34,12 +34,34 @@ Print version.
 Enable debug output.
 @item --syslog
 Print log messages to syslog instead of stderr.
+@item -o flock|no_flock
+enable/disable flock.
+The default is @var{no_flock}.
 @item -o log_level=@var{level}
 Print only log messages matching @var{level} or more severe.  @var{level} is
 one of @code{err}, @code{warn}, @code{info}, or @code{debug}.  The default is
 @var{info}.
+@item -o norace
+Disable racy fallback.
+The default is false.
+@item -o posix_lock|no_posix_lock
+Enable/Disable remote posix lock.
+The default is @var{posix_lock}.
+@item -o readdirplus|no_readdirplus
+Enable/Disable readdirplus.
+The default is @var{readdirplus}
 @item -o source=@var{path}
 Share host directory tree located at @var{path}.  This option is required.
+@item -o timeout=<number>
+I/O timeout (second).
+The default depends on cache= option.
+@item -o writeback|no_writeback
+Enable/Disable writeback cache. The cache alows the FUSE client
+to buffer and merge write requests.
+The default is @var{no_writeback}.
+@item -o xattr|no_xattr
+Enable/Disable Extended attributes (xattr) of the files and directories.
+The default is @var{no_xattr}.
 @item --socket-path=@var{path}, -o vhost_user_socket=@var{path}
 Listen on vhost-user UNIX domain socket at @var{path}.
 @item --fd=@var{fdnum}
Signature · 7 lines
2.18.1


_______________________________________________
Virtio-fs mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/virtio-fs

--
Dr. David Alan Gilbert / [email protected] / Manchester, UK

#5 lore raw

PATCH 3/3 virtiofsd: remove --writeback option from the man page

In reply to Masayoshi Mizuma

From: Masayoshi Mizuma <[email protected]>

'--writeback' options doesn't work for virtiofsd.
'-o writebck' works instead.

---
 tools/virtiofsd/virtiofsd.texi | 2 --
 1 file changed, 2 deletions(-)
tools/virtiofsd/virtiofsd.texi +0 -2
index 76eb219676..45f377d41e 100644
@@ -73,8 +73,6 @@ Select the desired trade-off between coherency and performance.  @code{none}
 forbids the FUSE client from caching to achieve best coherency at the cost of
 performance.  @code{auto} acts similar to NFS with a 1 second metadata cache
 timeout.  @code{always} sets a long cache lifetime at the expense of coherency.
-@item --writeback
-Enable writeback cache, allowing the FUSE client to buffer and merge write requests.
 @end table
 @c man end
 
Signature · 1 line
2.18.1