]> git.baikalelectronics.ru Git - kernel.git/commit
mm: remove get_swap_bio
authorChristoph Hellwig <hch@lst.de>
Tue, 26 Jan 2021 14:52:47 +0000 (15:52 +0100)
committerJens Axboe <axboe@kernel.dk>
Wed, 27 Jan 2021 16:51:49 +0000 (09:51 -0700)
commit7e3f8c327aff61dc9a1607c7aad40efb20665ada
tree2662d4a0b4e595433ae4caa57c4f2c437c7a7fc9
parent4c90078029f4bea9b7d6bffafe0f269bf8e86f3d
mm: remove get_swap_bio

Just reuse the block_device and sector from the swap_info structure,
just as used by the SWP_SYNCHRONOUS path.  Also remove the checks for
NULL returns from bio_alloc as that can't happen for sleeping
allocations.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Acked-by: Damien Le Moal <damien.lemoal@wdc.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
include/linux/swap.h
mm/page_io.c
mm/swapfile.c