2018-01-10 14:13:33

by Wei Yongjun

[permalink] [raw]
Subject: [PATCH -next] meson-gx-socinfo: make local function meson_gx_socinfo_init static

Fixes the following sparse warnings:

drivers/soc/amlogic/meson-gx-socinfo.c:100:12: warning:
symbol 'meson_gx_socinfo_init' was not declared. Should it be static?

Signed-off-by: Wei Yongjun <[email protected]>
---
drivers/soc/amlogic/meson-gx-socinfo.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/soc/amlogic/meson-gx-socinfo.c b/drivers/soc/amlogic/meson-gx-socinfo.c
index f2d8c3c..ea091f1 100644
--- a/drivers/soc/amlogic/meson-gx-socinfo.c
+++ b/drivers/soc/amlogic/meson-gx-socinfo.c
@@ -97,7 +97,7 @@ static const char *socinfo_to_soc_id(u32 socinfo)
return "Unknown";
}

-int __init meson_gx_socinfo_init(void)
+static int __init meson_gx_socinfo_init(void)
{
struct soc_device_attribute *soc_dev_attr;
struct soc_device *soc_dev;




2018-02-06 12:26:09

by Neil Armstrong

[permalink] [raw]
Subject: Re: [PATCH -next] meson-gx-socinfo: make local function meson_gx_socinfo_init static

On 10/01/2018 15:19, Wei Yongjun wrote:
> Fixes the following sparse warnings:
>
> drivers/soc/amlogic/meson-gx-socinfo.c:100:12: warning:
> symbol 'meson_gx_socinfo_init' was not declared. Should it be static?
>
> Signed-off-by: Wei Yongjun <[email protected]>
> ---
> drivers/soc/amlogic/meson-gx-socinfo.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/soc/amlogic/meson-gx-socinfo.c b/drivers/soc/amlogic/meson-gx-socinfo.c
> index f2d8c3c..ea091f1 100644
> --- a/drivers/soc/amlogic/meson-gx-socinfo.c
> +++ b/drivers/soc/amlogic/meson-gx-socinfo.c
> @@ -97,7 +97,7 @@ static const char *socinfo_to_soc_id(u32 socinfo)
> return "Unknown";
> }
>
> -int __init meson_gx_socinfo_init(void)
> +static int __init meson_gx_socinfo_init(void)
> {
> struct soc_device_attribute *soc_dev_attr;
> struct soc_device *soc_dev;
>
>
>

Acked-by: Neil Armstrong <[email protected]>

2018-02-09 00:51:23

by Kevin Hilman

[permalink] [raw]
Subject: Re: [PATCH -next] meson-gx-socinfo: make local function meson_gx_socinfo_init static

Neil Armstrong <[email protected]> writes:

> On 10/01/2018 15:19, Wei Yongjun wrote:
>> Fixes the following sparse warnings:
>>
>> drivers/soc/amlogic/meson-gx-socinfo.c:100:12: warning:
>> symbol 'meson_gx_socinfo_init' was not declared. Should it be static?
>>
>> Signed-off-by: Wei Yongjun <[email protected]>
>> ---
>> drivers/soc/amlogic/meson-gx-socinfo.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/soc/amlogic/meson-gx-socinfo.c b/drivers/soc/amlogic/meson-gx-socinfo.c
>> index f2d8c3c..ea091f1 100644
>> --- a/drivers/soc/amlogic/meson-gx-socinfo.c
>> +++ b/drivers/soc/amlogic/meson-gx-socinfo.c
>> @@ -97,7 +97,7 @@ static const char *socinfo_to_soc_id(u32 socinfo)
>> return "Unknown";
>> }
>>
>> -int __init meson_gx_socinfo_init(void)
>> +static int __init meson_gx_socinfo_init(void)
>> {
>> struct soc_device_attribute *soc_dev_attr;
>> struct soc_device *soc_dev;
>>
>>
>>
>
> Acked-by: Neil Armstrong <[email protected]>

Applied for v4.17, with Neil's ack.

Kevin