diff mbox series

libnvdimm/security: make __nvdimm_security_overwrite_query() static

Message ID 20200409084857.44169-1-yanaijie@huawei.com (mailing list archive)
State New, archived
Headers show
Series libnvdimm/security: make __nvdimm_security_overwrite_query() static | expand

Commit Message

Jason Yan April 9, 2020, 8:48 a.m. UTC
Fix the following sparse warning:

drivers/nvdimm/security.c:416:6: warning: symbol
'__nvdimm_security_overwrite_query' was not declared. Should it be
static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/nvdimm/security.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Ira Weiny April 9, 2020, 3:41 p.m. UTC | #1
On Thu, Apr 09, 2020 at 04:48:57PM +0800, Jason Yan wrote:
> Fix the following sparse warning:
> 
> drivers/nvdimm/security.c:416:6: warning: symbol
> '__nvdimm_security_overwrite_query' was not declared. Should it be
> static?
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Reviewed-by: Ira Weiny <ira.weiny@intel.com>

> ---
>  drivers/nvdimm/security.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/nvdimm/security.c b/drivers/nvdimm/security.c
> index 89b85970912d..11fb5ada70ad 100644
> --- a/drivers/nvdimm/security.c
> +++ b/drivers/nvdimm/security.c
> @@ -413,7 +413,7 @@ static int security_overwrite(struct nvdimm *nvdimm, unsigned int keyid)
>  	return rc;
>  }
>  
> -void __nvdimm_security_overwrite_query(struct nvdimm *nvdimm)
> +static void __nvdimm_security_overwrite_query(struct nvdimm *nvdimm)
>  {
>  	struct nvdimm_bus *nvdimm_bus = walk_to_nvdimm_bus(&nvdimm->dev);
>  	int rc;
> -- 
> 2.17.2
>
diff mbox series

Patch

diff --git a/drivers/nvdimm/security.c b/drivers/nvdimm/security.c
index 89b85970912d..11fb5ada70ad 100644
--- a/drivers/nvdimm/security.c
+++ b/drivers/nvdimm/security.c
@@ -413,7 +413,7 @@  static int security_overwrite(struct nvdimm *nvdimm, unsigned int keyid)
 	return rc;
 }
 
-void __nvdimm_security_overwrite_query(struct nvdimm *nvdimm)
+static void __nvdimm_security_overwrite_query(struct nvdimm *nvdimm)
 {
 	struct nvdimm_bus *nvdimm_bus = walk_to_nvdimm_bus(&nvdimm->dev);
 	int rc;