]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
dccp ccid-2: Use feature-negotiation to report Ack Ratio changes
authorGerrit Renker <gerrit@erg.abdn.ac.uk>
Thu, 4 Sep 2008 05:30:19 +0000 (07:30 +0200)
committerGerrit Renker <gerrit@erg.abdn.ac.uk>
Thu, 4 Sep 2008 05:45:32 +0000 (07:45 +0200)
This uses the new feature-negotiation framework to signal Ack Ratio changes,
as required by RFC 4341, sec. 6.1.2.

This raises some problems for CCID-2 since it can at the moment not cope
gracefully with Ack Ratio of e.g. 2. A FIXME has thus been added which
reverts to the existing policy of bypassing the Ack Ratio sysctl.

Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Acked-by: Ian McDonald <ian.mcdonald@jandi.co.nz>
net/dccp/feat.c
net/dccp/proto.c

index c847c80d1b97e1f9865c4a1e3a54f4869b35dc99..f94c7c9d1a7f0d81aa443d887e0e4252eed32116 100644 (file)
@@ -74,6 +74,18 @@ static int dccp_hdlr_seq_win(struct sock *sk, u64 seq_win, bool rx)
 
 static int dccp_hdlr_ack_ratio(struct sock *sk, u64 ratio, bool rx)
 {
+#ifndef __CCID2_COPES_GRACEFULLY_WITH_DYNAMIC_ACK_RATIO_UPDATES__
+       /*
+        * FIXME: This is required until several problems in the CCID-2 code are
+        * resolved. The CCID-2 code currently does not cope well; using dynamic
+        * Ack Ratios greater than 1 caused instabilities. These were manifest
+        * in hangups and long RTO timeouts (1...3 seconds). Until this has been
+        * stabilised, it is safer not to activate dynamic Ack Ratio changes.
+        */
+       dccp_pr_debug("Not changing %s Ack Ratio from 1 to %u\n",
+                     rx ? "RX" : "TX", (u16)ratio);
+       ratio = 1;
+#endif
        if (rx)
                dccp_sk(sk)->dccps_r_ack_ratio = ratio;
        else
index 392a5d822b3310c2d2dea20eaadcc15e274cf4b9..11905e0cf8f7ee3f126c6e946ff4d176796350f7 100644 (file)
@@ -189,7 +189,6 @@ int dccp_init_sock(struct sock *sk, const __u8 ctl_sock_initialized)
        dp->dccps_rate_last     = jiffies;
        dp->dccps_role          = DCCP_ROLE_UNDEFINED;
        dp->dccps_service       = DCCP_SERVICE_CODE_IS_ABSENT;
-       dp->dccps_l_ack_ratio   = dp->dccps_r_ack_ratio = 1;
 
        dccp_init_xmit_timers(sk);