mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
sctp: add stream reconf timer
This patch is to add a per transport timer based on sctp timer frame for stream reconf chunk retransmission. It would start after sending a reconf request chunk, and stop after receiving the response chunk. If the timer expires, besides retransmitting the reconf request chunk, it would also do the same thing with data RTO timer. like to increase the appropriate error counts, and perform threshold management, possibly destroying the asoc if sctp retransmission thresholds are exceeded, just as section 5.1.1 describes. This patch is also to add asoc strreset_chunk, it is used to save the reconf request chunk, so that it can be retransmitted, and to check if the response is really for this request by comparing the information inside with the response chunk as well. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
cc16f00f65
commit
7b9438de0c
8 changed files with 113 additions and 2 deletions
|
@ -877,6 +877,9 @@ struct sctp_transport {
|
|||
/* Timer to handle ICMP proto unreachable envets */
|
||||
struct timer_list proto_unreach_timer;
|
||||
|
||||
/* Timer to handler reconf chunk rtx */
|
||||
struct timer_list reconf_timer;
|
||||
|
||||
/* Since we're using per-destination retransmission timers
|
||||
* (see above), we're also using per-destination "transmitted"
|
||||
* queues. This probably ought to be a private struct
|
||||
|
@ -935,6 +938,7 @@ void sctp_transport_pmtu(struct sctp_transport *, struct sock *sk);
|
|||
void sctp_transport_free(struct sctp_transport *);
|
||||
void sctp_transport_reset_t3_rtx(struct sctp_transport *);
|
||||
void sctp_transport_reset_hb_timer(struct sctp_transport *);
|
||||
void sctp_transport_reset_reconf_timer(struct sctp_transport *transport);
|
||||
int sctp_transport_hold(struct sctp_transport *);
|
||||
void sctp_transport_put(struct sctp_transport *);
|
||||
void sctp_transport_update_rto(struct sctp_transport *, __u32);
|
||||
|
@ -1868,6 +1872,8 @@ struct sctp_association {
|
|||
__u32 strreset_outseq; /* Update after receiving response */
|
||||
__u32 strreset_inseq; /* Update after receiving request */
|
||||
|
||||
struct sctp_chunk *strreset_chunk; /* save request chunk */
|
||||
|
||||
struct sctp_priv_assoc_stats stats;
|
||||
|
||||
int sent_cnt_removable;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue