All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] vdpa: Mark macaddr_buf with static keyword
@ 2020-12-18  1:51 Zou Wei
  2020-12-18  5:20   ` Jason Wang
  2020-12-18  7:56   ` Stefano Garzarella
  0 siblings, 2 replies; 8+ messages in thread
From: Zou Wei @ 2020-12-18  1:51 UTC (permalink / raw)
  To: mst, jasowang; +Cc: sgarzare, mgurtovoy, virtualization, linux-kernel, Zou Wei

Fix the following sparse warning:

drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zou Wei <zou_wei@huawei.com>
---
 drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
index c10b698..f048242 100644
--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
@@ -33,7 +33,7 @@ static char *macaddr;
 module_param(macaddr, charp, 0);
 MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
 
-u8 macaddr_buf[ETH_ALEN];
+static u8 macaddr_buf[ETH_ALEN];
 
 static struct vdpasim *vdpasim_net_dev;
 
-- 
2.6.2


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

* Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
  2020-12-18  1:51 [PATCH -next] vdpa: Mark macaddr_buf with static keyword Zou Wei
@ 2020-12-18  5:20   ` Jason Wang
  2020-12-18  7:56   ` Stefano Garzarella
  1 sibling, 0 replies; 8+ messages in thread
From: Jason Wang @ 2020-12-18  5:20 UTC (permalink / raw)
  To: Zou Wei, mst; +Cc: sgarzare, mgurtovoy, virtualization, linux-kernel


On 2020/12/18 上午9:51, Zou Wei wrote:
> Fix the following sparse warning:
>
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zou Wei <zou_wei@huawei.com>
> ---
>   drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> index c10b698..f048242 100644
> --- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> +++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> @@ -33,7 +33,7 @@ static char *macaddr;
>   module_param(macaddr, charp, 0);
>   MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>   
> -u8 macaddr_buf[ETH_ALEN];
> +static u8 macaddr_buf[ETH_ALEN];
>   
>   static struct vdpasim *vdpasim_net_dev;


Acked-by: Jason Wang <jasowang@redhat.com>



>   


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

* Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
@ 2020-12-18  5:20   ` Jason Wang
  0 siblings, 0 replies; 8+ messages in thread
From: Jason Wang @ 2020-12-18  5:20 UTC (permalink / raw)
  To: Zou Wei, mst; +Cc: mgurtovoy, virtualization, linux-kernel


On 2020/12/18 上午9:51, Zou Wei wrote:
> Fix the following sparse warning:
>
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zou Wei <zou_wei@huawei.com>
> ---
>   drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> index c10b698..f048242 100644
> --- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> +++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> @@ -33,7 +33,7 @@ static char *macaddr;
>   module_param(macaddr, charp, 0);
>   MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>   
> -u8 macaddr_buf[ETH_ALEN];
> +static u8 macaddr_buf[ETH_ALEN];
>   
>   static struct vdpasim *vdpasim_net_dev;


Acked-by: Jason Wang <jasowang@redhat.com>



>   

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

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

* Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
  2020-12-18  1:51 [PATCH -next] vdpa: Mark macaddr_buf with static keyword Zou Wei
@ 2020-12-18  7:56   ` Stefano Garzarella
  2020-12-18  7:56   ` Stefano Garzarella
  1 sibling, 0 replies; 8+ messages in thread
From: Stefano Garzarella @ 2020-12-18  7:56 UTC (permalink / raw)
  To: Zou Wei; +Cc: mst, jasowang, mgurtovoy, virtualization, linux-kernel

On Fri, Dec 18, 2020 at 09:51:35AM +0800, Zou Wei wrote:
>Fix the following sparse warning:
>
>drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>
>Reported-by: Hulk Robot <hulkci@huawei.com>
>Signed-off-by: Zou Wei <zou_wei@huawei.com>
>---
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

I built with W=1 but I didn't have this warning.

Thanks for fixing,
Stefano

>
>diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>index c10b698..f048242 100644
>--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>@@ -33,7 +33,7 @@ static char *macaddr;
> module_param(macaddr, charp, 0);
> MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>
>-u8 macaddr_buf[ETH_ALEN];
>+static u8 macaddr_buf[ETH_ALEN];
>
> static struct vdpasim *vdpasim_net_dev;
>
>-- 
>2.6.2
>


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

* Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
@ 2020-12-18  7:56   ` Stefano Garzarella
  0 siblings, 0 replies; 8+ messages in thread
From: Stefano Garzarella @ 2020-12-18  7:56 UTC (permalink / raw)
  To: Zou Wei; +Cc: mgurtovoy, virtualization, linux-kernel, mst

On Fri, Dec 18, 2020 at 09:51:35AM +0800, Zou Wei wrote:
>Fix the following sparse warning:
>
>drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>
>Reported-by: Hulk Robot <hulkci@huawei.com>
>Signed-off-by: Zou Wei <zou_wei@huawei.com>
>---
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

I built with W=1 but I didn't have this warning.

Thanks for fixing,
Stefano

>
>diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>index c10b698..f048242 100644
>--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>@@ -33,7 +33,7 @@ static char *macaddr;
> module_param(macaddr, charp, 0);
> MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>
>-u8 macaddr_buf[ETH_ALEN];
>+static u8 macaddr_buf[ETH_ALEN];
>
> static struct vdpasim *vdpasim_net_dev;
>
>-- 
>2.6.2
>

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

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

* 答复: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
  2020-12-18  7:56   ` Stefano Garzarella
  (?)
@ 2020-12-18  8:11   ` Zouwei (Samuel)
  2020-12-18  8:15       ` Stefano Garzarella
  -1 siblings, 1 reply; 8+ messages in thread
From: Zouwei (Samuel) @ 2020-12-18  8:11 UTC (permalink / raw)
  To: Stefano Garzarella; +Cc: mst, jasowang, mgurtovoy, virtualization, linux-kernel

Hi,
I run this command:
make allmodconfig ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-
make C=2 drivers/vdpa/vdpa_sim/vdpa_sim_net.o ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-


-----邮件原件-----
发件人: Stefano Garzarella [mailto:sgarzare@redhat.com] 
发送时间: 2020年12月18日 15:57
收件人: Zouwei (Samuel) <zou_wei@huawei.com>
抄送: mst@redhat.com; jasowang@redhat.com; mgurtovoy@nvidia.com; virtualization@lists.linux-foundation.org; linux-kernel@vger.kernel.org
主题: Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword

On Fri, Dec 18, 2020 at 09:51:35AM +0800, Zou Wei wrote:
>Fix the following sparse warning:
>
>drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>
>Reported-by: Hulk Robot <hulkci@huawei.com>
>Signed-off-by: Zou Wei <zou_wei@huawei.com>
>---
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

I built with W=1 but I didn't have this warning.

Thanks for fixing,
Stefano

>
>diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c 
>b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>index c10b698..f048242 100644
>--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>@@ -33,7 +33,7 @@ static char *macaddr;  module_param(macaddr, charp, 
>0);  MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>
>-u8 macaddr_buf[ETH_ALEN];
>+static u8 macaddr_buf[ETH_ALEN];
>
> static struct vdpasim *vdpasim_net_dev;
>
>--
>2.6.2
>


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

* Re: 答复: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
  2020-12-18  8:11   ` 答复: " Zouwei (Samuel)
@ 2020-12-18  8:15       ` Stefano Garzarella
  0 siblings, 0 replies; 8+ messages in thread
From: Stefano Garzarella @ 2020-12-18  8:15 UTC (permalink / raw)
  To: Zouwei (Samuel); +Cc: mst, jasowang, mgurtovoy, virtualization, linux-kernel

On Fri, Dec 18, 2020 at 08:11:20AM +0000, Zouwei (Samuel) wrote:
>Hi,
>I run this command:
>make allmodconfig ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-
>make C=2 drivers/vdpa/vdpa_sim/vdpa_sim_net.o ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-

Yeah, I can see the warning using C=2.
I'll use it next times.

Thanks for sharing,
Stefano

>
>
>-----邮件原件-----
>发件人: Stefano Garzarella [mailto:sgarzare@redhat.com]
>发送时间: 2020年12月18日 15:57
>收件人: Zouwei (Samuel) <zou_wei@huawei.com>
>抄送: mst@redhat.com; jasowang@redhat.com; mgurtovoy@nvidia.com; virtualization@lists.linux-foundation.org; linux-kernel@vger.kernel.org
>主题: Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
>
>On Fri, Dec 18, 2020 at 09:51:35AM +0800, Zou Wei wrote:
>>Fix the following sparse warning:
>>
>>drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>>
>>Reported-by: Hulk Robot <hulkci@huawei.com>
>>Signed-off-by: Zou Wei <zou_wei@huawei.com>
>>---
>> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
>
>I built with W=1 but I didn't have this warning.
>
>Thanks for fixing,
>Stefano
>
>>
>>diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>index c10b698..f048242 100644
>>--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>@@ -33,7 +33,7 @@ static char *macaddr;  module_param(macaddr, charp,
>>0);  MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>>
>>-u8 macaddr_buf[ETH_ALEN];
>>+static u8 macaddr_buf[ETH_ALEN];
>>
>> static struct vdpasim *vdpasim_net_dev;
>>
>>--
>>2.6.2
>>
>


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

* Re: 答复: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
@ 2020-12-18  8:15       ` Stefano Garzarella
  0 siblings, 0 replies; 8+ messages in thread
From: Stefano Garzarella @ 2020-12-18  8:15 UTC (permalink / raw)
  To: Zouwei (Samuel); +Cc: mgurtovoy, virtualization, linux-kernel, mst

On Fri, Dec 18, 2020 at 08:11:20AM +0000, Zouwei (Samuel) wrote:
>Hi,
>I run this command:
>make allmodconfig ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-
>make C=2 drivers/vdpa/vdpa_sim/vdpa_sim_net.o ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-

Yeah, I can see the warning using C=2.
I'll use it next times.

Thanks for sharing,
Stefano

>
>
>-----邮件原件-----
>发件人: Stefano Garzarella [mailto:sgarzare@redhat.com]
>发送时间: 2020年12月18日 15:57
>收件人: Zouwei (Samuel) <zou_wei@huawei.com>
>抄送: mst@redhat.com; jasowang@redhat.com; mgurtovoy@nvidia.com; virtualization@lists.linux-foundation.org; linux-kernel@vger.kernel.org
>主题: Re: [PATCH -next] vdpa: Mark macaddr_buf with static keyword
>
>On Fri, Dec 18, 2020 at 09:51:35AM +0800, Zou Wei wrote:
>>Fix the following sparse warning:
>>
>>drivers/vdpa/vdpa_sim/vdpa_sim_net.c:36:4: warning: symbol 'macaddr_buf' was not declared. Should it be static?
>>
>>Reported-by: Hulk Robot <hulkci@huawei.com>
>>Signed-off-by: Zou Wei <zou_wei@huawei.com>
>>---
>> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
>
>I built with W=1 but I didn't have this warning.
>
>Thanks for fixing,
>Stefano
>
>>
>>diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>index c10b698..f048242 100644
>>--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
>>@@ -33,7 +33,7 @@ static char *macaddr;  module_param(macaddr, charp,
>>0);  MODULE_PARM_DESC(macaddr, "Ethernet MAC address");
>>
>>-u8 macaddr_buf[ETH_ALEN];
>>+static u8 macaddr_buf[ETH_ALEN];
>>
>> static struct vdpasim *vdpasim_net_dev;
>>
>>--
>>2.6.2
>>
>

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

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

end of thread, other threads:[~2020-12-18  8:17 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-18  1:51 [PATCH -next] vdpa: Mark macaddr_buf with static keyword Zou Wei
2020-12-18  5:20 ` Jason Wang
2020-12-18  5:20   ` Jason Wang
2020-12-18  7:56 ` Stefano Garzarella
2020-12-18  7:56   ` Stefano Garzarella
2020-12-18  8:11   ` 答复: " Zouwei (Samuel)
2020-12-18  8:15     ` Stefano Garzarella
2020-12-18  8:15       ` Stefano Garzarella

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.