diff mbox series

[-next] coresight: catu: Make catu_helper_ops and catu_ops static

Message ID 20190321151852.10216-1-yuehaibing@huawei.com (mailing list archive)
State Mainlined, archived
Commit 61810404b43fb0f7195cd947aef903ac90ea6989
Headers show
Series [-next] coresight: catu: Make catu_helper_ops and catu_ops static | expand

Commit Message

Yue Haibing March 21, 2019, 3:18 p.m. UTC
From: YueHaibing <yuehaibing@huawei.com>

Fix sparse warnings:

drivers/hwtracing/coresight/coresight-catu.c:488:35: warning:
 symbol 'catu_helper_ops' was not declared. Should it be static?
drivers/hwtracing/coresight/coresight-catu.c:493:28: warning:
 symbol 'catu_ops' was not declared. Should it be static?

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/hwtracing/coresight/coresight-catu.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Suzuki K Poulose March 22, 2019, 12:31 p.m. UTC | #1
On 03/21/2019 03:18 PM, Yue Haibing wrote:
> From: YueHaibing <yuehaibing@huawei.com>
> 
> Fix sparse warnings:
> 
> drivers/hwtracing/coresight/coresight-catu.c:488:35: warning:
>   symbol 'catu_helper_ops' was not declared. Should it be static?
> drivers/hwtracing/coresight/coresight-catu.c:493:28: warning:
>   symbol 'catu_ops' was not declared. Should it be static?
> 
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
>   drivers/hwtracing/coresight/coresight-catu.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/hwtracing/coresight/coresight-catu.c b/drivers/hwtracing/coresight/coresight-catu.c
> index 170fbb6..057627a 100644
> --- a/drivers/hwtracing/coresight/coresight-catu.c
> +++ b/drivers/hwtracing/coresight/coresight-catu.c
> @@ -485,12 +485,12 @@ static int catu_disable(struct coresight_device *csdev, void *__unused)
>   	return rc;
>   }
>   
> -const struct coresight_ops_helper catu_helper_ops = {
> +static const struct coresight_ops_helper catu_helper_ops = {
>   	.enable = catu_enable,
>   	.disable = catu_disable,
>   };
>   
> -const struct coresight_ops catu_ops = {
> +static const struct coresight_ops catu_ops = {
>   	.helper_ops = &catu_helper_ops,
>   };
>   
> 

Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Mathieu Poirier March 22, 2019, 4:33 p.m. UTC | #2
On Thu, 21 Mar 2019 at 09:19, Yue Haibing <yuehaibing@huawei.com> wrote:
>
> From: YueHaibing <yuehaibing@huawei.com>
>
> Fix sparse warnings:
>
> drivers/hwtracing/coresight/coresight-catu.c:488:35: warning:
>  symbol 'catu_helper_ops' was not declared. Should it be static?
> drivers/hwtracing/coresight/coresight-catu.c:493:28: warning:
>  symbol 'catu_ops' was not declared. Should it be static?
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
>  drivers/hwtracing/coresight/coresight-catu.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/hwtracing/coresight/coresight-catu.c b/drivers/hwtracing/coresight/coresight-catu.c
> index 170fbb6..057627a 100644
> --- a/drivers/hwtracing/coresight/coresight-catu.c
> +++ b/drivers/hwtracing/coresight/coresight-catu.c
> @@ -485,12 +485,12 @@ static int catu_disable(struct coresight_device *csdev, void *__unused)
>         return rc;
>  }
>
> -const struct coresight_ops_helper catu_helper_ops = {
> +static const struct coresight_ops_helper catu_helper_ops = {
>         .enable = catu_enable,
>         .disable = catu_disable,
>  };
>
> -const struct coresight_ops catu_ops = {
> +static const struct coresight_ops catu_ops = {
>         .helper_ops = &catu_helper_ops,
>  };
>

Applied thanks.
Mathieu

> --
> 2.7.0
>
>
diff mbox series

Patch

diff --git a/drivers/hwtracing/coresight/coresight-catu.c b/drivers/hwtracing/coresight/coresight-catu.c
index 170fbb6..057627a 100644
--- a/drivers/hwtracing/coresight/coresight-catu.c
+++ b/drivers/hwtracing/coresight/coresight-catu.c
@@ -485,12 +485,12 @@  static int catu_disable(struct coresight_device *csdev, void *__unused)
 	return rc;
 }
 
-const struct coresight_ops_helper catu_helper_ops = {
+static const struct coresight_ops_helper catu_helper_ops = {
 	.enable = catu_enable,
 	.disable = catu_disable,
 };
 
-const struct coresight_ops catu_ops = {
+static const struct coresight_ops catu_ops = {
 	.helper_ops = &catu_helper_ops,
 };