From: "Ilpo Järvinen" <ilpo.jarvinen@helsinki.fi>
To: Netdev <netdev@vger.kernel.org>
Cc: David Miller <davem@davemloft.net>
Subject: Suspicious fackets_out handling
Date: Mon, 23 Apr 2007 14:28:21 +0300 (EEST) [thread overview]
Message-ID: <Pine.LNX.4.64.0704231218440.28337@kivilampi-30.cs.helsinki.fi> (raw)
Hi,
While looking through the users of fackets_out, i found this from
tcp_fragment(...):
/* If this packet has been sent out already, we must
* adjust the various packet counters.
*/
if (!before(tp->snd_nxt, TCP_SKB_CB(buff)->end_seq)) {
int diff = old_factor - tcp_skb_pcount(skb) -
tcp_skb_pcount(buff);
[...snip...]
if (diff > 0) {
/* Adjust Reno SACK estimate. */
if (!tp->rx_opt.sack_ok) {
tp->sacked_out -= diff;
if ((int)tp->sacked_out < 0)
tp->sacked_out = 0;
tcp_sync_left_out(tp);
}
tp->fackets_out -= diff;
if ((int)tp->fackets_out < 0)
tp->fackets_out = 0;
}
}
[...]
There are IMHO two problems in it. First of all, nothing ensures that the
skb TCP is fragmenting is actually below the forwardmost sack block (and
thus is included to the fackets_out)... What I'm not sure of though, is
how to fix this in net-2.6(.22), it is due to the fact that there is no
pointer/seq which can be used in testing for it like in tcp-2.6 which has
the highest_sack. Second problem is even more obvious: if adjustment here
is being done and the sacktag code then uses fastpath at the arrival of
the next ACK, the sacktag code will use a stale value from
fastpath_cnt_hint and fails to notice all that math TCP did here unless we
start clearing fastpath_skb_hint.
--
i.
next reply other threads:[~2007-04-23 11:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-23 11:28 Ilpo Järvinen [this message]
2007-05-31 19:59 ` Suspicious fackets_out handling David Miller
2007-06-01 12:17 ` Ilpo Järvinen
2007-07-03 5:07 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.64.0704231218440.28337@kivilampi-30.cs.helsinki.fi \
--to=ilpo.jarvinen@helsinki.fi \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).