Skip to content

Commit 1b6d639

Browse files
Zhen Leitorvalds
authored andcommitted
lib: kunit: suppress a compilation warning of frame size
lib/bitfield_kunit.c: In function `test_bitfields_constants': lib/bitfield_kunit.c:93:1: warning: the frame size of 7456 bytes is larger than 2048 bytes [-Wframe-larger-than=] } ^ As the description of BITFIELD_KUNIT in lib/Kconfig.debug, it "Only useful for kernel devs running the KUnit test harness, and not intended for inclusion into a production build". Therefore, it is not worth modifying variable 'test_bitfields_constants' to clear this warning. Just suppress it. Link: https://lkml.kernel.org/r/20210518094533.7652-1-thunder.leizhen@huawei.com Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com> Cc: Shuah Khan <skhan@linuxfoundation.org> Cc: Vitor Massaru Iha <vitor@massaru.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 43b2ec9 commit 1b6d639

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

lib/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,7 @@ obj-$(CONFIG_OBJAGG) += objagg.o
348348
obj-$(CONFIG_PLDMFW) += pldmfw/
349349

350350
# KUnit tests
351+
CFLAGS_bitfield_kunit.o := $(call cc-option,-Wframe-larger-than=10240)
351352
obj-$(CONFIG_BITFIELD_KUNIT) += bitfield_kunit.o
352353
obj-$(CONFIG_LIST_KUNIT_TEST) += list-test.o
353354
obj-$(CONFIG_LINEAR_RANGES_TEST) += test_linear_ranges.o

0 commit comments

Comments
 (0)