All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] stmmac: fix noderef.cocci warnings
  2016-03-03  1:55 [net-next:master 963/985] drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer kbuild test robot
@ 2016-03-03  1:55 ` kbuild test robot
  2016-03-04 12:45   ` Alexandre Torgue
  2016-03-07  3:46   ` David Miller
  0 siblings, 2 replies; 5+ messages in thread
From: kbuild test robot @ 2016-03-03  1:55 UTC (permalink / raw)
  To: Giuseppe Cavallaro; +Cc: kbuild-all, netdev, Alexandre TORGUE, linux-kernel

drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer

 sizeof when applied to a pointer typed expression gives the size of
 the pointer

Generated by: scripts/coccinelle/misc/noderef.cocci

CC: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
---

 stmmac_platform.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
@@ -112,7 +112,7 @@ static struct stmmac_axi *stmmac_axi_set
 	if (!np)
 		return NULL;
 
-	axi = kzalloc(sizeof(axi), GFP_KERNEL);
+	axi = kzalloc(sizeof(*axi), GFP_KERNEL);
 	if (!axi)
 		return ERR_PTR(-ENOMEM);
 

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

* [net-next:master 963/985] drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer
@ 2016-03-03  1:55 kbuild test robot
  2016-03-03  1:55 ` [PATCH] stmmac: fix noderef.cocci warnings kbuild test robot
  0 siblings, 1 reply; 5+ messages in thread
From: kbuild test robot @ 2016-03-03  1:55 UTC (permalink / raw)
  To: Giuseppe Cavallaro; +Cc: kbuild-all, netdev, Alexandre TORGUE

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head:   3ebeac1d029550a860ea2d034bf1c7f1de52d442
commit: afea03656add70a0e00f5b0039f87288c7af8b9f [963/985] stmmac: rework DMA bus setting and introduce new platform AXI structure


coccinelle warnings: (new ones prefixed by >>)

>> drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer

Please review and possibly fold the followup patch.

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

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

* Re: [PATCH] stmmac: fix noderef.cocci warnings
  2016-03-03  1:55 ` [PATCH] stmmac: fix noderef.cocci warnings kbuild test robot
@ 2016-03-04 12:45   ` Alexandre Torgue
  2016-03-04 21:32     ` David Miller
  2016-03-07  3:46   ` David Miller
  1 sibling, 1 reply; 5+ messages in thread
From: Alexandre Torgue @ 2016-03-04 12:45 UTC (permalink / raw)
  To: kbuild test robot, Giuseppe Cavallaro; +Cc: kbuild-all, netdev, linux-kernel

Hi,

On 03/03/2016 02:55 AM, kbuild test robot wrote:
> drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer
>
>   sizeof when applied to a pointer typed expression gives the size of
>   the pointer
>
> Generated by: scripts/coccinelle/misc/noderef.cocci
>
> CC: Giuseppe Cavallaro <peppe.cavallaro@st.com>
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> ---
>
>   stmmac_platform.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
> @@ -112,7 +112,7 @@ static struct stmmac_axi *stmmac_axi_set
>   	if (!np)
>   		return NULL;
>
> -	axi = kzalloc(sizeof(axi), GFP_KERNEL);
> +	axi = kzalloc(sizeof(*axi), GFP_KERNEL);
>   	if (!axi)
>   		return ERR_PTR(-ENOMEM);
>
>


Thanks.
You can add my Acked-by: Alexandre Torgue <alexandre.torgue@st.com>

-- 

Regards

Alex

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

* Re: [PATCH] stmmac: fix noderef.cocci warnings
  2016-03-04 12:45   ` Alexandre Torgue
@ 2016-03-04 21:32     ` David Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2016-03-04 21:32 UTC (permalink / raw)
  To: alexandre.torgue
  Cc: fengguang.wu, peppe.cavallaro, kbuild-all, netdev, linux-kernel

From: Alexandre Torgue <alexandre.torgue@st.com>
Date: Fri, 4 Mar 2016 13:45:40 +0100

> Hi,
> 
> On 03/03/2016 02:55 AM, kbuild test robot wrote:
>> drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21:
>> ERROR: application of sizeof to pointer
>>
>>   sizeof when applied to a pointer typed expression gives the size of
>>   the pointer
>>
>> Generated by: scripts/coccinelle/misc/noderef.cocci
>>
>> CC: Giuseppe Cavallaro <peppe.cavallaro@st.com>
>> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
>> ---
>>
>>   stmmac_platform.c |    2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
>> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
>> @@ -112,7 +112,7 @@ static struct stmmac_axi *stmmac_axi_set
>>   	if (!np)
>>   		return NULL;
>>
>> -	axi = kzalloc(sizeof(axi), GFP_KERNEL);
>> +	axi = kzalloc(sizeof(*axi), GFP_KERNEL);
>>   	if (!axi)
>>   		return ERR_PTR(-ENOMEM);
>>
>>
> 
> 
> Thanks.
> You can add my Acked-by: Alexandre Torgue <alexandre.torgue@st.com>

Don't do this.

Automated tools look for Acked-by: tags in replies to patch postings
in a certain way, so you must provide you Acked-by: on the first
column of a line in order for it to be picked up properly by those
tools.

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

* Re: [PATCH] stmmac: fix noderef.cocci warnings
  2016-03-03  1:55 ` [PATCH] stmmac: fix noderef.cocci warnings kbuild test robot
  2016-03-04 12:45   ` Alexandre Torgue
@ 2016-03-07  3:46   ` David Miller
  1 sibling, 0 replies; 5+ messages in thread
From: David Miller @ 2016-03-07  3:46 UTC (permalink / raw)
  To: fengguang.wu
  Cc: peppe.cavallaro, kbuild-all, netdev, alexandre.torgue, linux-kernel

From: kbuild test robot <fengguang.wu@intel.com>
Date: Thu, 3 Mar 2016 09:55:19 +0800

> drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer
> 
>  sizeof when applied to a pointer typed expression gives the size of
>  the pointer
> 
> Generated by: scripts/coccinelle/misc/noderef.cocci
> 
> CC: Giuseppe Cavallaro <peppe.cavallaro@st.com>
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>

Applied, thanks.

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

end of thread, other threads:[~2016-03-07  3:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-03  1:55 [net-next:master 963/985] drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer kbuild test robot
2016-03-03  1:55 ` [PATCH] stmmac: fix noderef.cocci warnings kbuild test robot
2016-03-04 12:45   ` Alexandre Torgue
2016-03-04 21:32     ` David Miller
2016-03-07  3:46   ` David Miller

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.