From: Stephen Hemminger <shemminger@linux-foundation.org>
To: "Michael Chan" <mchan@broadcom.com>
Cc: "Herbert Xu" <herbert.xu@redhat.com>, "netdev" <netdev@vger.kernel.org>
Subject: Re: Definition and usage of NETIF_F_HW_SUM?
Date: Tue, 29 May 2007 16:45:42 -0700 [thread overview]
Message-ID: <20070529164542.2a38e2f8@freepuppy> (raw)
In-Reply-To: <1180483852.9711.28.camel@dell>
On Tue, 29 May 2007 17:10:52 -0700
"Michael Chan" <mchan@broadcom.com> wrote:
> On Wed, 2007-05-30 at 07:36 +1000, Herbert Xu wrote:
>
> >
> > I just checked e1000 and it's correct as it does use the csum_offset
> > when doing TX offload. However, you're definitely right that bnx2
> > seems to be broken.
> >
> > > A few devices take a offset, starting point, and insertion point. This looks like
> > > the correct model. But no upper layer protocols other than IPV4/IPV6 can do checksum
> > > offload at present, so it seems moot.
> >
> > I could easily whip up a patch to get GRE to use it for a start :)
> >
> > > IMHO the correct solution would be to get rid if NETIF_F_HW_SUM and make a new flag
> > > NETIF_F_IPV6_SUM. Devices that can checksum both could do NETIF_F_IPV4_SUM|NETI_F_IPV6_SUM.
> >
> > We should definitely keep NETIF_F_HW_SUM for sane hardware such as the
> > e1000. Unfortunately we may just have to invent IPV6_SUM for the broken
> > ones.
> >
> > Ccing Michael to see if the bnx2 chip can actually do offset-based
> > checksum offload.
> >
>
> bnx2 and tg3 cannot do offset-based checksumming because the hardware
> doesn't have room in the buffer descriptors to specify the offsets. So
> regrettably, the NETIF_F_HW_SUM flag has been misused in these drivers.
> A new NETIF_F_IPV6_SUM flag will be very useful for us.
Look furthur many drivers are just plain broken and use F_HW_SUM
and can't even do IPV6 properly. I'll fix
The worst code award goes to: qla3xxx.c
which is broken on IPV6 and goes to trouble of computing all the
offsets and they are already there in skb...
--
Stephen Hemminger <shemminger@linux-foundation.org>
next prev parent reply other threads:[~2007-05-29 23:56 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-29 20:58 Definition and usage of NETIF_F_HW_SUM? Stephen Hemminger
2007-05-29 21:36 ` Herbert Xu
2007-05-29 21:58 ` Stephen Hemminger
2007-05-30 0:10 ` Michael Chan
2007-05-29 23:45 ` Stephen Hemminger [this message]
2007-06-04 15:35 ` Ron Mercer
2007-05-30 15:53 ` [RFC] IPV6 checksum offloading in network devices Stephen Hemminger
2007-05-30 16:13 ` Patrick McHardy
2007-05-30 21:00 ` Stephen Hemminger
2007-06-27 7:44 ` 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=20070529164542.2a38e2f8@freepuppy \
--to=shemminger@linux-foundation.org \
--cc=herbert.xu@redhat.com \
--cc=mchan@broadcom.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).