Skip to content

Commit aa5d7df

Browse files
Arnaldo Carvalho de Melodavem330
authored andcommitted
[DCCP] CCID3: Set the no_feedback_timer fields near init_timer
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 9833d6d commit aa5d7df

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

net/dccp/ccids/ccid3.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -307,8 +307,6 @@ static int ccid3_hc_tx_send_packet(struct sock *sk,
307307

308308
switch (hctx->ccid3hctx_state) {
309309
case TFRC_SSTATE_NO_SENT:
310-
hctx->ccid3hctx_no_feedback_timer.function = ccid3_hc_tx_no_feedback_timer;
311-
hctx->ccid3hctx_no_feedback_timer.data = (unsigned long)sk;
312310
sk_reset_timer(sk, &hctx->ccid3hctx_no_feedback_timer,
313311
jiffies + usecs_to_jiffies(TFRC_INITIAL_TIMEOUT));
314312
hctx->ccid3hctx_last_win_count = 0;
@@ -672,6 +670,9 @@ static int ccid3_hc_tx_init(struct sock *sk)
672670
hctx->ccid3hctx_t_rto = USEC_PER_SEC;
673671
hctx->ccid3hctx_state = TFRC_SSTATE_NO_SENT;
674672
INIT_LIST_HEAD(&hctx->ccid3hctx_hist);
673+
674+
hctx->ccid3hctx_no_feedback_timer.function = ccid3_hc_tx_no_feedback_timer;
675+
hctx->ccid3hctx_no_feedback_timer.data = (unsigned long)sk;
675676
init_timer(&hctx->ccid3hctx_no_feedback_timer);
676677

677678
return 0;

0 commit comments

Comments
 (0)