]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
block: split bio_alloc_bioset more clearly into a fast and slowpath
authorChristoph Hellwig <hch@lst.de>
Mon, 16 Mar 2026 16:11:30 +0000 (17:11 +0100)
committerJens Axboe <axboe@kernel.dk>
Wed, 18 Mar 2026 01:27:14 +0000 (19:27 -0600)
commitb520c4eef83dd406591431f936de0908c3ed7fb9
tree9b5ca572a66dae95eebf0d1bb078652584aa18ae
parentfed406f3c1c2feb97adcbc557218713c5f7ec6a7
block: split bio_alloc_bioset more clearly into a fast and slowpath

bio_alloc_bioset tries non-waiting slab allocations first for the bio and
bvec array, but does so in a somewhat convoluted way.

Restructure the function so that it first open codes these slab
allocations, and then falls back to the mempools with the original
gfp mask.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com> -ck
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Link: https://patch.msgid.link/20260316161144.1607877-3-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/bio.c
include/linux/bio.h