Skip to contentSkip to conversation

Recent changes (master)

PATCH Jens Axboe 1 participant 1 message May 19, 2018

lore
Share & tools
lore

Jens Axboe

author
#0 lore raw

The following changes since commit 5eac3b00238b450ac0679121a76f1e566ca8f468:

make fio scripts python3-ready (2018-05-16 11:17:55 -0600)

are available in the git repository at:

git://git.kernel.dk/fio.git master

for you to fetch changes up to 12223a35ac7d975d7c2950c664d8caf7f9c065bf:

Merge branch 'sg-verify2' of https://github.com/vincentkfu/fio (2018-05-18 13:34:36 -0600)

----------------------------------------------------------------
Jens Axboe (1):
Merge branch 'sg-verify2' of https://github.com/vincentkfu/fio

Vincent Fu (2):
engines/sg: add support for WRITE AND VERIFY, WRITE SAME
docs: add documentation for sg ioengine WRITE SAME, WRITE AND VERIFY command support

 HOWTO        | 20 ++++++++++++++++++++
 engines/sg.c | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++--------
 fio.1        | 27 ++++++++++++++++++++++++++
 3 files changed, 101 insertions(+), 8 deletions(-)

---

Diff of recent changes:

HOWTO +20 -0
index d200700..7680f9c 100644
@@ -2079,6 +2079,26 @@ with the caveat that when used on the command line, they must come after the
 	With writefua option set to 1, write operations include
 	the force unit access (fua) flag. Default is 0.
 
+.. option:: sg_write_mode=str : [sg]
+	Specify the type of write commands to issue. This option can take three values:
+
+	**write**
+		This is the default where write opcodes are issued as usual.
+	**verify**
+		Issue WRITE AND VERIFY commands. The BYTCHK bit is set to 0. This
+		directs the device to carry out a medium verification with no data
+		comparison. The writefua option is ignored with this selection.
+	**same**
+		Issue WRITE SAME commands. This transfers a single block to the device
+		and writes this same block of data to a contiguous sequence of LBAs
+		beginning at the specified offset. fio's block size parameter specifies
+		the amount of data written with each command. However, the amount of data
+		actually transferred to the device is equal to the device's block
+		(sector) size. For a device with 512 byte sectors, blocksize=8k will
+		write 16 sectors with each command. fio will still generate 8k of data
+		for each command but only the first 512 bytes will be used and
+		transferred to the device. The writefua option is ignored with this
+		selection.
 
 I/O depth
 ~~~~~~~~~
engines/sg.c +54 -8

85 lines not on this page · raw message

fio.1 +27 -0
index 7d5d8be..ce3585a 100644
@@ -1828,6 +1828,33 @@ unit access (fua) flag. Default: 0.
 .BI (sg)writefua \fR=\fPbool
 With writefua option set to 1, write operations include the force
 unit access (fua) flag. Default: 0.
+.TP
+.BI (sg)sg_write_mode \fR=\fPstr
+Specify the type of write commands to issue. This option can take three
+values:
+.RS
+.RS
+.TP
+.B write (default)
+Write opcodes are issued as usual
+.TP
+.B verify
+Issue WRITE AND VERIFY commands. The BYTCHK bit is set to 0. This
+directs the device to carry out a medium verification with no data
+comparison. The writefua option is ignored with this selection.
+.TP
+.B same
+Issue WRITE SAME commands. This transfers a single block to the device
+and writes this same block of data to a contiguous sequence of LBAs
+beginning at the specified offset. fio's block size parameter
+specifies the amount of data written with each command. However, the
+amount of data actually transferred to the device is equal to the
+device's block (sector) size. For a device with 512 byte sectors,
+blocksize=8k will write 16 sectors with each command. fio will still
+generate 8k of data for each command butonly the first 512 bytes will
+be used and transferred to the device. The writefua option is ignored
+with this selection.
+
 .SS "I/O depth"
 .TP
 .BI iodepth \fR=\fPint