Message ID | bea97388-01df-8eac-091b-a3c89b4a4a09@suse.cz (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [FIX,-next] Re: [linux-next:master 7012/7430] include/linux/compiler_types.h:328:38: error: call to '__compiletime_assert_183' declared with attribute error: unexpected size in kmalloc_index() | expand |
diff --git a/include/linux/slab.h b/include/linux/slab.h index 8d8dd8571261..083f3ce550bc 100644 --- a/include/linux/slab.h +++ b/include/linux/slab.h @@ -413,7 +413,8 @@ static __always_inline unsigned int __kmalloc_index(size_t size, if (size <= 16 * 1024 * 1024) return 24; if (size <= 32 * 1024 * 1024) return 25; - if ((IS_ENABLED(CONFIG_CC_IS_GCC) || CONFIG_CLANG_VERSION >= 110000) && size_is_constant) + if ((IS_ENABLED(CONFIG_CC_IS_GCC) || CONFIG_CLANG_VERSION >= 110000) + && !IS_ENABLED(CONFIG_PROFILE_ALL_BRANCHES) && size_is_constant) BUILD_BUG_ON_MSG(1, "unexpected size in kmalloc_index()"); else BUG();