mm: support async buffered reads in generic_file_buffered_read()
authorJens Axboe <axboe@kernel.dk>
Fri, 22 May 2020 15:18:38 +0000 (09:18 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 26 May 2020 19:32:03 +0000 (13:32 -0600)
commit255c6d9584c2003f280e9aecce717858d4b2adad
tree556f1a198d8a120afddd17df0bd4d7a13c6155c8
parenta9d83b40e35fc46692f22eaa9e9f60c73c5d8b11
mm: support async buffered reads in generic_file_buffered_read()

Use the async page locking infrastructure, if IOCB_WAITQ is set in the
passed in iocb. The caller must expect an -EIOCBQUEUED return value,
which means that IO is started but not done yet. This is similar to how
O_DIRECT signals the same operation. Once the callback is received by
the caller for IO completion, the caller must retry the operation.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
mm/filemap.c