summaryrefslogtreecommitdiff
path: root/lib/tests/overflow_kunit.c
diff options
context:
space:
mode:
authorJani Nikula <jani.nikula@intel.com>2025-06-09 12:40:46 +0300
committerJani Nikula <jani.nikula@intel.com>2025-06-09 12:40:46 +0300
commit34c55367af96f62e89221444f04487440ebc6487 (patch)
treefdb36ba67d7dea09455b55037e26043b7e051ef9 /lib/tests/overflow_kunit.c
parent7247efca0dcbc8ac6147db9200ed1549c0662465 (diff)
parent19272b37aa4f83ca52bdf9c16d5d81bdd1354494 (diff)
downloadlinux-34c55367af96f62e89221444f04487440ebc6487.tar.xz
Merge drm/drm-next into drm-intel-next
Sync to v6.16-rc1, among other things to get the fixed size GENMASK_U*() and BIT_U*() macros. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Diffstat (limited to 'lib/tests/overflow_kunit.c')
-rw-r--r--lib/tests/overflow_kunit.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/tests/overflow_kunit.c b/lib/tests/overflow_kunit.c
index 894691b4411a..19cb03b25dc5 100644
--- a/lib/tests/overflow_kunit.c
+++ b/lib/tests/overflow_kunit.c
@@ -1210,6 +1210,10 @@ static void DEFINE_FLEX_test(struct kunit *test)
KUNIT_EXPECT_EQ(test, __struct_size(empty->array), 0);
KUNIT_EXPECT_EQ(test, __member_size(empty->array), 0);
+ KUNIT_EXPECT_EQ(test, STACK_FLEX_ARRAY_SIZE(two, array), 2);
+ KUNIT_EXPECT_EQ(test, STACK_FLEX_ARRAY_SIZE(eight, array), 8);
+ KUNIT_EXPECT_EQ(test, STACK_FLEX_ARRAY_SIZE(empty, array), 0);
+
/* If __counted_by is not being used, array size will have the on-stack size. */
if (!IS_ENABLED(CONFIG_CC_HAS_COUNTED_BY))
array_size_override = 2 * sizeof(s16);