[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CADVnQykoadLALP4iOzm16F=XQW41q8m_GnzKsGOgrkg6jso15g@mail.gmail.com>
Date: Fri, 4 Aug 2017 11:54:32 -0400
From: Neal Cardwell <ncardwell@...gle.com>
To: maowenan <maowenan@...wei.com>
Cc: David Miller <davem@...emloft.net>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
Yuchung Cheng <ycheng@...gle.com>,
Nandita Dukkipati <nanditad@...gle.com>
Subject: Re: [PATCH net 3/3] tcp: fix xmit timer to only be reset if data ACKed/SACKed
On Fri, Aug 4, 2017 at 3:12 AM, maowenan <maowenan@...wei.com> wrote:
> > > --- a/net/ipv4/tcp_output.c
> > > +++ b/net/ipv4/tcp_output.c
> > > @@ -2380,21 +2380,12 @@ bool tcp_schedule_loss_probe(struct sock *sk)
> > > u32 rtt = usecs_to_jiffies(tp->srtt_us >> 3);
> > > u32 timeout, rto_delta_us;
> > >
> > > - /* No consecutive loss probes. */
> > > - if (WARN_ON(icsk->icsk_pending == ICSK_TIME_LOSS_PROBE)) {
> > > - tcp_rearm_rto(sk);
> > > - return false;
> > > - }
> [Mao Wenan] I'm sorry I can't get why you delete this and below "if" branch?
We deleted those two "if" branches in tcp_schedule_loss_probe()
because they were assuming that TLP probes would only be scheduled in
a context where an RTO had already been scheduled. With the old
implementation that was true: on every ACK (tcp_ack()) or send of new
data (tcp_event_new_data_sent()) we would first schedule an RTO (by
calling tcp_rearm_rto()) and then schedule a TLP (by calling
tcp_schedule_loss_probe()). So the checks were the right ones for the
old implementation.
With the new implementation, we do not first rearm the RTO on every
incoming ACK. That means when we get to tcp_schedule_loss_probe() we
may find either an RTO or TLP is pending.
Hope that helps clear that up.
cheers,
neal
Powered by blists - more mailing lists