[PATCH 1/1] RDMA/rxe: Remove the unused variable

From
<hidden>
Date
2021-12-15 13:24:58
From: Zhu Yanjun <redacted>

The member variable xmit_errors can be replaced with
rxe_counter_inc(rxe, RXE_CNT_SEND_ERR) totally. So
remove it.

Signed-off-by: Zhu Yanjun <redacted>
---
 drivers/infiniband/sw/rxe/rxe_net.c   | 1 -
 drivers/infiniband/sw/rxe/rxe_verbs.h | 2 --
 2 files changed, 3 deletions(-)
diff --git a/drivers/infiniband/sw/rxe/rxe_net.c b/drivers/infiniband/sw/rxe/rxe_net.c
index 2cb810cb890a..112506c31b37 100644
--- a/drivers/infiniband/sw/rxe/rxe_net.c
+++ b/drivers/infiniband/sw/rxe/rxe_net.c
@@ -444,7 +444,6 @@ int rxe_xmit_packet(struct rxe_qp *qp, struct rxe_pkt_info *pkt,
 	else
 		err = rxe_send(skb, pkt);
 	if (err) {
-		rxe->xmit_errors++;
 		rxe_counter_inc(rxe, RXE_CNT_SEND_ERR);
 		return err;
 	}
diff --git a/drivers/infiniband/sw/rxe/rxe_verbs.h b/drivers/infiniband/sw/rxe/rxe_verbs.h
index 35e041450090..af0117710175 100644
--- a/drivers/infiniband/sw/rxe/rxe_verbs.h
+++ b/drivers/infiniband/sw/rxe/rxe_verbs.h
@@ -392,8 +392,6 @@ struct rxe_dev {
 
 	struct net_device	*ndev;
 
-	int			xmit_errors;
-
 	struct rxe_pool		uc_pool;
 	struct rxe_pool		pd_pool;
 	struct rxe_pool		ah_pool;
-- 
2.27.0
Thread (3 messages) 3 messages, 3 authors, last reply 2022-01-05
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help