diff options
Diffstat (limited to 'net/dccp/ccids/ccid2.c')
-rw-r--r-- | net/dccp/ccids/ccid2.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/net/dccp/ccids/ccid2.c b/net/dccp/ccids/ccid2.c index e96d5e810039..fadecd20d75b 100644 --- a/net/dccp/ccids/ccid2.c +++ b/net/dccp/ccids/ccid2.c | |||
@@ -583,6 +583,15 @@ done: | |||
583 | dccp_ackvec_parsed_cleanup(&hc->tx_av_chunks); | 583 | dccp_ackvec_parsed_cleanup(&hc->tx_av_chunks); |
584 | } | 584 | } |
585 | 585 | ||
586 | /* | ||
587 | * Convert RFC 3390 larger initial window into an equivalent number of packets. | ||
588 | * This is based on the numbers specified in RFC 5681, 3.1. | ||
589 | */ | ||
590 | static inline u32 rfc3390_bytes_to_packets(const u32 smss) | ||
591 | { | ||
592 | return smss <= 1095 ? 4 : (smss > 2190 ? 2 : 3); | ||
593 | } | ||
594 | |||
586 | static int ccid2_hc_tx_init(struct ccid *ccid, struct sock *sk) | 595 | static int ccid2_hc_tx_init(struct ccid *ccid, struct sock *sk) |
587 | { | 596 | { |
588 | struct ccid2_hc_tx_sock *hc = ccid_priv(ccid); | 597 | struct ccid2_hc_tx_sock *hc = ccid_priv(ccid); |