[PATCH v2 net-next 14/16] tcp: new CC hook to set sending rate with rate_sample in any CA state

2016-09-17 Thread Neal Cardwell
n Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/net/tcp.h| 4 net/ipv4/tcp_cong.c | 2 +- net/ipv4/tcp_input.c | 17 ++--- 3 files c

[PATCH v2 net-next 05/16] tcp: switch back to proper tcp_skb_cb size check in tcp_init()

2016-09-17 Thread Neal Cardwell
older form of the tcp_skb_cb size check. Doing so allows TCP to use 4 more bytes of the skb->cb[] space. Fixes: b4772ef879a8 ("net: use common macro for assering skb->cb[] available size in protocol families") Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yega

[PATCH v2 net-next 07/16] tcp: track data delivery rate for a TCP connection

2016-09-17 Thread Neal Cardwell
end_phase_rtt, ack_phase_rtt) In large-scale experiments, this filtering approach incorporating send_phase_rtt is effective at avoiding bandwidth overestimates due to ACK compression or stretched ACKs. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-o

[PATCH v2 net-next 04/16] net_sched: sch_fq: add low_rate_threshold parameter

2016-09-17 Thread Neal Cardwell
-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/uapi/linux/pkt_sched.h | 2 ++ net/sched/sch_fq.c | 22 +++--- 2 files

[PATCH v2 net-next 03/16] tcp: use windowed min filter library for TCP min_rtt estimation

2016-09-17 Thread Neal Cardwell
use the windowed min/max filter code. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/linux/tcp.h | 5 ++-- include/net/tcp.h| 2

[PATCH v2 net-next 15/16] tcp: increase ICSK_CA_PRIV_SIZE from 64 bytes to 88

2016-09-17 Thread Neal Cardwell
The TCP CUBIC module already uses 64 bytes. The upcoming TCP BBR module uses 88 bytes. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/net

[PATCH v2 net-next 12/16] tcp: export tcp_mss_to_mtu() for congestion control modules

2016-09-17 Thread Neal Cardwell
Export tcp_mss_to_mtu(), so that congestion control modules can use this to help calculate a pacing rate. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh

[PATCH v2 net-next 02/16] lib/win_minmax: windowed min or max estimator

2016-09-17 Thread Neal Cardwell
increasing or decreasing. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/linux/win_minmax.h | 37 + lib/Makefile | 2

[PATCH v2 net-next 13/16] tcp: allow congestion control to expand send buffer differently

2016-09-17 Thread Neal Cardwell
expand the TCP send buffer. For congestion control modules that do not specificy this callback, TCP continues to use the previous default of 2. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet

[PATCH v2 net-next 09/16] tcp: export data delivery rate

2016-09-17 Thread Neal Cardwell
l for applications that want to know the current throughput the TCP connection is seeing, e.g. adaptive bitrate video streaming. It can also be very useful for debugging or troubleshooting. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukk

[PATCH v2 net-next 06/16] tcp: count packets marked lost for a TCP connection

2016-09-17 Thread Neal Cardwell
losses when a policer kicks in. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/linux/tcp.h | 1 + net/ipv4/tcp_input.c | 25

[PATCH v2 net-next 08/16] tcp: track application-limited rate samples

2016-09-17 Thread Neal Cardwell
max receive window offered by the TCP protocol is 2^(16+14) = 2^30. So we only need 30 bits for the tx.in_flight used by NV. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Has

[PATCH v2 net-next 11/16] tcp: export tcp_tso_autosize() and parameterize minimum number of TSO segments

2016-09-17 Thread Neal Cardwell
per TSO skb, in case the congestion control module has a different notion of the best floor for TSO skbs for the connection right now. For very low-rate paths or policed connections it can be appropriate to use smaller TSO skbs. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell

[PATCH v2 net-next 16/16] tcp_bbr: add BBR congestion control

2016-09-17 Thread Neal Cardwell
further research. Test results, performance evaluations, feedback, and BBR-related discussions are very welcome in the public e-mail list for BBR: https://groups.google.com/forum/#!forum/bbr-dev Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: N

[PATCH v2 net-next 01/16] tcp: cdg: rename struct minmax in tcp_cdg.c to avoid a naming conflict

2016-09-17 Thread Neal Cardwell
This would create a compilation error for tcp_cdg.c, which defines its own minmax struct. To avoid this naming conflict (and potentially others in the future), this commit renames the version used in tcp_cdg.c to cdg_minmax. Signed-off-by: Soheil Hassas Yeganeh Signed-off-by: Neal Cardwell Signed-o

[PATCH v2 net-next 00/16] tcp: BBR congestion control algorithm

2016-09-17 Thread Neal Cardwell
tcp_skb_cb size check in tcp_init() Eric Dumazet (2): net_sched: sch_fq: add low_rate_threshold parameter tcp: switch back to proper tcp_skb_cb size check in tcp_init() Neal Cardwell (8): lib/win_minmax: windowed min or max estimator tcp: use windowed min filter library for TCP min_rtt estima

Re: [PATCH net-next 05/14] tcp: track data delivery rate for a TCP connection

2016-09-17 Thread Neal Cardwell
On Fri, Sep 16, 2016 at 5:38 PM, kbuild test robot wrote: > Hi Yuchung, > > [auto build test WARNING on net-next/master] > All warnings (new ones prefixed by >>): > >In file included from net/ipv4/route.c:103:0: >>> include/net/tcp.h:769:11: warning: 'packed' attribute ignored for field of >>

Re: [PATCH net-next 07/14] tcp: export data delivery rate

2016-09-16 Thread Neal Cardwell
On Fri, Sep 16, 2016 at 11:56 PM, kbuild test robot wrote: > >>> net/ipv4/tcp.c:2794:3: note: in expansion of macro 'do_div' > do_div(rate, intv); > ^~ >In file included from arch/arm/include/asm/div64.h:126:0, > from include/linux/kernel.h:142, >

Re: [PATCH net-next 02/14] tcp: use windowed min filter library for TCP min_rtt estimation

2016-09-16 Thread Neal Cardwell
On Fri, Sep 16, 2016 at 3:21 PM, kbuild test robot wrote: > All errors (new ones prefixed by >>): > >>> net/ipv4/tcp_cdg.c:59:8: error: redefinition of 'struct minmax' > struct minmax { >^~ >In file included from include/linux/tcp.h:22:0, > from include/

[PATCH net-next 13/14] tcp: increase ICSK_CA_PRIV_SIZE from 64 bytes to 88

2016-09-16 Thread Neal Cardwell
The TCP CUBIC module already uses 64 bytes. The upcoming TCP BBR module uses 88 bytes. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/net

[PATCH net-next 09/14] tcp: export tcp_tso_autosize() and parameterize minimum number of TSO segments

2016-09-16 Thread Neal Cardwell
per TSO skb, in case the congestion control module has a different notion of the best floor for TSO skbs for the connection right now. For very low-rate paths or policed connections it can be appropriate to use smaller TSO skbs. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell

[PATCH net-next 12/14] tcp: new CC hook to set sending rate with rate_sample in any CA state

2016-09-16 Thread Neal Cardwell
n Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/net/tcp.h| 4 net/ipv4/tcp_cong.c | 2 +- net/ipv4/tcp_input.c | 17 ++--- 3 files c

[PATCH net-next 06/14] tcp: track application-limited rate samples

2016-09-16 Thread Neal Cardwell
max receive window offered by the TCP protocol is 2^(16+14) = 2^30. So we only need 30 bits for the tx.in_flight used by NV. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Has

[PATCH net-next 05/14] tcp: track data delivery rate for a TCP connection

2016-09-16 Thread Neal Cardwell
end_phase_rtt, ack_phase_rtt) In large-scale experiments, this filtering approach incorporating send_phase_rtt is effective at avoiding bandwidth overestimates due to ACK compression or stretched ACKs. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-o

[PATCH net-next 03/14] net_sched: sch_fq: add low_rate_threshold parameter

2016-09-16 Thread Neal Cardwell
-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/uapi/linux/pkt_sched.h | 2 ++ net/sched/sch_fq.c | 22 +++--- 2 files

[PATCH net-next 14/14] tcp_bbr: add BBR congestion control

2016-09-16 Thread Neal Cardwell
further research. Test results, performance evaluations, feedback, and BBR-related discussions are very welcome in the public e-mail list for BBR: https://groups.google.com/forum/#!forum/bbr-dev Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: N

[PATCH net-next 08/14] tcp: allow congestion control module to request TSO skb segment count

2016-09-16 Thread Neal Cardwell
d-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/net/tcp.h | 2 ++ net/ipv4/tcp_output.c | 15 +-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/in

[PATCH net-next 07/14] tcp: export data delivery rate

2016-09-16 Thread Neal Cardwell
l for applications that want to know the current throughput the TCP connection is seeing, e.g. adaptive bitrate video streaming. It can also be very useful for debugging or troubleshooting. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukk

[PATCH net-next 04/14] tcp: count packets marked lost for a TCP connection

2016-09-16 Thread Neal Cardwell
losses when a policer kicks in. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/linux/tcp.h | 1 + net/ipv4/tcp_input.c | 25

[PATCH net-next 10/14] tcp: export tcp_mss_to_mtu() for congestion control modules

2016-09-16 Thread Neal Cardwell
Export tcp_mss_to_mtu(), so that congestion control modules can use this to help calculate a pacing rate. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh

[PATCH net-next 11/14] tcp: allow congestion control to expand send buffer differently

2016-09-16 Thread Neal Cardwell
expand the TCP send buffer. For congestion control modules that do not specificy this callback, TCP continues to use the previous default of 2. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet

[PATCH net-next 02/14] tcp: use windowed min filter library for TCP min_rtt estimation

2016-09-16 Thread Neal Cardwell
use the windowed min/max filter code. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/linux/tcp.h | 5 ++-- include/net/tcp.h| 2

[PATCH net-next 01/14] lib/win_minmax: windowed min or max estimator

2016-09-16 Thread Neal Cardwell
increasing or decreasing. Signed-off-by: Van Jacobson Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Nandita Dukkipati Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh --- include/linux/win_minmax.h | 37 + lib/Makefile | 2

[PATCH net-next 00/14] tcp: BBR congestion control algorithm

2016-09-16 Thread Neal Cardwell
Dumazet (1): net_sched: sch_fq: add low_rate_threshold parameter Neal Cardwell (8): lib/win_minmax: windowed min or max estimator tcp: use windowed min filter library for TCP min_rtt estimation tcp: count packets marked lost for a TCP connection tcp: allow congestion control module to r

Re: [PATCH] tcp: cwnd does not increase in TCP YeAH

2016-09-05 Thread Neal Cardwell
KB/s for single TCP > connection and kernel 4.3 and above (including 4.8-rc4) shows bandwidth > ~100KB/s. > That is caused by stalled cwnd when cwnd equals ssthresh. This patch > fixes it by proper increasing cwnd in this case. > > Signed-off-by: Artem Germanov Acked-by: Neal Cardwell neal

Re: [PATCH next] tcp: fastopen: fix rcv_wup initialization for TFO server on SYN/data

2016-08-30 Thread Neal Cardwell
Sorry, there's a typo in the subject line: that should be "net" rather than "next" (I'm proposing "net" since it's a bug fix). Looks like "git am" strips this mistake, but I'm happy to resubmit if it helps. thanks, neal

[PATCH next] tcp: fastopen: fix rcv_wup initialization for TFO server on SYN/data

2016-08-30 Thread Neal Cardwell
e it sends a SYN/ACK for the SYN/data. Reported-by: Yuchung Cheng Signed-off-by: Neal Cardwell Signed-off-by: Yuchung Cheng Signed-off-by: Eric Dumazet Signed-off-by: Soheil Hassas Yeganeh Fixes: 168a8f58059a ("tcp: TCP Fast Open Server - main code path") --- net/ipv4/tcp_fastopen.c |

Re: [PATCH net-next] tcp: add tcp_add_backlog()

2016-08-27 Thread Neal Cardwell
like collapsing > receive queues or partial ofo pruning. > > Signed-off-by: Eric Dumazet > Cc: Yuchung Cheng > Cc: Neal Cardwell > --- > include/net/tcp.h |1 + > net/ipv4/tcp_ipv4.c | 33 + > net/ipv6/tcp_ipv6.c |5 +

Re: [PATCH net-next] tcp: md5: increment sk_drops on syn_recv state

2016-08-24 Thread Neal Cardwell
increase the parent (listener) sk_drops. > > Signed-off-by: Eric Dumazet > --- Acked-by: Neal Cardwell Thanks, Eric! neal

Re: [PATCH net] tcp: properly scale window in tcp_v[46]_reqsk_send_ack()

2016-08-22 Thread Neal Cardwell
+0 < . 1:11(10) ack 1 win 156 > // check that window is properly scaled ! > +0 > . 1:1(0) ack 1 win 226 > > > Signed-off-by: Eric Dumazet > Cc: Yuchung Cheng > Cc: Neal Cardwell > --- Acked-by: Neal Cardwell Nice. neal

Re: [PATCH net-next] tcp: refine tcp_prune_ofo_queue() to not drop all packets

2016-08-18 Thread Neal Cardwell
ns only a part of the out of order queue in order > to meet the memory constraints. > > Signed-off-by: Eric Dumazet > Cc: Neal Cardwell > Cc: Yuchung Cheng > Cc: Soheil Hassas Yeganeh > Cc: C. Stephen Gun > Cc: Van Jacobson > --- Nice. Acked-by: Neal Cardwell neal

Re: [PATCH net-next] tcp: defer sacked assignment

2016-08-17 Thread Neal Cardwell
change in slow path, but why not ? ;) > > Signed-off-by: Eric Dumazet > --- Acked-by: Neal Cardwell neal

Re: [PATCH net] tcp: fix use after free in tcp_xmit_retransmit_queue()

2016-08-17 Thread Neal Cardwell
found by Marco Grassi thanks to syzkaller. > > Fixes: 6859d49475d4 ("[TCP]: Abstract tp->highest_sack accessing & point to > next skb") > Reported-by: Marco Grassi > Signed-off-by: Eric Dumazet > Cc: Ilpo Järvinen > Cc: Yuchung Cheng > Cc: Neal Cardwell Acked-by: Neal Cardwell Thanks, Eric. neal

Re: backport "tcp: fix tcp_mark_head_lost to check skb len before fragmenting" to 4.4-stable?

2016-08-02 Thread Neal Cardwell
_rcv+0x122/0x220 > [] tcp_v4_rcv+0x9a6/0xa80 > [] ip_local_deliver_finish+0x9a/0x200 > [] ip_local_deliver+0x64/0xd0 > [] ? ip_rcv_finish+0x350/0x350 > [] ip_rcv_finish+0x151/0x350 > > [...] > > This upstream patch seems to address this issue: > > commit d88270e

Re: [PATCH v2 net] tcp: consider recv buf for the initial window scale

2016-07-29 Thread Neal Cardwell
-off-by: Soheil Hassas Yeganeh > Suggested-by: Neal Cardwell Acked-by: Neal Cardwell Thanks, Soheil. neal

Re: [PATCH net] tcp: consider recv buf for the initial window scale

2016-07-29 Thread Neal Cardwell
_select_initial_window(). > > To fix this, consider the maximum of net.ipv4.tcp_rmem[2], > net.core.rmem_max and socket's initial buffer space. > > This part of the code does not have git history and as a > result this patch does not have a `Fixes:` tag. > > Signed-off-by: S

Re: [PATCH net] tcp: enable per-socket rate limiting of all 'challenge acks'

2016-07-15 Thread Neal Cardwell
-up to: > Subject: tcp: make challenge acks less predictable > > Cc: Eric Dumazet > Cc: David S. Miller > Cc: Neal Cardwell > Cc: Yuchung Cheng > Cc: Yue Cao > Signed-off-by: Jason Baron > --- > net/ipv4/tcp_input.c | 39 ++- > 1 file changed, 22 insertions(+), 17 deletions(-) Sounds good to me. Acked-by: Neal Cardwell thanks, neal

Re: [PATCH v2 net] tcp: make challenge acks less predictable

2016-07-10 Thread Neal Cardwell
-by: Eric Dumazet > Suggested-by: Linus Torvalds > Cc: Yuchung Cheng > Cc: Neal Cardwell Acked-by: Neal Cardwell Thanks, Eric! neal

Re: [PATCH net-next] tcp: increase size at which tcp_bound_to_half_wnd bounds to > TCP_MSS_DEFAULT

2016-06-28 Thread Neal Cardwell
On Tue, Jun 28, 2016 at 5:54 PM, Seymour, Shane M wrote: >> From: Eric Dumazet [mailto:eric.duma...@gmail.com] ... >> Anyway, your patch is reversed. > > I'm not sure what you mean by reversed, I didn't change the direction > of the test in the code just what it's being compared against and so > i

Re: [PATCH net] tcp: do not send too big packets at retransmit time

2016-06-27 Thread Neal Cardwell
Eric Dumazet > Reported-by: Arjun V > Tested-by: Arjun V > --- > net/ipv4/tcp_output.c | 7 ++- > 1 file changed, 6 insertions(+), 1 deletion(-) Acked-by: Neal Cardwell Thanks, Eric! neal

Re: [REGRESSION, bisect]cxgb4 port failure with TSO traffic after commit 10d3be569243def8("tcp-tso: do not split TSO packets at retransmit time")

2016-06-27 Thread Neal Cardwell
On Mon, Jun 27, 2016 at 9:27 AM, Eric Dumazet wrote: > Excellent idea ;) > > Here is the v2 patch. > > diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c > index 8bd9911fdd16..e00e972c4e6a 100644 > --- a/net/ipv4/tcp_output.c > +++ b/net/ipv4/tcp_output.c > @@ -2751,7 +2751,7 @@ void tcp_x

Re: [REGRESSION, bisect]cxgb4 port failure with TSO traffic after commit 10d3be569243def8("tcp-tso: do not split TSO packets at retransmit time")

2016-06-27 Thread Neal Cardwell
On Mon, Jun 27, 2016 at 8:46 AM, Eric Dumazet wrote: > Patch would be : > > diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c > index 8bd9911fdd16..3587efe22864 100644 > --- a/net/ipv4/tcp_output.c > +++ b/net/ipv4/tcp_output.c > @@ -2784,6 +2784,10 @@ void tcp_xmit_retransmit_queue(struc

[PATCH net-next] tcp: return sizeof tcp_dctcp_info in dctcp_get_info()

2016-06-13 Thread Neal Cardwell
uct tcp_dctcp_info, in which case the TCP_CC_INFO code might accidentally copy uninitialized bytes from the stack. Signed-off-by: Neal Cardwell Signed-off-by: Soheil Hassas Yeganeh Signed-off-by: Eric Dumazet --- net/ipv4/tcp_dctcp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/

Re: [PATCH net-next] tcp: accept RST if SEQ matches right edge of right-most SACK block

2016-06-07 Thread Neal Cardwell
der to avoid spoofing attacks. > >> Signed-off-by: Pau Espin Pedrol Acked-by: Neal Cardwell Tested-by: Neal Cardwell I verified that it passes the following packetdrill test, which is based on the script posted by Pau in a recent thread on this topic. Thanks! neal // Test that w

Re: [PATCH net-next] tcp: accept RST if SEQ matches right edge of right-most SACK block

2016-06-06 Thread Neal Cardwell
The functionality seems OK to me, though there are some style/formatting issues, which checkpatch.pl picks up: > ./scripts/checkpatch.pl > net-next-tcp-accept-RST-if-SEQ-matches-right-edge-of-right-most-SACK-block.patch WARNING: line over 80 characters #73: FILE: net/ipv4/tcp_input.c:5199: +

Re: [PATCH net-next] tcp: accept RST if SEQ matches right edge of SACK block

2016-06-03 Thread Neal Cardwell
On Fri, Jun 3, 2016 at 3:44 PM, Neal Cardwell wrote: > On Fri, Jun 3, 2016 at 12:24 PM, Eric Dumazet wrote: >> On Fri, 2016-06-03 at 11:45 -0400, Neal Cardwell wrote: >>> But I would also vote to tighten up the proposed logic slightly, and >>> only check the seq of t

Re: [PATCH net-next] tcp: accept RST if SEQ matches right edge of SACK block

2016-06-03 Thread Neal Cardwell
On Fri, Jun 3, 2016 at 12:24 PM, Eric Dumazet wrote: > On Fri, 2016-06-03 at 11:45 -0400, Neal Cardwell wrote: >> But I would also vote to tighten up the proposed logic slightly, and >> only check the seq of the incoming RST against the right edge of the >> *right-most* SAC

Re: [PATCH net-next] tcp: accept RST if SEQ matches right edge of SACK block

2016-06-03 Thread Neal Cardwell
On Fri, Jun 3, 2016 at 11:13 AM, Eric Dumazet wrote: > I have no strict opinion on this. > > It seems to me that checking at most 4 right edges (at least in current > linux implementation) is not adding a huge risk, and allows for better > interoperability. > > I vote for no extra sysctl. I vote

Re: [PATCH v2 net-next 11/11] tcp: rate limit ACK sent by SYN_RECV request sockets

2016-04-01 Thread Neal Cardwell
end back an ACK. > > This patch adds a rate limitation, so that the effect of such > attacks is limited to ingress only. > > We roughly double our ability to absorb such attacks. Thanks, Eric! Acked-by: Neal Cardwell neal

Re: Variable download speed

2016-02-23 Thread Neal Cardwell
On Tue, Feb 23, 2016 at 8:57 AM, wrote: > I published example pcap file under following link: > > https://www.dropbox.com/s/v8375ub16seyt1a/test7.pcap?dl=0 > > I hope it is possible to download it without creating dropbox account. Thanks for the trace. It looks like for the first 0.8 seconds of

Re: Variable download speed

2016-02-23 Thread Neal Cardwell
On Tue, Feb 23, 2016 at 6:19 AM, wrote: > My question is: what causes such dynamic change in > the window size (while transferring data)? > Is it some kernel parameter wrong set or something like this? That sounds like TCP receive buffer auto-tuning (also called "Dynamic right-sizing (DRS)" (Fisk

Re: [PATCH net] tcp: fix NULL deref in tcp_v4_send_ack()

2016-01-21 Thread Neal Cardwell
cket arrived. > > Before queuing a packet, TCP has to set skb->dev to NULL as the device > could disappear before packet is removed from the queue. > > Fix this issue by using the net pointer provided by the socket (being a > timewait or a request socket). Thanks, Eric! Acked-by: Neal Cardwell neal

Re: [RFC PATCHv2 net-next 1/2] tcp: RTO Restart (RTOR)

2015-12-10 Thread Neal Cardwell
On Thu, Dec 10, 2015 at 1:51 AM, Per Hurtig wrote: > >> On 08 Dec 2015, at 14:47, Eric Dumazet wrote: >> >> On Tue, 2015-12-08 at 10:19 +0100, Per Hurtig wrote: >> >>> +static u32 tcp_unsent_pkts(const struct sock *sk, u32 ulimit) >>> +{ >>> +struct sk_buff *skb = tcp_send_head(sk); >>> +

Re: [PATCH RFC net-next 2/2] tcp: Add Redundant Data Bundling (RDB)

2015-10-26 Thread Neal Cardwell
On Fri, Oct 23, 2015 at 4:50 PM, Bendik Rønning Opstad wrote: >@@ -2409,6 +2412,15 @@ static int do_tcp_setsockopt(struct sock *sk, int level, ... > + case TCP_RDB: > + if (val < 0 || val > 1) { > + err = -EINVAL; > + } else { > +

Re: [PATCH net-next 2/7] tcp: track min RTT using windowed min-filter

2015-10-18 Thread Neal Cardwell
On Wed, Oct 14, 2015 at 5:28 AM, Andrew Shewmaker wrote: >> diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c >> index 38743e5..e177386 100644 >> --- a/net/ipv4/tcp_input.c >> +++ b/net/ipv4/tcp_input.c > ... >> @@ -2961,7 +3028,7 @@ void tcp_synack_rtt_meas(struct sock *sk, struct >> requ

Re: Slow ramp-up for single-stream TCP throughput on 4.2 kernel.

2015-10-03 Thread Neal Cardwell
On Sat, Oct 3, 2015 at 6:46 PM, Ben Greear wrote: > > > On 10/03/2015 09:29 AM, Neal Cardwell wrote: >> >> On Fri, Oct 2, 2015 at 8:21 PM, Ben Greear >> wrote: >>> >>> Gah, seems 'cubic' related. That is the default tcp cong ctrl >>

Re: Slow ramp-up for single-stream TCP throughput on 4.2 kernel.

2015-10-03 Thread Neal Cardwell
On Fri, Oct 2, 2015 at 8:21 PM, Ben Greear wrote: > Gah, seems 'cubic' related. That is the default tcp cong ctrl > I was using (same in 3.17, for that matter). There have been recent changes to CUBIC that may account for this. If you could repeat your test with more instrumentation, eg "nstat",

Re: [PATCH net] tcp: add proper TS val into RST packets

2015-09-23 Thread Neal Cardwell
opposite : > > Once TSopt has been successfully negotiated, that is both and >contain TSopt, the TSopt MUST be sent in every non- > segment for the duration of the connection, and SHOULD be sent in an >segment (see Section 5.2 for details) > > Fixes: 7faee5c0d514 (&q

Re: [PATCH v2 net-next] tcp: Fix CWV being too strict on thin streams

2015-09-23 Thread Neal Cardwell
.1). > > Cc: Andreas Petlund > Cc: Carsten Griwodz > Cc: Jonas Markussen > Cc: Kenneth Klette Jonassen > Cc: Mads Johannessen > Signed-off-by: Bendik Rønning Opstad > --- Acked-by: Neal Cardwell Tested-by: Neal Cardwell I ran all the Google packetdrill test cases wit

Re: [PATCH net-next] tcp: Fix CWV being too strict on thin streams

2015-09-23 Thread Neal Cardwell
On Wed, Sep 23, 2015 at 10:46 AM, Bendik Rønning Opstad wrote: >> On Tue, Sep 22, 2015 at 2:02 PM, Neal Cardwell wrote: >> > More generally, my sense is that we should tweak the is_cwnd_limited code >> > to >> > shift from saying "set is_cwnd_limit

Re: [PATCH net-next] tcp: Fix CWV being too strict on thin streams

2015-09-22 Thread Neal Cardwell
On Tue, Sep 22, 2015 at 2:02 PM, Neal Cardwell wrote: > More generally, my sense is that we should tweak the is_cwnd_limited code to > shift from saying "set is_cwnd_limited to true iff the cwnd is known to be > limiting transmits" to saying "set is_cwnd_limited to

Re: [PATCH net-next] tcp: Fix CWV being too strict on thin streams

2015-09-22 Thread Neal Cardwell
> I'll describe two example scenarios in detail. In both scenarios we are in > congestion avoidance after experiencing loss. Nagle is disabled. Thanks for the detailed follow-up! And thanks, Eric, for the packetdrill script! This looks like an issue of how to deal with the case when we run out of

Re: [PATCH net-next] tcp: Fix CWV being too strict on thin streams

2015-09-19 Thread Neal Cardwell
On Fri, Sep 18, 2015 at 7:38 PM, Bendik Rønning Opstad wrote: > > Application limited streams such as thin streams, that transmit small > amounts of payload in relatively few packets per RTT, are prevented from > growing the CWND after experiencing loss. This leads to increased > sojourn times for

Re: kernel warning in tcp_fragment

2015-09-14 Thread Neal Cardwell
On Mon, Sep 14, 2015 at 6:27 AM, Jovi Zhangwei wrote: > > Hi Near, > > After several days testing on your patch, our system crashed. Dmesg attached. Jovi -- Sorry about that... thank you for the testing and the data point. neal -- To unsubscribe from this list: send the line "unsubscribe netdev"

Re: [PATCH v2 net-next] tcp: fix slow start after idle vs TSO/GSO

2015-08-21 Thread Neal Cardwell
m the check > if/when receive window opens. ... > Signed-off-by: Eric Dumazet > Cc: Neal Cardwell > Cc: Yuchung Cheng > --- Acked-by: Neal Cardwell Looks good to me. Thanks, Eric! neal -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of

Re: [PATCH net-next] tcp: refine pacing rate determination

2015-08-21 Thread Neal Cardwell
ect the conservative ratio > as soon as cwnd >= ssthresh/2 : > > - After cwnd reduction, it is safer to ramp up more slowly, > as we approach optimal cwnd. > - Initial ramp up (ssthresh == INFINITY) still allows doubling > cwnd every other RTT. > > Signed-off-by: Eric Duma

Re: [PATCH net-next] tcp: fix slow start after idle vs TSO/GSO

2015-08-21 Thread Neal Cardwell
On Thu, Aug 20, 2015 at 1:08 PM, Eric Dumazet wrote: > From: Eric Dumazet > > slow start after idle might reduce cwnd, but we perform this > after first packet was cooked and sent. > > With TSO/GSO, it means that we might send a full TSO packet > even if cwnd should have been reduced to IW10. > >

Re: kernel warning in tcp_fragment

2015-08-10 Thread Neal Cardwell
On Mon, Aug 10, 2015 at 2:10 PM, Jovi Zhangwei wrote: > > Ping? > > We saw a lot of this warnings in our production system. It would be > great appreciate if someone can give us the fix on this warnings. :) What is your net.ipv4.tcp_mtu_probing setting? If 1, have you tried setting it to 0? Previ

Re: [PATCH net-next] tcp: tso: allow deferring under reordering state

2015-07-26 Thread Neal Cardwell
his patch removes the limitation, as we did for CWR state > in commit a0ea700e409 ("tcp: tso: allow CA_CWR state in > tcp_tso_should_defer()") > > Neal Cardwell had a concern about limited transmit so > Yuchung conducted experiments on GFE and found nothing > worth ad

Re: [RFC PATCH v2 net-next 3/3] tcp: add NV congestion control

2015-07-22 Thread Neal Cardwell
On Wed, Jul 22, 2015 at 2:50 AM, Yuchung Cheng wrote: > On Tue, Jul 21, 2015 at 9:21 PM, Lawrence Brakmo wrote: >> This is a request for comments. >> >> TCP-NV (New Vegas) is a major update to TCP-Vegas. An earlier version of >> NV was presented at 2010's LPC (slides). It is a delayed based >> co

Re: [RFC PATCH v2 net-next 1/3] tcp: replace cnt & rtt with struct in pkts_acked()

2015-07-22 Thread Neal Cardwell
n without having to modify existing congestion control >> modules (tcp_nv in particular needs bytes in flight when packet >> was sent). >> >> This was proposed by Neal Cardwell in his comments to the tcp_nv patch. > > Are you sure Neal suggested to pass a struct as argument

Re: [PATCH net-next] tcp: do not export tcp_init_xmit_timers()

2015-07-09 Thread Neal Cardwell
On Thu, Jul 9, 2015 at 12:01 PM, Eric Dumazet wrote: > > From: Eric Dumazet > > After commit 900f65d361d3 ("tcp: move duplicate code from > tcp_v4_init_sock()/tcp_v6_init_sock()"), we no longer > need to export tcp_init_xmit_timers() > > Signed-off-by: Eric Du

Re: [RFC PATCH net-next] tcp: add NV congestion control

2015-07-03 Thread Neal Cardwell
> diff --git a/include/linux/tcp.h b/include/linux/tcp.h > index 48c3696..05e0da5 100644 > --- a/include/linux/tcp.h > +++ b/include/linux/tcp.h > @@ -254,6 +254,10 @@ struct tcp_sock { > u32 lost_out; /* Lost packets */ > u32 sacked_out; /* SACK'd

Re: [PATCH net-next] inet: add IP_BIND_ADDRESS_NO_PORT to overcome bind(0) limitations

2015-06-06 Thread Neal Cardwell
On Sat, Jun 6, 2015 at 11:53 AM, Eric Dumazet wrote: > From: Eric Dumazet ... > This patch adds a new SOL_IP socket option, asking kernel to ignore > the 0 port provided by application in bind(IP, port=0) and only > remember the given IP address. ... > This new feature is available for both IPv4

Re: Recurring trace from tcp_fragment()

2015-06-04 Thread Neal Cardwell
On Thu, Jun 4, 2015 at 12:35 PM, Grant Zhang wrote: > Hi Neal, > > Unfortunately with the patch we still see the same stack trace. Attached is > the TcpExtTCPSACKReneging with the patch, captured with 60 seconds interval. > Its value is incremented at an similar speed as before, about 30/minute. >

Re: Recurring trace from tcp_fragment()

2015-05-30 Thread Neal Cardwell
On Sat, May 30, 2015 at 2:52 PM, Grant Zhang wrote: > Thank you Neal. Most likely I will test the patch on Monday and report > back the result. > > As for the TcpExtTCPSACKReneging counter, attached is the captured > counter value on a 1-second interval for 10 minutes. OK, great. Those TcpExtTCPS

Re: Recurring trace from tcp_fragment()

2015-05-30 Thread Neal Cardwell
On Fri, May 29, 2015 at 3:53 PM, Grant Zhang wrote: > Hi Neal, > > I will be more happy to test the patch. Please send it my way. Great. Thank you so much for being willing to do this. Attached is a patch for testing. I generated it and tested it relative to Linux v3.14.39, since your stack trace

Re: Recurring trace from tcp_fragment()

2015-05-29 Thread Neal Cardwell
On Fri, May 29, 2015 at 3:21 PM, Grant Zhang wrote: > We have multiple machines running into the following trace repeatedly. The > trace shows up every couple of seconds on our production machines. > ... > May 29 18:14:04 cache-fra1230 kernel:[3080455.796188] [] > tcp_fragment+0x2e4/0x2f0 > May

[PATCH net] tcp: fix child sockets to use system default congestion control if not set

2015-05-29 Thread Neal Cardwell
Fixes: 55d8694fa82c ("net: tcp: assign tcp cong_ops when tcp sk is created") Cc: Florian Westphal Cc: Daniel Borkmann Cc: Glenn Judd Cc: Stephen Hemminger Signed-off-by: Neal Cardwell Signed-off-by: Eric Dumazet Signed-off-by: Yuchung Cheng --- include/net/inet_connection_s

Re: [PATCH net-next] tcp: tcp_tso_autosize() minimum is one packet

2015-05-26 Thread Neal Cardwell
> We can then revert 843925f33fcc293d80acf2c5c8a78adf3344d49b > ("tcp: Do not apply TSO segment limit to non-TSO packets") > and save few cpu cycles in fast path. Thanks, Eric! This is a nice clean-up/simplification. Acked-by: Neal Cardwell neal -- To unsubscribe from this list: send the line "un

Re: [PATCH v2 net-next 1/2] tcp: adjust window probe timers to safer values

2015-05-06 Thread Neal Cardwell
based retransmits) > > A followup patch adds a new SNMP counter, as it would have helped a lot > diagnosing this issue. > > Signed-off-by: Eric Dumazet > Signed-off-by: Yuchung Cheng Acked-by: Neal Cardwell neal -- To unsubscribe from this list: send the line &qu

Re: [PATCH net-next] tcp_westwood: fix tcp_westwood_info()

2015-04-29 Thread Neal Cardwell
Reported-by: kbuild test robot > Signed-off-by: Eric Dumazet Acked-by: Neal Cardwell neal -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH net-next 2/2] tcp: add TCP_CC_INFO socket option

2015-04-28 Thread Neal Cardwell
y have a socket file descriptor, > instead of playing complex netlink games. > > Sample usage would be : > > union tcp_cc_info info; > socklen_t len = sizeof(info); > > if (getsockopt(fd, SOL_TCP, TCP_CC_INFO, &info, &len) == -1) > > Signed-off-

Re: [PATCH net-next 1/2] tcp: prepare CC get_info() access from getsockopt()

2015-04-28 Thread Neal Cardwell
info(), so that following patch > can reuse this common infrastructure. > > Signed-off-by: Eric Dumazet > Cc: Yuchung Cheng > Cc: Neal Cardwell > --- Acked-by: Neal Cardwell Thanks, Eric! neal -- To unsubscribe from this list: send the line "unsubscribe netd

<    1   2   3   4