diff options
author | Jens Axboe <axboe@kernel.dk> | 2021-08-31 04:37:41 +0300 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-08-31 20:45:30 +0300 |
commit | 7b3188e7ed54102a5dcc73d07727f41fb528f7c8 (patch) | |
tree | f758c94f0b7b3d6b02299d62f8e690fd99e12e88 /fs/io_uring.c | |
parent | 94ffb0a282872c2f4b14f757fa1aef2302aeaabb (diff) | |
download | linux-7b3188e7ed54102a5dcc73d07727f41fb528f7c8.tar.xz |
io_uring: IORING_OP_WRITE needs hash_reg_file set
During some testing, it became evident that using IORING_OP_WRITE doesn't
hash buffered writes like the other writes commands do. That's simply
an oversight, and can cause performance regressions when doing buffered
writes with this command.
Correct that and add the flag, so that buffered writes are correctly
hashed when using the non-iovec based write command.
Cc: stable@vger.kernel.org
Fixes: 3a6820f2bb8a ("io_uring: add non-vectored read/write commands")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'fs/io_uring.c')
-rw-r--r-- | fs/io_uring.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/io_uring.c b/fs/io_uring.c index 7cc458e0b636..473a977c7979 100644 --- a/fs/io_uring.c +++ b/fs/io_uring.c @@ -995,6 +995,7 @@ static const struct io_op_def io_op_defs[] = { }, [IORING_OP_WRITE] = { .needs_file = 1, + .hash_reg_file = 1, .unbound_nonreg_file = 1, .pollout = 1, .plug = 1, |