Skip to content
Commit 0df71650 authored by Mike Snitzer's avatar Mike Snitzer Committed by Jens Axboe
Browse files

block: allow using the per-cpu bio cache from bio_alloc_bioset



Replace the BIO_PERCPU_CACHE bio-internal flag with a REQ_ALLOC_CACHE
one that can be passed to bio_alloc / bio_alloc_bioset, and implement
the percpu cache allocation logic in a helper called from
bio_alloc_bioset.  This allows any bio_alloc_bioset user to use the
percpu caches instead of having the functionality tied to struct kiocb.

Signed-off-by: default avatarMike Snitzer <snitzer@kernel.org>
[hch: refactored a bit]
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20220324203526.62306-2-snitzer@kernel.org


Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent b2d229d4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment