All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xfs_io: Document '-q' option for pread/pwrite command
@ 2020-07-14  5:53 Xiao Yang
  2020-07-14 15:01 ` Darrick J. Wong
  0 siblings, 1 reply; 4+ messages in thread
From: Xiao Yang @ 2020-07-14  5:53 UTC (permalink / raw)
  To: linux-xfs; +Cc: Xiao Yang

Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
---
 io/pread.c        |  3 ++-
 io/pwrite.c       |  3 ++-
 man/man8/xfs_io.8 | 10 ++++++++--
 3 files changed, 12 insertions(+), 4 deletions(-)

diff --git a/io/pread.c b/io/pread.c
index 971dbbc9..458a78b8 100644
--- a/io/pread.c
+++ b/io/pread.c
@@ -30,6 +30,7 @@ pread_help(void)
 " The reads are performed in sequential blocks starting at offset, with the\n"
 " blocksize tunable using the -b option (default blocksize is 4096 bytes),\n"
 " unless a different pattern is requested.\n"
+" -q   -- quiet mode, do not write anything to standard output.\n"
 " -B   -- read backwards through the range from offset (backwards N bytes)\n"
 " -F   -- read forwards through the range of bytes from offset (default)\n"
 " -v   -- be verbose, dump out buffers (used when reading forwards)\n"
@@ -506,7 +507,7 @@ pread_init(void)
 	pread_cmd.argmin = 2;
 	pread_cmd.argmax = -1;
 	pread_cmd.flags = CMD_NOMAP_OK | CMD_FOREIGN_OK;
-	pread_cmd.args = _("[-b bs] [-v] [-i N] [-FBR [-Z N]] off len");
+	pread_cmd.args = _("[-b bs] [-qv] [-i N] [-FBR [-Z N]] off len");
 	pread_cmd.oneline = _("reads a number of bytes at a specified offset");
 	pread_cmd.help = pread_help;
 
diff --git a/io/pwrite.c b/io/pwrite.c
index 995f6ece..467bfa9f 100644
--- a/io/pwrite.c
+++ b/io/pwrite.c
@@ -27,6 +27,7 @@ pwrite_help(void)
 " The writes are performed in sequential blocks starting at offset, with the\n"
 " blocksize tunable using the -b option (default blocksize is 4096 bytes),\n"
 " unless a different write pattern is requested.\n"
+" -q   -- quiet mode, do not write anything to standard output.\n"
 " -S   -- use an alternate seed number for filling the write buffer\n"
 " -i   -- input file, source of data to write (used when writing forward)\n"
 " -d   -- open the input file for direct IO\n"
@@ -483,7 +484,7 @@ pwrite_init(void)
 	pwrite_cmd.argmax = -1;
 	pwrite_cmd.flags = CMD_NOMAP_OK | CMD_FOREIGN_OK;
 	pwrite_cmd.args =
-_("[-i infile [-dDwNOW] [-s skip]] [-b bs] [-S seed] [-FBR [-Z N]] [-V N] off len");
+_("[-i infile [-qdDwNOW] [-s skip]] [-b bs] [-S seed] [-FBR [-Z N]] [-V N] off len");
 	pwrite_cmd.oneline =
 		_("writes a number of bytes at a specified offset");
 	pwrite_cmd.help = pwrite_help;
diff --git a/man/man8/xfs_io.8 b/man/man8/xfs_io.8
index b9dcc312..d3eb3e7e 100644
--- a/man/man8/xfs_io.8
+++ b/man/man8/xfs_io.8
@@ -200,7 +200,7 @@ option will set the file permissions to read-write (0644). This allows xfs_io to
 set up mismatches between the file permissions and the open file descriptor
 read/write mode to exercise permission checks inside various syscalls.
 .TP
-.BI "pread [ \-b " bsize " ] [ \-v ] [ \-FBR [ \-Z " seed " ] ] [ \-V " vectors " ] " "offset length"
+.BI "pread [ \-b " bsize " ] [ \-qv ] [ \-FBR [ \-Z " seed " ] ] [ \-V " vectors " ] " "offset length"
 Reads a range of bytes in a specified blocksize from the given
 .IR offset .
 .RS 1.0i
@@ -211,6 +211,9 @@ can be used to set the blocksize into which the
 .BR read (2)
 requests will be split. The default blocksize is 4096 bytes.
 .TP
+.B \-q
+quiet mode, do not write anything to standard output.
+.TP
 .B \-v
 dump the contents of the buffer after reading,
 by default only the count of bytes actually read is dumped.
@@ -241,7 +244,7 @@ See the
 .B pread
 command.
 .TP
-.BI "pwrite [ \-i " file " ] [ \-dDwNOW ] [ \-s " skip " ] [ \-b " size " ] [ \-S " seed " ] [ \-FBR [ \-Z " zeed " ] ] [ \-V " vectors " ] " "offset length"
+.BI "pwrite [ \-i " file " ] [ \-qdDwNOW ] [ \-s " skip " ] [ \-b " size " ] [ \-S " seed " ] [ \-FBR [ \-Z " zeed " ] ] [ \-V " vectors " ] " "offset length"
 Writes a range of bytes in a specified blocksize from the given
 .IR offset .
 The bytes written can be either a set pattern or read in from another
@@ -254,6 +257,9 @@ allows an input
 .I file
 to be specified as the source of the data to be written.
 .TP
+.B \-q
+quiet mode, do not write anything to standard output.
+.TP
 .B \-d
 causes direct I/O, rather than the usual buffered
 I/O, to be used when reading the input file.
-- 
2.21.0




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

end of thread, other threads:[~2020-07-22  3:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-14  5:53 [PATCH] xfs_io: Document '-q' option for pread/pwrite command Xiao Yang
2020-07-14 15:01 ` Darrick J. Wong
2020-07-14 18:08   ` Eric Sandeen
2020-07-22  3:46     ` Xiao Yang

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.