-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
io_uring: Add 'write_mode' option for optional cmds #1766
io_uring: Add 'write_mode' option for optional cmds #1766
Conversation
Can we have a new DDIR only just for If possible, I would like to introduce a
|
There is a similar option for the sg ioengine. Can you adopt that option for io_uring_cmd? |
2e9ae80
to
2f4c005
Compare
That makes sense. I've updated parameter name to |
engines/nvme.c
Outdated
@@ -336,7 +336,6 @@ void fio_nvme_uring_cmd_trim_prep(struct nvme_uring_cmd *cmd, struct io_u *io_u, | |||
uint8_t *buf_point; | |||
int i; | |||
|
|||
cmd->opcode = nvme_cmd_dsm; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should not be removed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, this is really bad. I will update it, thanks for catching this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.
The nomenclature here is not ideal because none of verify, write zeroes, and write uncorrectable will actually make use of the data buffer that fio prepares for write operations. By default fio will generate random data for the write buffer one time only. So this is probably not a big deal. |
Add a new option 'write_mode' to support additional optional Write command family such as Write Uncorrectable and Write Zeroes in NVMe. Since we have io_uring_cmd ioengine where we can define the actual opcode of the command, this option will be used to test NVMe device with various combination of Write command types. 'write_mode' option can be given either 'write', 'uncor', 'zeroes' or 'verify'. 'write' is for normal Write command which is by default, 'uncor' is for Write Uncorrectable, 'zeroes' for Write Zeroes and 'verify' for Verify command This should be used with DDIR_WRITE ddir. This patch updates command's opcode in fio_ioring_init() to avoid branches in the I/O hottest path giving opcode value to the fio_nvme_uring_cmd_prep() as an argument. Signed-off-by: Minwoo Im <[email protected]>
Indeed, that's why I've been curious about whether the name of |
2f4c005
to
87a4903
Compare
Add a new option 'write_mode' to support additional optional Write
command family such as Write Uncorrectable and Write Zeroes in NVMe.
Since we have io_uring_cmd ioengine where we can define the actual
opcode of the command, this option will be used to test NVMe device with
various combination of Write command types.
'write_mode' option can be given either 'write', 'uncor', 'zeroes' or
'verify'. 'write' is for normal Write command which is by default,
'uncor' is for Write Uncorrectable, 'zeroes' for Write Zeroes and 'verify'
for Verify command This should be used with DDIR_WRITE ddir.
This patch updates command's opcode in fio_ioring_init() to avoid
branches in the I/O hottest path giving opcode value to the
fio_nvme_uring_cmd_prep() as an argument.