diff options
author | Ankit Kumar <ankit.kumar@samsung.com> | 2023-08-14 20:27:38 +0530 |
---|---|---|
committer | Vincent Fu <vincent.fu@samsung.com> | 2023-08-14 10:27:33 -0400 |
commit | a904d1829b058506bdb9cf6c223f45260a30e723 (patch) | |
tree | 0e4b0d728ec70b0ec8506fabe76240e15b6c3d26 | |
parent | 62f35562722f0c903567096d0f10a836d1ae2f60 (diff) | |
download | fio-a904d1829b058506bdb9cf6c223f45260a30e723.tar.gz |
engines:io_uring: add missing error during open file
This change ensures the error is propogated to upper layers to make fio
exit with a non-zero return code.
Add filename for errors when block size is not a multiple of logical
blocks.
Signed-off-by: Ankit Kumar <ankit.kumar@samsung.com>
Link: https://lore.kernel.org/r/20230814145747.114725-2-ankit.kumar@samsung.com
Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
-rw-r--r-- | engines/io_uring.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/engines/io_uring.c b/engines/io_uring.c index b361e6a5b..090654634 100644 --- a/engines/io_uring.c +++ b/engines/io_uring.c @@ -1115,10 +1115,12 @@ static int fio_ioring_cmd_open_file(struct thread_data *td, struct fio_file *f) if (td->o.min_bs[ddir] % lba_size || td->o.max_bs[ddir] % lba_size) { if (data->lba_ext) - log_err("block size must be a multiple of " - "(LBA data size + Metadata size)\n"); + log_err("%s: block size must be a multiple of (LBA data size + Metadata size)\n", + f->file_name); else - log_err("block size must be a multiple of LBA data size\n"); + log_err("%s: block size must be a multiple of LBA data size\n", + f->file_name); + td_verror(td, EINVAL, "fio_ioring_cmd_open_file"); return 1; } } |