diff options
author | Eric Dumazet <edumazet@google.com> | 2017-10-27 10:47:31 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-28 06:24:39 -0400 |
commit | 23a7102a2d1068508fa2a0ce593a0df7f8fdc0ac (patch) | |
tree | 1c3eeee74cbc15facccc2d1c11472490785e198a /net/ipv4/tcp_input.c | |
parent | 4170ba6b589ced82da56c7e4f71cc84b2be036d6 (diff) |
tcp: Namespace-ify sysctl_tcp_pacing_ss_ratio
Also remove an obsolete comment about TCP pacing.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_input.c')
-rw-r--r-- | net/ipv4/tcp_input.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index db4d458d0205..29539d39e61a 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -767,13 +767,6 @@ static void tcp_rtt_estimator(struct sock *sk, long mrtt_us) | |||
767 | tp->srtt_us = max(1U, srtt); | 767 | tp->srtt_us = max(1U, srtt); |
768 | } | 768 | } |
769 | 769 | ||
770 | /* Set the sk_pacing_rate to allow proper sizing of TSO packets. | ||
771 | * Note: TCP stack does not yet implement pacing. | ||
772 | * FQ packet scheduler can be used to implement cheap but effective | ||
773 | * TCP pacing, to smooth the burst on large writes when packets | ||
774 | * in flight is significantly lower than cwnd (or rwin) | ||
775 | */ | ||
776 | int sysctl_tcp_pacing_ss_ratio __read_mostly = 200; | ||
777 | int sysctl_tcp_pacing_ca_ratio __read_mostly = 120; | 770 | int sysctl_tcp_pacing_ca_ratio __read_mostly = 120; |
778 | 771 | ||
779 | static void tcp_update_pacing_rate(struct sock *sk) | 772 | static void tcp_update_pacing_rate(struct sock *sk) |
@@ -793,7 +786,7 @@ static void tcp_update_pacing_rate(struct sock *sk) | |||
793 | * end of slow start and should slow down. | 786 | * end of slow start and should slow down. |
794 | */ | 787 | */ |
795 | if (tp->snd_cwnd < tp->snd_ssthresh / 2) | 788 | if (tp->snd_cwnd < tp->snd_ssthresh / 2) |
796 | rate *= sysctl_tcp_pacing_ss_ratio; | 789 | rate *= sock_net(sk)->ipv4.sysctl_tcp_pacing_ss_ratio; |
797 | else | 790 | else |
798 | rate *= sysctl_tcp_pacing_ca_ratio; | 791 | rate *= sysctl_tcp_pacing_ca_ratio; |
799 | 792 | ||