Skip to content

Commit 2bbfb8f

Browse files
Ming Leiopsiff
Ming Lei
authored andcommitted
block: fix 'kmem_cache of name 'bio-108' already exists'
mainline inclusion from mainline-v6.14-rc5 category: bugfix Device mapper bioset often has big bio_slab size, which can be more than 1000, then 8byte can't hold the slab name any more, cause the kmem_cache allocation warning of 'kmem_cache of name 'bio-108' already exists'. Fix the warning by extending bio_slab->name to 12 bytes, but fix output of /proc/slabinfo Reported-by: Guangwu Zhang <[email protected]> Signed-off-by: Ming Lei <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jens Axboe <[email protected]> (cherry picked from commit b654f7a) Signed-off-by: Wentao Guan <[email protected]>
1 parent b11cfb2 commit 2bbfb8f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

block/bio.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ struct bio_slab {
7878
struct kmem_cache *slab;
7979
unsigned int slab_ref;
8080
unsigned int slab_size;
81-
char name[8];
81+
char name[12];
8282
};
8383
static DEFINE_MUTEX(bio_slab_lock);
8484
static DEFINE_XARRAY(bio_slabs);

0 commit comments

Comments
 (0)