diff options
Diffstat (limited to 'net/dccp/ccids/ccid2.c')
| -rw-r--r-- | net/dccp/ccids/ccid2.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/net/dccp/ccids/ccid2.c b/net/dccp/ccids/ccid2.c index 2efb505aeb35..162032baeac0 100644 --- a/net/dccp/ccids/ccid2.c +++ b/net/dccp/ccids/ccid2.c | |||
| @@ -23,7 +23,7 @@ | |||
| 23 | */ | 23 | */ |
| 24 | 24 | ||
| 25 | /* | 25 | /* |
| 26 | * This implementation should follow: draft-ietf-dccp-ccid2-10.txt | 26 | * This implementation should follow RFC 4341 |
| 27 | * | 27 | * |
| 28 | * BUGS: | 28 | * BUGS: |
| 29 | * - sequence number wrapping | 29 | * - sequence number wrapping |
| @@ -352,14 +352,14 @@ static void ccid2_hc_tx_packet_sent(struct sock *sk, int more, int len) | |||
| 352 | 352 | ||
| 353 | #ifdef CONFIG_IP_DCCP_CCID2_DEBUG | 353 | #ifdef CONFIG_IP_DCCP_CCID2_DEBUG |
| 354 | ccid2_pr_debug("pipe=%d\n", hctx->ccid2hctx_pipe); | 354 | ccid2_pr_debug("pipe=%d\n", hctx->ccid2hctx_pipe); |
| 355 | ccid2_pr_debug("Sent: seq=%llu\n", seq); | 355 | ccid2_pr_debug("Sent: seq=%llu\n", (unsigned long long)seq); |
| 356 | do { | 356 | do { |
| 357 | struct ccid2_seq *seqp = hctx->ccid2hctx_seqt; | 357 | struct ccid2_seq *seqp = hctx->ccid2hctx_seqt; |
| 358 | 358 | ||
| 359 | while (seqp != hctx->ccid2hctx_seqh) { | 359 | while (seqp != hctx->ccid2hctx_seqh) { |
| 360 | ccid2_pr_debug("out seq=%llu acked=%d time=%lu\n", | 360 | ccid2_pr_debug("out seq=%llu acked=%d time=%lu\n", |
| 361 | seqp->ccid2s_seq, seqp->ccid2s_acked, | 361 | (unsigned long long)seqp->ccid2s_seq, |
| 362 | seqp->ccid2s_sent); | 362 | seqp->ccid2s_acked, seqp->ccid2s_sent); |
| 363 | seqp = seqp->ccid2s_next; | 363 | seqp = seqp->ccid2s_next; |
| 364 | } | 364 | } |
| 365 | } while (0); | 365 | } while (0); |
| @@ -480,7 +480,8 @@ static inline void ccid2_new_ack(struct sock *sk, | |||
| 480 | /* first measurement */ | 480 | /* first measurement */ |
| 481 | if (hctx->ccid2hctx_srtt == -1) { | 481 | if (hctx->ccid2hctx_srtt == -1) { |
| 482 | ccid2_pr_debug("R: %lu Time=%lu seq=%llu\n", | 482 | ccid2_pr_debug("R: %lu Time=%lu seq=%llu\n", |
| 483 | r, jiffies, seqp->ccid2s_seq); | 483 | r, jiffies, |
| 484 | (unsigned long long)seqp->ccid2s_seq); | ||
| 484 | ccid2_change_srtt(hctx, r); | 485 | ccid2_change_srtt(hctx, r); |
| 485 | hctx->ccid2hctx_rttvar = r >> 1; | 486 | hctx->ccid2hctx_rttvar = r >> 1; |
| 486 | } else { | 487 | } else { |
| @@ -636,8 +637,9 @@ static void ccid2_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb) | |||
| 636 | u64 ackno_end_rl; | 637 | u64 ackno_end_rl; |
| 637 | 638 | ||
| 638 | dccp_set_seqno(&ackno_end_rl, ackno - rl); | 639 | dccp_set_seqno(&ackno_end_rl, ackno - rl); |
| 639 | ccid2_pr_debug("ackvec start:%llu end:%llu\n", ackno, | 640 | ccid2_pr_debug("ackvec start:%llu end:%llu\n", |
| 640 | ackno_end_rl); | 641 | (unsigned long long)ackno, |
| 642 | (unsigned long long)ackno_end_rl); | ||
| 641 | /* if the seqno we are analyzing is larger than the | 643 | /* if the seqno we are analyzing is larger than the |
| 642 | * current ackno, then move towards the tail of our | 644 | * current ackno, then move towards the tail of our |
| 643 | * seqnos. | 645 | * seqnos. |
| @@ -672,7 +674,7 @@ static void ccid2_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb) | |||
| 672 | 674 | ||
| 673 | seqp->ccid2s_acked = 1; | 675 | seqp->ccid2s_acked = 1; |
| 674 | ccid2_pr_debug("Got ack for %llu\n", | 676 | ccid2_pr_debug("Got ack for %llu\n", |
| 675 | seqp->ccid2s_seq); | 677 | (unsigned long long)seqp->ccid2s_seq); |
| 676 | ccid2_hc_tx_dec_pipe(sk); | 678 | ccid2_hc_tx_dec_pipe(sk); |
| 677 | } | 679 | } |
| 678 | if (seqp == hctx->ccid2hctx_seqt) { | 680 | if (seqp == hctx->ccid2hctx_seqt) { |
| @@ -718,7 +720,7 @@ static void ccid2_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb) | |||
| 718 | while (1) { | 720 | while (1) { |
| 719 | if (!seqp->ccid2s_acked) { | 721 | if (!seqp->ccid2s_acked) { |
| 720 | ccid2_pr_debug("Packet lost: %llu\n", | 722 | ccid2_pr_debug("Packet lost: %llu\n", |
| 721 | seqp->ccid2s_seq); | 723 | (unsigned long long)seqp->ccid2s_seq); |
| 722 | /* XXX need to traverse from tail -> head in | 724 | /* XXX need to traverse from tail -> head in |
| 723 | * order to detect multiple congestion events in | 725 | * order to detect multiple congestion events in |
| 724 | * one ack vector. | 726 | * one ack vector. |
