Skip to content

Commit ddc4bbe

Browse files
micchiedavem330
authored andcommitted
sctp: fasthandoff with ASCONF at mobile-node
Fast retransmission after changing the last address with ASCONF negotiation Signed-off-by: Michio Honda <micchie@sfc.wide.ad.jp> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 8ce120f commit ddc4bbe

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

include/net/sctp/structs.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1085,6 +1085,7 @@ void sctp_transport_burst_reset(struct sctp_transport *);
10851085
unsigned long sctp_transport_timeout(struct sctp_transport *);
10861086
void sctp_transport_reset(struct sctp_transport *);
10871087
void sctp_transport_update_pmtu(struct sctp_transport *, u32);
1088+
void sctp_transport_immediate_rtx(struct sctp_transport *);
10881089

10891090

10901091
/* This is the structure we use to queue packets as they come into

net/sctp/sm_make_chunk.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3400,8 +3400,10 @@ int sctp_process_asconf_ack(struct sctp_association *asoc,
34003400
asconf_len -= length;
34013401
}
34023402

3403-
if (no_err && asoc->src_out_of_asoc_ok)
3403+
if (no_err && asoc->src_out_of_asoc_ok) {
34043404
asoc->src_out_of_asoc_ok = 0;
3405+
sctp_transport_immediate_rtx(asoc->peer.primary_path);
3406+
}
34053407

34063408
/* Free the cached last sent asconf chunk. */
34073409
list_del_init(&asconf->transmitted_list);

net/sctp/transport.c

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -641,3 +641,19 @@ void sctp_transport_reset(struct sctp_transport *t)
641641
t->cacc.next_tsn_at_change = 0;
642642
t->cacc.cacc_saw_newack = 0;
643643
}
644+
645+
/* Schedule retransmission on the given transport */
646+
void sctp_transport_immediate_rtx(struct sctp_transport *t)
647+
{
648+
/* Stop pending T3_rtx_timer */
649+
if (timer_pending(&t->T3_rtx_timer)) {
650+
(void)del_timer(&t->T3_rtx_timer);
651+
sctp_transport_put(t);
652+
}
653+
sctp_retransmit(&t->asoc->outqueue, t, SCTP_RTXR_T3_RTX);
654+
if (!timer_pending(&t->T3_rtx_timer)) {
655+
if (!mod_timer(&t->T3_rtx_timer, jiffies + t->rto))
656+
sctp_transport_hold(t);
657+
}
658+
return;
659+
}

0 commit comments

Comments
 (0)