From: William Allen Simpson <william.allen.simpson@gmail.com>
To: "netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: query: bnx2 and tg3 don't check tcp and/or ip header length validity?
Date: Wed, 14 Oct 2009 20:40:36 -0400 [thread overview]
Message-ID: <4AD66F84.2010703@gmail.com> (raw)
In-Reply-To: <1255555458.20869.221.camel@nseg_linux_HP1.broadcom.com>
Michael Chan wrote:
> The option length is needed by the hardware to segment a TSO packet into
> proper MTU-sized packets. You'll get malformed packets if the TSO
> header is bad. Setting it to zero perhaps can make these bad packets
> more deterministic, but I don't know for sure.
>
Malformed packets are unlikely (I'll use unlikely() on the test), but
I've seen a lot of unlikely things happen over the years. When I was
concourse manager at Interop '91, a bad Portmaster build wouldn't pass
packets through one kind of router (3com); but it passed through all
the others! Turned out, *most* routers didn't check the IP version
and IHL fields. Shocking!
When we were designing IPv6 in '93, we had to use new IEEE numbers, etc.
(instead of the IP version and IHL) to distinguish the new version.
Otherwise, various printers crashed....
Unless there's a clearly documented check earlier in the code path (and
there's nothing documented here), always re-check everything. (Also,
never forget cosmic radiation....) Remember, from a driver developer's
perspective, the hardware always fails. (And from a hardware viewpoint,
the software is always bad.)
next prev parent reply other threads:[~2009-10-15 0:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-14 15:50 query: bnx2 and tg3 don't check tcp and/or ip header length validity? William Allen Simpson
2009-10-14 20:46 ` William Allen Simpson
2009-10-14 21:24 ` Michael Chan
2009-10-15 0:40 ` William Allen Simpson [this message]
2009-10-15 0:49 ` 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=4AD66F84.2010703@gmail.com \
--to=william.allen.simpson@gmail.com \
--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).