mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH -next] device-dax: make dev_dax_kmem_probe() static
@ 2020-07-07 11:23 Wei Yongjun
  2020-07-11  3:31 ` Ira Weiny
  0 siblings, 1 reply; 3+ messages in thread
From: Wei Yongjun @ 2020-07-07 11:23 UTC (permalink / raw)
  To: Hulk Robot, Dan Williams, Vishal Verma, Dave Jiang, Dave Hansen
  Cc: Wei Yongjun, linux-nvdimm, linux-kernel

sparse report warning as follows:

drivers/dax/kmem.c:22:5: warning:
 symbol 'dev_dax_kmem_probe' was not declared. Should it be static?

dev_dax_kmem_probe() is not used outside of kmem.c, so marks
it static.

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/dax/kmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/dax/kmem.c b/drivers/dax/kmem.c
index 275aa5f87399..87e271668170 100644
--- a/drivers/dax/kmem.c
+++ b/drivers/dax/kmem.c
@@ -19,7 +19,7 @@ static const char *kmem_name;
 /* Set if any memory will remain added when the driver will be unloaded. */
 static bool any_hotremove_failed;
 
-int dev_dax_kmem_probe(struct device *dev)
+static int dev_dax_kmem_probe(struct device *dev)
 {
 	struct dev_dax *dev_dax = to_dev_dax(dev);
 	struct resource *res = &dev_dax->region->res;


^ permalink raw reply	[flat|nested] 3+ messages in thread
* [PATCH -next] device-dax: Make dev_dax_kmem_probe static
@ 2019-03-22 14:33 Yue Haibing
  0 siblings, 0 replies; 3+ messages in thread
From: Yue Haibing @ 2019-03-22 14:33 UTC (permalink / raw)
  To: dan.j.williams, vishal.l.verma, keith.busch, dave.jiang
  Cc: linux-kernel, linux-nvdimm, YueHaibing

From: YueHaibing <yuehaibing@huawei.com>

Fix sparse warning:

drivers/dax/kmem.c:17:5: warning:
 symbol 'dev_dax_kmem_probe' was not declared. Should it be static?

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/dax/kmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/dax/kmem.c b/drivers/dax/kmem.c
index a02318c..e5cbbe2 100644
--- a/drivers/dax/kmem.c
+++ b/drivers/dax/kmem.c
@@ -14,7 +14,7 @@
 #include "dax-private.h"
 #include "bus.h"
 
-int dev_dax_kmem_probe(struct device *dev)
+static int dev_dax_kmem_probe(struct device *dev)
 {
 	struct dev_dax *dev_dax = to_dev_dax(dev);
 	struct resource *res = &dev_dax->region->res;
-- 
2.7.0



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-07-11  3:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-07 11:23 [PATCH -next] device-dax: make dev_dax_kmem_probe() static Wei Yongjun
2020-07-11  3:31 ` Ira Weiny
  -- strict thread matches above, loose matches on Subject: below --
2019-03-22 14:33 [PATCH -next] device-dax: Make dev_dax_kmem_probe static Yue Haibing

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®