linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] page_pool: remove unnecessary variable init
@ 2019-08-15 12:41 Yunsheng Lin
  2019-08-15 14:56 ` Jesper Dangaard Brouer
  2019-08-15 18:50 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Yunsheng Lin @ 2019-08-15 12:41 UTC (permalink / raw)
  To: hawk, ilias.apalodimas, davem; +Cc: netdev, linux-kernel

Remove variable initializations in functions that
are followed by assignments before use

Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>
---
 net/core/page_pool.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/core/page_pool.c b/net/core/page_pool.c
index 3272dc7..31187ff 100644
--- a/net/core/page_pool.c
+++ b/net/core/page_pool.c
@@ -61,7 +61,7 @@ static int page_pool_init(struct page_pool *pool,
 struct page_pool *page_pool_create(const struct page_pool_params *params)
 {
 	struct page_pool *pool;
-	int err = 0;
+	int err;
 
 	pool = kzalloc_node(sizeof(*pool), GFP_KERNEL, params->nid);
 	if (!pool)
-- 
2.8.1


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

* Re: [PATCH net-next] page_pool: remove unnecessary variable init
  2019-08-15 12:41 [PATCH net-next] page_pool: remove unnecessary variable init Yunsheng Lin
@ 2019-08-15 14:56 ` Jesper Dangaard Brouer
  2019-08-15 18:50 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: Jesper Dangaard Brouer @ 2019-08-15 14:56 UTC (permalink / raw)
  To: Yunsheng Lin; +Cc: brouer, hawk, ilias.apalodimas, davem, netdev, linux-kernel

On Thu, 15 Aug 2019 20:41:00 +0800
Yunsheng Lin <linyunsheng@huawei.com> wrote:

> Remove variable initializations in functions that
> are followed by assignments before use
> 
> Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>

Acked-by: Jesper Dangaard Brouer <brouer@redhat.com>

-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Principal Kernel Engineer at Red Hat
  LinkedIn: http://www.linkedin.com/in/brouer

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

* Re: [PATCH net-next] page_pool: remove unnecessary variable init
  2019-08-15 12:41 [PATCH net-next] page_pool: remove unnecessary variable init Yunsheng Lin
  2019-08-15 14:56 ` Jesper Dangaard Brouer
@ 2019-08-15 18:50 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2019-08-15 18:50 UTC (permalink / raw)
  To: linyunsheng; +Cc: hawk, ilias.apalodimas, netdev, linux-kernel

From: Yunsheng Lin <linyunsheng@huawei.com>
Date: Thu, 15 Aug 2019 20:41:00 +0800

> Remove variable initializations in functions that
> are followed by assignments before use
> 
> Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>

Applied.

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

end of thread, other threads:[~2019-08-15 18:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-15 12:41 [PATCH net-next] page_pool: remove unnecessary variable init Yunsheng Lin
2019-08-15 14:56 ` Jesper Dangaard Brouer
2019-08-15 18:50 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).