DCCP protocol discussions
 help / color / mirror / Atom feed
* [PATCH 2/9] [CCID2]: Remove unused variable
@ 2007-11-03 12:04 Gerrit Renker
  2007-11-03 23:51 ` Ian McDonald
  0 siblings, 1 reply; 2+ messages in thread
From: Gerrit Renker @ 2007-11-03 12:04 UTC (permalink / raw)
  To: dccp

This removes a variable `ccid2hctx_sent' which is incremented but
never referenced/read (i.e., dead code).

Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
---
 net/dccp/ccids/ccid2.c |    4 ----
 net/dccp/ccids/ccid2.h |    2 --
 2 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/net/dccp/ccids/ccid2.c b/net/dccp/ccids/ccid2.c
index 683d4c2..722d481 100644
--- a/net/dccp/ccids/ccid2.c
+++ b/net/dccp/ccids/ccid2.c
@@ -221,7 +221,6 @@ static void ccid2_hc_tx_rto_expire(unsigned long data)
 	hctx->ccid2hctx_seqt	= hctx->ccid2hctx_seqh;
 	hctx->ccid2hctx_ssacks	= 0;
 	hctx->ccid2hctx_acks	= 0;
-	hctx->ccid2hctx_sent	= 0;
 
 	/* clear ack ratio state. */
 	hctx->ccid2hctx_rpseq	 = 0;
@@ -285,8 +284,6 @@ static void ccid2_hc_tx_packet_sent(struct sock *sk, int more, unsigned int len)
 	ccid2_pr_debug("cwnd=%d pipe=%d\n", hctx->ccid2hctx_cwnd,
 		       hctx->ccid2hctx_pipe);
 
-	hctx->ccid2hctx_sent++;
-
 	/*
 	 * FIXME: The code below is broken and the variables have been removed
 	 * from the socket struct. The `ackloss' variable was always set to 0,
@@ -517,7 +514,6 @@ static inline void ccid2_new_ack(struct sock *sk,
 		ccid2_pr_debug("srtt: %ld rttvar: %ld rto: %ld (HZ=%d) R=%lu\n",
 			       hctx->ccid2hctx_srtt, hctx->ccid2hctx_rttvar,
 			       hctx->ccid2hctx_rto, HZ, r);
-		hctx->ccid2hctx_sent = 0;
 	}
 
 	/* we got a new ack, so re-start RTO timer */
diff --git a/net/dccp/ccids/ccid2.h b/net/dccp/ccids/ccid2.h
index ed95f8f..6d0b4e3 100644
--- a/net/dccp/ccids/ccid2.h
+++ b/net/dccp/ccids/ccid2.h
@@ -42,7 +42,6 @@ struct ccid2_seq {
  *
  * @ccid2hctx_ssacks - ACKs recv in slow start
  * @ccid2hctx_acks - ACKS recv in AI phase
- * @ccid2hctx_sent - packets sent in this window
  * @ccid2hctx_lastrtt -time RTT was last measured
  * @ccid2hctx_rpseq - last consecutive seqno
  * @ccid2hctx_rpdupack - dupacks since rpseq
@@ -61,7 +60,6 @@ struct ccid2_hc_tx_sock {
 	long			ccid2hctx_rto;
 	long			ccid2hctx_srtt;
 	long			ccid2hctx_rttvar;
-	int			ccid2hctx_sent;
 	unsigned long		ccid2hctx_lastrtt;
 	struct timer_list	ccid2hctx_rtotimer;
 	u64			ccid2hctx_rpseq;
-- 
1.5.2.2.238.g7cbf2f2-dirty


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

* Re: [PATCH 2/9] [CCID2]: Remove unused variable
  2007-11-03 12:04 [PATCH 2/9] [CCID2]: Remove unused variable Gerrit Renker
@ 2007-11-03 23:51 ` Ian McDonald
  0 siblings, 0 replies; 2+ messages in thread
From: Ian McDonald @ 2007-11-03 23:51 UTC (permalink / raw)
  To: dccp

On 11/4/07, Gerrit Renker <gerrit@erg.abdn.ac.uk> wrote:
> This removes a variable `ccid2hctx_sent' which is incremented but
> never referenced/read (i.e., dead code).
>
> Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>

Signed-off-by: Ian McDonald <ian.mcdonald@jandi.co.nz>

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

end of thread, other threads:[~2007-11-03 23:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-03 12:04 [PATCH 2/9] [CCID2]: Remove unused variable Gerrit Renker
2007-11-03 23:51 ` Ian McDonald

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox