diff options
| author | Christoph Hellwig <hch@lst.de> | 2026-03-16 19:11:30 +0300 |
|---|---|---|
| committer | Jens Axboe <axboe@kernel.dk> | 2026-03-18 04:27:14 +0300 |
| commit | b520c4eef83dd406591431f936de0908c3ed7fb9 (patch) | |
| tree | 9b5ca572a66dae95eebf0d1bb078652584aa18ae /include/linux/bio.h | |
| parent | fed406f3c1c2feb97adcbc557218713c5f7ec6a7 (diff) | |
| download | linux-b520c4eef83dd406591431f936de0908c3ed7fb9.tar.xz | |
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>
Diffstat (limited to 'include/linux/bio.h')
| -rw-r--r-- | include/linux/bio.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/include/linux/bio.h b/include/linux/bio.h index 9693a0d6fefe..984844d2870b 100644 --- a/include/linux/bio.h +++ b/include/linux/bio.h @@ -350,8 +350,7 @@ extern void bioset_exit(struct bio_set *); extern int biovec_init_pool(mempool_t *pool, int pool_entries); struct bio *bio_alloc_bioset(struct block_device *bdev, unsigned short nr_vecs, - blk_opf_t opf, gfp_t gfp_mask, - struct bio_set *bs); + blk_opf_t opf, gfp_t gfp, struct bio_set *bs); struct bio *bio_kmalloc(unsigned short nr_vecs, gfp_t gfp_mask); extern void bio_put(struct bio *); |
