]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit - mm/filemap.c
mm/filemap: don't revert iter on -EIOCBQUEUED
authorPavel Begunkov <asml.silence@gmail.com>
Wed, 24 Feb 2021 20:01:45 +0000 (12:01 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 24 Feb 2021 21:38:27 +0000 (13:38 -0800)
commitab2125df921d991a3c8a4fdcfe617ef6cad6b484
tree162a4f8e7c945d4ec69f8c5272ef1baee99a43d2
parent1f7ef657740344541645349a8bece90cbff898f5
mm/filemap: don't revert iter on -EIOCBQUEUED

Currently, if I/O is enqueued for async execution direct paths of
generic_file_{read,write}_iter() will always revert the iter.  There are
no users expecting that, and that is also costly.  Leave iterators as is
on -EIOCBQUEUED.

Link: https://lkml.kernel.org/r/f5247b60e7abbd2ff850cd108491f53a2e0c501a.1610207781.git.asml.silence@gmail.com
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/filemap.c