Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 78196
b: refs/heads/master
c: df054e1
h: refs/heads/master
v: v3
  • Loading branch information
Gerrit Renker authored and David S. Miller committed Jan 28, 2008
1 parent 40b3b72 commit 83045c1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cfbbeabc8864902c4af1c0cadf0972b352930a26
refs/heads/master: df054e1d00fdafa2e2920319df326ddb3f0d0413
9 changes: 5 additions & 4 deletions trunk/net/dccp/ccids/ccid2.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ static int ccid2_hc_tx_send_packet(struct sock *sk, struct sk_buff *skb)
return 1; /* XXX CCID should dequeue when ready instead of polling */
}

static void ccid2_change_l_ack_ratio(struct sock *sk, int val)
static void ccid2_change_l_ack_ratio(struct sock *sk, u32 val)
{
struct dccp_sock *dp = dccp_sk(sk);
/*
Expand All @@ -159,9 +159,10 @@ static void ccid2_change_l_ack_ratio(struct sock *sk, int val)
if (val > max)
val = max;
}
if (val > 0xFFFF) /* RFC 4340, 11.3 */
val = 0xFFFF;

ccid2_pr_debug("changing local ack ratio to %d\n", val);
WARN_ON(val <= 0);
ccid2_pr_debug("changing local ack ratio to %u\n", val);
dp->dccps_l_ack_ratio = val;
}

Expand Down Expand Up @@ -572,7 +573,7 @@ static void ccid2_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb)
hctx->ccid2hctx_rpdupack = -1; /* XXX lame */
hctx->ccid2hctx_rpseq = 0;

ccid2_change_l_ack_ratio(sk, dp->dccps_l_ack_ratio << 1);
ccid2_change_l_ack_ratio(sk, 2 * dp->dccps_l_ack_ratio);
}
}
}
Expand Down

0 comments on commit 83045c1

Please sign in to comment.