aio: utilize io_event->res2 for CQ ring
authorJens Axboe <axboe@kernel.dk>
Fri, 14 Dec 2018 04:00:42 +0000 (21:00 -0700)
committerJens Axboe <axboe@kernel.dk>
Thu, 3 Jan 2019 15:14:03 +0000 (08:14 -0700)
commit9d84a51f739d6f56487a62097b5bf1968775aabd
tree122e087105909edc92216a60c987663fbc175c42
parent94f72c195b62fec14812c5bbc43f2b954ad369de
aio: utilize io_event->res2 for CQ ring

We don't use this at all, grab it to provide hints about the data.
The first hint we add is IORING_RES2_CACHEHIT, whether a read was
served out of the page cache, or if it hit media. This is useful
for buffered aio, O_DIRECT reads would never have this set (for
obvious reasons).

Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/aio.c
include/uapi/linux/aio_abi.h