linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] lib/test_bits: make some functions static
@ 2020-07-02 15:03 Wei Yongjun
  0 siblings, 0 replies; only message in thread
From: Wei Yongjun @ 2020-07-02 15:03 UTC (permalink / raw)
  To: Hulk Robot, Stephen Rothwell, Andrew Morton, Andy Shevchenko,
	Rikard Falkeborn, Randy Dunlap
  Cc: Wei Yongjun, linux-kernel

Fix sparse build warnings:

lib/test_bits.c:10:6: warning:
 symbol 'genmask_test' was not declared. Should it be static?
lib/test_bits.c:27:6: warning:
 symbol 'genmask_ull_test' was not declared. Should it be static?
lib/test_bits.c:42:6: warning:
 symbol 'genmask_input_check_test' was not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 lib/test_bits.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/test_bits.c b/lib/test_bits.c
index 89e0ea83511f..c9368a2314e7 100644
--- a/lib/test_bits.c
+++ b/lib/test_bits.c
@@ -7,7 +7,7 @@
 #include <linux/bits.h>
 
 
-void genmask_test(struct kunit *test)
+static void genmask_test(struct kunit *test)
 {
 	KUNIT_EXPECT_EQ(test, 1ul, GENMASK(0, 0));
 	KUNIT_EXPECT_EQ(test, 3ul, GENMASK(1, 0));
@@ -24,7 +24,7 @@ void genmask_test(struct kunit *test)
 
 }
 
-void genmask_ull_test(struct kunit *test)
+static void genmask_ull_test(struct kunit *test)
 {
 	KUNIT_EXPECT_EQ(test, 1ull, GENMASK_ULL(0, 0));
 	KUNIT_EXPECT_EQ(test, 3ull, GENMASK_ULL(1, 0));
@@ -39,7 +39,7 @@ void genmask_ull_test(struct kunit *test)
 #endif
 }
 
-void genmask_input_check_test(struct kunit *test)
+static void genmask_input_check_test(struct kunit *test)
 {
 	unsigned int x, y;
 	int z, w;


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2020-07-02 14:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-02 15:03 [PATCH -next] lib/test_bits: make some functions static Wei Yongjun

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).