All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] net: ibm: remove redundant local variables 'act_nr_of_entries' and 'act_pages'
@ 2018-09-19 14:30 zhong jiang
  2018-09-20  4:26 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: zhong jiang @ 2018-09-19 14:30 UTC (permalink / raw)
  To: davem; +Cc: dougmill, netdev, linux-kernel

That local variable are never used after being assigned.
hence it should be redundant and can be removed.

Signed-off-by: zhong jiang <zhongjiang@huawei.com>
---
 drivers/net/ethernet/ibm/ehea/ehea_qmr.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/ibm/ehea/ehea_qmr.c b/drivers/net/ethernet/ibm/ehea/ehea_qmr.c
index a0820f7..5e4e371 100644
--- a/drivers/net/ethernet/ibm/ehea/ehea_qmr.c
+++ b/drivers/net/ethernet/ibm/ehea/ehea_qmr.c
@@ -125,7 +125,7 @@ struct ehea_cq *ehea_create_cq(struct ehea_adapter *adapter,
 	struct ehea_cq *cq;
 	struct h_epa epa;
 	u64 *cq_handle_ref, hret, rpage;
-	u32 act_nr_of_entries, act_pages, counter;
+	u32 counter;
 	int ret;
 	void *vpage;
 
@@ -140,8 +140,6 @@ struct ehea_cq *ehea_create_cq(struct ehea_adapter *adapter,
 	cq->adapter = adapter;
 
 	cq_handle_ref = &cq->fw_handle;
-	act_nr_of_entries = 0;
-	act_pages = 0;
 
 	hret = ehea_h_alloc_resource_cq(adapter->handle, &cq->attr,
 					&cq->fw_handle, &cq->epas);
-- 
1.7.12.4


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

* Re: [PATCH] net: ibm: remove redundant local variables 'act_nr_of_entries' and 'act_pages'
  2018-09-19 14:30 [PATCH] net: ibm: remove redundant local variables 'act_nr_of_entries' and 'act_pages' zhong jiang
@ 2018-09-20  4:26 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2018-09-20  4:26 UTC (permalink / raw)
  To: zhongjiang; +Cc: dougmill, netdev, linux-kernel

From: zhong jiang <zhongjiang@huawei.com>
Date: Wed, 19 Sep 2018 22:30:49 +0800

> That local variable are never used after being assigned.
> hence it should be redundant and can be removed.
> 
> Signed-off-by: zhong jiang <zhongjiang@huawei.com>

Applied.

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

end of thread, other threads:[~2018-09-20  4:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-19 14:30 [PATCH] net: ibm: remove redundant local variables 'act_nr_of_entries' and 'act_pages' zhong jiang
2018-09-20  4:26 ` 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.