summaryrefslogtreecommitdiffstats
path: root/include/linux/iversion.h
diff options
context:
space:
mode:
authorChristoph Hellwig2018-11-30 09:23:48 +0100
committerJens Axboe2018-11-30 16:28:51 +0100
commit531724abc3bfb556c1dd68086cf9cb51f76464e3 (patch)
tree8bfb395ad202bb38e9ed47d574abab5d3eac92bb /include/linux/iversion.h
parentsbitmap: don't loop for find_next_zero_bit() for !round_robin (diff)
downloadkernel-qcow2-linux-531724abc3bfb556c1dd68086cf9cb51f76464e3.tar.gz
kernel-qcow2-linux-531724abc3bfb556c1dd68086cf9cb51f76464e3.tar.xz
kernel-qcow2-linux-531724abc3bfb556c1dd68086cf9cb51f76464e3.zip
block: avoid extra bio reference for async O_DIRECT
The bio referencing has a trick that doesn't do any actual atomic inc/dec on the reference count until we have to elevator to > 1. For the async IO O_DIRECT case, we can't use the simple DIO variants, so we use __blkdev_direct_IO(). It always grabs an extra reference to the bio after allocation, which means we then enter the slower path of actually having to do atomic_inc/dec on the count. We don't need to do that for the async case, unless we end up going multi-bio, in which case we're already doing huge amounts of IO. For the smaller IO case (< BIO_MAX_PAGES), we can do without the extra ref. Based on an earlier patch (and commit log) from Jens Axboe. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/iversion.h')
0 files changed, 0 insertions, 0 deletions