From: Keith Busch Date: Wed, 2 Mar 2016 15:14:13 +0000 (-0700) Subject: Add write zeroes command X-Git-Tag: v0.5~21 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=a911dd8f2b01dd3696ca661ed0b68b500f6c9acf;p=users%2Fsagi%2Fnvme-cli.git Add write zeroes command As part of this, moving the namespace id error handling to a common function, as this has become a common repitition. Signed-off-by: Keith Busch --- diff --git a/Documentation/cmds-main.txt b/Documentation/cmds-main.txt index 88c7c6a5..d21e4736 100644 --- a/Documentation/cmds-main.txt +++ b/Documentation/cmds-main.txt @@ -76,6 +76,9 @@ linknvme:nvme-read[1]:: linknvme:nvme-write[1]:: Issue IO Write Command +linknvme:nvme-write-zeroes[1]:: + Issue IO Write Zeroes Command + linknvme:nvme-resv-acquire[1]:: Acquire Namespace Reservation diff --git a/Documentation/nvme-write-zeroes.1 b/Documentation/nvme-write-zeroes.1 new file mode 100644 index 00000000..1f526cb1 --- /dev/null +++ b/Documentation/nvme-write-zeroes.1 @@ -0,0 +1,58 @@ +'\" t +.\" Title: nvme-zeroes +.\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 03/02/2016 +.\" Manual: NVMe Manual +.\" Source: NVMe +.\" Language: English +.\" +.TH "NVME\-ZEROES" "1" "03/02/2016" "NVMe" "NVMe Manual" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +nvme-write-zeroes \- Send an NVMe write zeroes command, return results +.SH "SYNOPSIS" +.sp +.nf +\fInvme\-write\-zeroes\fR [\-\-start\-block= | \-s ] + [\-\-block\-count= | \-c ] + [\-\-ref\-tag= | \-r ] + [\-\-prinfo= | \-p ] + [\-\-app\-tag\-mask= | \-m ] + [\-\-app\-tag= | \-a ] + [\-\-limited\-retry | \-l] + [\-\-force\-unit\-access | \-f] +.fi +.SH "DESCRIPTION" +.sp +The Write Zeroes command is used to set a range of logical blocks to 0\&. +.SH "OPTIONS" +.PP +\-\-start\-block=, \-s +.RS 4 +Start block\&. +.RE +.SH "EXAMPLES" +.sp +No examples yet\&. +.SH "NVME" +.sp +Part of the nvme\-user suite diff --git a/Documentation/nvme-write-zeroes.html b/Documentation/nvme-write-zeroes.html new file mode 100644 index 00000000..0603e4f2 --- /dev/null +++ b/Documentation/nvme-write-zeroes.html @@ -0,0 +1,811 @@ + + + + + +nvme-zeroes(1) + + + + + +
+
+

SYNOPSIS

+
+
+
nvme-write-zeroes <device> [--start-block=<slba> | -s <slba>]
+                        [--block-count=<nlb> | -c <nlb>]
+                        [--ref-tag=<reftag> | -r <reftag>]
+                        [--prinfo=<prinfo> | -p <prinfo>]
+                        [--app-tag-mask=<appmask> | -m <appmask>]
+                        [--app-tag=<apptag> | -a <apptag>]
+                        [--limited-retry | -l]
+                        [--force-unit-access | -f]
+
+
+
+
+
+

DESCRIPTION

+
+

The Write Zeroes command is used to set a range of logical blocks to 0.

+
+
+
+

OPTIONS

+
+
+
+--start-block=<slba> +
+
+-s <slba> +
+
+

+ Start block. +

+
+
+
+
+
+

EXAMPLES

+
+

No examples yet.

+
+
+
+

NVME

+
+

Part of the nvme-user suite

+
+
+
+

+ + + diff --git a/Documentation/nvme-write-zeroes.txt b/Documentation/nvme-write-zeroes.txt new file mode 100644 index 00000000..6225a289 --- /dev/null +++ b/Documentation/nvme-write-zeroes.txt @@ -0,0 +1,36 @@ +nvme-zeroes(1) +============== + +NAME +---- +nvme-write-zeroes - Send an NVMe write zeroes command, return results + +SYNOPSIS +-------- +[verse] +'nvme-write-zeroes' [--start-block= | -s ] + [--block-count= | -c ] + [--ref-tag= | -r ] + [--prinfo= | -p ] + [--app-tag-mask= | -m ] + [--app-tag= | -a ] + [--limited-retry | -l] + [--force-unit-access | -f] + +DESCRIPTION +----------- +The Write Zeroes command is used to set a range of logical blocks to 0. + +OPTIONS +------- +--start-block=:: +-s :: + Start block. + +EXAMPLES +-------- +No examples yet. + +NVME +---- +Part of the nvme-user suite diff --git a/Documentation/nvme-write.1 b/Documentation/nvme-write.1 index 0cf5730e..06988c5e 100644 --- a/Documentation/nvme-write.1 +++ b/Documentation/nvme-write.1 @@ -1,13 +1,13 @@ '\" t -.\" Title: nvme-compare +.\" Title: nvme-write .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.76.1 -.\" Date: 10/21/2015 +.\" Date: 03/02/2016 .\" Manual: NVMe Manual .\" Source: NVMe .\" Language: English .\" -.TH "NVME\-COMPARE" "1" "10/21/2015" "NVMe" "NVMe Manual" +.TH "NVME\-WRITE" "1" "03/02/2016" "NVMe" "NVMe Manual" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- diff --git a/Documentation/nvme-write.html b/Documentation/nvme-write.html index 82a2247a..52cb07fb 100644 --- a/Documentation/nvme-write.html +++ b/Documentation/nvme-write.html @@ -4,7 +4,7 @@ -nvme-compare(1) +nvme-write(1)