projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
06ec57e
)
engines/libzbc: for read workloads always open devices with O_RDONLY flag
author
Vincent Fu
<vincent.fu@samsung.com>
Tue, 7 Feb 2023 14:37:29 +0000
(09:37 -0500)
committer
Vincent Fu
<vincent.fu@samsung.com>
Tue, 7 Feb 2023 14:37:29 +0000
(09:37 -0500)
libzbc uses the SG_IO ioctl to send commands to devices (instead of
using write() to send commands to character devices). So we don't need
to open character devices with the O_RDWR flag.
Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
engines/libzbc.c
patch
|
blob
|
blame
|
history
diff --git
a/engines/libzbc.c
b/engines/libzbc.c
index 2b63ef1acaa0b4624b80206893f3c6f6c74fb618..cb3e9ca5458e3488a113ad3b5adfaac20da5d457 100644
(file)
--- a/
engines/libzbc.c
+++ b/
engines/libzbc.c
@@
-68,9
+68,6
@@
static int libzbc_open_dev(struct thread_data *td, struct fio_file *f,
if (!read_only)
flags |= O_RDWR;
} else if (td_read(td)) {
- if (f->filetype == FIO_TYPE_CHAR && !read_only)
- flags |= O_RDWR;
- else
flags |= O_RDONLY;
}