Discussion of explicit congestion notification's impact on the Internet
 help / color / mirror / Atom feed
* [Ecn-sane] net-next dctcp mod question
@ 2019-08-05 18:21 Dave Taht
  2019-08-05 19:10 ` Jonathan Morton
  0 siblings, 1 reply; 4+ messages in thread
From: Dave Taht @ 2019-08-05 18:21 UTC (permalink / raw)
  To: ECN-Sane

The SCE tree had two key looking modifications to it that seem to have
been superceded by net-next.

My reading of the remaining differences seem to be resolved in the
state machine where setting the last portion
of the SCE patch appears to do a decrease on multiple losses. ? Can I
not forward port these?

--- a/net/ipv4/tcp_dctcp.c
+++ b/net/ipv4/tcp_dctcp.c
@@ -110,7 +110,7 @@ static u32 dctcp_ssthresh(struct sock *sk)

 static void dctcp_update_alpha(struct sock *sk, u32 flags)
 {
-       const struct tcp_sock *tp = tcp_sk(sk);
+       struct tcp_sock *tp = tcp_sk(sk);
        struct dctcp *ca = inet_csk_ca(sk);

        /* Expired RTT */
@@ -138,6 +138,7 @@ static void dctcp_update_alpha(struct sock *sk, u32 flags)
                 */
                WRITE_ONCE(ca->dctcp_alpha, alpha);
                dctcp_reset(tp, ca);
+               tp->snd_cwnd = dctcp_ssthresh(sk);
        }
 }

@@ -147,6 +148,7 @@ static void dctcp_react_to_loss(struct sock *sk)
        struct tcp_sock *tp = tcp_sk(sk);

        ca->loss_cwnd = tp->snd_cwnd;
+       tp->snd_cwnd = max(tp->snd_cwnd >> 1U, 2U);
        tp->snd_ssthresh = max(tp->snd_cwnd >> 1U, 2U);
 }



-- 

Dave Täht
CTO, TekLibre, LLC
http://www.teklibre.com
Tel: 1-831-205-9740

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-08-05 20:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-05 18:21 [Ecn-sane] net-next dctcp mod question Dave Taht
2019-08-05 19:10 ` Jonathan Morton
2019-08-05 19:53   ` Dave Taht
2019-08-05 20:00     ` Dave Taht

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox