Commit 21d0f4fa authored by Eric Biggers's avatar Eric Biggers Committed by Theodore Ts'o

mbcache: don't BUG() if entry cache cannot be allocated

mbcache can be a module that is loaded long after startup, when someone
asks to mount an ext2 or ext4 filesystem.  Therefore it should not BUG()
if kmem_cache_create() fails, but rather just fail the module load.
Signed-off-by: default avatarEric Biggers <>
Signed-off-by: default avatarTheodore Ts'o <>
Reviewed-by: default avatarJan Kara <>
parent 918b7306
......@@ -420,7 +420,8 @@ static int __init mbcache_init(void)
mb_entry_cache = kmem_cache_create("mbcache",
sizeof(struct mb_cache_entry), 0,
if (!mb_entry_cache)
return -ENOMEM;
return 0;
Markdown is supported
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