Pavel Begunkov fac7c6d529 block: cache bdev in struct file for raw bdev IO
bdev = &BDEV_I(file->f_mapping->host)->bdev

Getting struct block_device from a file requires 2 memory dereferences
as illustrated above, that takes a toll on performance, so cache it in
yet unused file->private_data. That gives a noticeable peak performance
improvement.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/8415f9fe12e544b9da89593dfbca8de2b52efe03.1634115360.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2021-10-18 06:17:36 -06:00
..
2021-10-18 06:17:01 -06:00
2021-08-18 07:21:12 -06:00
2021-10-18 06:17:36 -06:00
2021-08-17 20:17:34 -06:00
2021-08-30 18:52:11 -07:00
2021-06-17 15:51:20 +02:00
2020-03-17 20:55:21 +01:00
2021-10-18 06:17:36 -06:00
2021-10-18 06:17:36 -06:00
2021-10-18 06:17:36 -06:00
2021-09-14 00:22:15 -04:00
2021-10-18 06:17:01 -06:00
2021-10-18 06:17:35 -06:00