Home
last modified time | relevance | path

Searched hist:"21 bd900572f3708e281ea25f051fc92462eb1193" (Results 1 – 4 of 4) sorted by relevance

/openbmc/linux/kernel/power/
H A Duser.cdiff 21bd900572f3708e281ea25f051fc92462eb1193 Mon Sep 21 02:19:56 CDT 2020 Christoph Hellwig <hch@lst.de> mm: split swap_type_of

swap_type_of is used for two entirely different purposes:

(1) check what swap type a given device/offset corresponds to
(2) find the first available swap device that can be written to

Mixing both in a single function creates an unreadable mess. Create two
separate functions instead, and switch both to pass a dev_t instead of
a struct block_device to further simplify the code.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
H A Dswap.cdiff 21bd900572f3708e281ea25f051fc92462eb1193 Mon Sep 21 02:19:56 CDT 2020 Christoph Hellwig <hch@lst.de> mm: split swap_type_of

swap_type_of is used for two entirely different purposes:

(1) check what swap type a given device/offset corresponds to
(2) find the first available swap device that can be written to

Mixing both in a single function creates an unreadable mess. Create two
separate functions instead, and switch both to pass a dev_t instead of
a struct block_device to further simplify the code.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
/openbmc/linux/include/linux/
H A Dswap.hdiff 21bd900572f3708e281ea25f051fc92462eb1193 Mon Sep 21 02:19:56 CDT 2020 Christoph Hellwig <hch@lst.de> mm: split swap_type_of

swap_type_of is used for two entirely different purposes:

(1) check what swap type a given device/offset corresponds to
(2) find the first available swap device that can be written to

Mixing both in a single function creates an unreadable mess. Create two
separate functions instead, and switch both to pass a dev_t instead of
a struct block_device to further simplify the code.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
/openbmc/linux/mm/
H A Dswapfile.cdiff 21bd900572f3708e281ea25f051fc92462eb1193 Mon Sep 21 02:19:56 CDT 2020 Christoph Hellwig <hch@lst.de> mm: split swap_type_of

swap_type_of is used for two entirely different purposes:

(1) check what swap type a given device/offset corresponds to
(2) find the first available swap device that can be written to

Mixing both in a single function creates an unreadable mess. Create two
separate functions instead, and switch both to pass a dev_t instead of
a struct block_device to further simplify the code.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>