* [PATCH net-next] net: bcmgenet: return NULL instead of plain integer
@ 2018-03-28 12:51 Wei Yongjun
2018-03-28 16:24 ` Florian Fainelli
2018-03-29 18:36 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Wei Yongjun @ 2018-03-28 12:51 UTC (permalink / raw)
To: Doug Berger, Florian Fainelli; +Cc: Wei Yongjun, netdev, kernel-janitors
Fixes the following sparse warning:
drivers/net/ethernet/broadcom/genet/bcmgenet.c:1351:16: warning:
Using plain integer as NULL pointer
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/net/ethernet/broadcom/genet/bcmgenet.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/broadcom/genet/bcmgenet.c b/drivers/net/ethernet/broadcom/genet/bcmgenet.c
index 7db8edc..2f4cb5c 100644
--- a/drivers/net/ethernet/broadcom/genet/bcmgenet.c
+++ b/drivers/net/ethernet/broadcom/genet/bcmgenet.c
@@ -1348,7 +1348,7 @@ static struct sk_buff *bcmgenet_free_tx_cb(struct device *dev,
dma_unmap_addr_set(cb, dma_addr, 0);
}
- return 0;
+ return NULL;
}
/* Simple helper to free a receive control block's resources */
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] net: bcmgenet: return NULL instead of plain integer
2018-03-28 12:51 [PATCH net-next] net: bcmgenet: return NULL instead of plain integer Wei Yongjun
@ 2018-03-28 16:24 ` Florian Fainelli
2018-03-29 18:36 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Florian Fainelli @ 2018-03-28 16:24 UTC (permalink / raw)
To: Wei Yongjun, Doug Berger; +Cc: netdev, kernel-janitors
On March 28, 2018 5:51:19 AM PDT, Wei Yongjun <weiyongjun1@huawei.com> wrote:
>Fixes the following sparse warning:
>
>drivers/net/ethernet/broadcom/genet/bcmgenet.c:1351:16: warning:
> Using plain integer as NULL pointer
>
>Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
--
Florian
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] net: bcmgenet: return NULL instead of plain integer
2018-03-28 12:51 [PATCH net-next] net: bcmgenet: return NULL instead of plain integer Wei Yongjun
2018-03-28 16:24 ` Florian Fainelli
@ 2018-03-29 18:36 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2018-03-29 18:36 UTC (permalink / raw)
To: weiyongjun1; +Cc: opendmb, f.fainelli, netdev, kernel-janitors
From: Wei Yongjun <weiyongjun1@huawei.com>
Date: Wed, 28 Mar 2018 12:51:19 +0000
> Fixes the following sparse warning:
>
> drivers/net/ethernet/broadcom/genet/bcmgenet.c:1351:16: warning:
> Using plain integer as NULL pointer
>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Applied.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-03-29 18:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-28 12:51 [PATCH net-next] net: bcmgenet: return NULL instead of plain integer Wei Yongjun
2018-03-28 16:24 ` Florian Fainelli
2018-03-29 18:36 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox