linux-nvdimm.lists.01.org archive mirror
 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;
_______________________________________________
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-leave@lists.01.org

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

* Re: [PATCH -next] device-dax: make dev_dax_kmem_probe() static
  2020-07-07 11:23 [PATCH -next] device-dax: make dev_dax_kmem_probe() static Wei Yongjun
@ 2020-07-11  3:31 ` Ira Weiny
  0 siblings, 0 replies; 3+ messages in thread
From: Ira Weiny @ 2020-07-11  3:31 UTC (permalink / raw)
  To: Wei Yongjun; +Cc: Hulk Robot, Dave Hansen, linux-nvdimm, linux-kernel

On Tue, Jul 07, 2020 at 07:23:40PM +0800, Wei Yongjun wrote:
> 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>

Seems ok,

Reviewed-by: Ira Weiny <ira.weiny@intel.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;
> 
_______________________________________________
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-leave@lists.01.org

^ 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: YueHaibing, linux-kernel, linux-nvdimm

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


_______________________________________________
Linux-nvdimm mailing list
Linux-nvdimm@lists.01.org
https://lists.01.org/mailman/listinfo/linux-nvdimm

^ permalink raw reply related	[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;
as well as URLs for NNTP newsgroup(s).