projects
/
platform
/
upstream
/
f2fs-tools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2579fe8
)
f2fs_io: add OSYNC option
author
Jaegeuk Kim
<jaegeuk@kernel.org>
Fri, 14 Aug 2020 01:11:22 +0000
(18:11 -0700)
committer
Jaegeuk Kim
<jaegeuk@kernel.org>
Thu, 20 Aug 2020 16:08:07 +0000
(09:08 -0700)
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
tools/f2fs_io/f2fs_io.c
patch
|
blob
|
history
diff --git
a/tools/f2fs_io/f2fs_io.c
b/tools/f2fs_io/f2fs_io.c
index
abb655a
..
70a077a
100644
(file)
--- a/
tools/f2fs_io/f2fs_io.c
+++ b/
tools/f2fs_io/f2fs_io.c
@@
-424,6
+424,7
@@
static void do_fallocate(int argc, char **argv, const struct cmd_desc *cmd)
"IO can be\n" \
" buffered : buffered IO\n" \
" dio : direct IO\n" \
+" osync : O_SYNC\n" \
static void do_write(int argc, char **argv, const struct cmd_desc *cmd)
{
@@
-460,6
+461,8
@@
static void do_write(int argc, char **argv, const struct cmd_desc *cmd)
if (!strcmp(argv[5], "dio"))
flags |= O_DIRECT;
+ else if (!strcmp(argv[5], "osync"))
+ flags |= O_SYNC;
else if (strcmp(argv[5], "buffered"))
die("Wrong IO type");