]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
testsuite: remove UNIQ(testname)
authorEmil Velikov <emil.l.velikov@gmail.com>
Sat, 18 Jul 2026 09:11:13 +0000 (10:11 +0100)
committerLucas De Marchi <ldemarchi@kernel.org>
Tue, 28 Jul 2026 14:11:03 +0000 (09:11 -0500)
Stop making the test name variable (section entry) unique. This is no
longer needed, plus we'll reshuffle some of the remaining names shortly.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/450
Signed-off-by: Lucas De Marchi <ldemarchi@kernel.org>
testsuite/testsuite.h

index 10dea9faeb0ca521c0ac370078a17efce27b5065..b23d631f7c1e1c6670a92ba1e96f6af5be33159b 100644 (file)
@@ -129,9 +129,11 @@ int test_run(const struct test *t);
        } while (false)
 
 /* Test definitions */
-#define DEFINE_TEST_WITH_FUNC(_name, _func, ...)                                      \
-       _used_ _retain_ _section_("kmod_tests") _alignedptr_ static const struct test \
-       UNIQ(s##_name) = { .name = #_name, .func = _func, ##__VA_ARGS__ }
+#define DEFINE_TEST_WITH_FUNC(_name, _func, ...)                           \
+       _used_ _retain_ _section_("kmod_tests")                            \
+       _alignedptr_ static const struct test s##_name = { .name = #_name, \
+                                                          .func = _func,  \
+                                                          ##__VA_ARGS__ }
 
 #define DEFINE_TEST(_name, ...) DEFINE_TEST_WITH_FUNC(_name, _name, __VA_ARGS__)