[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1398549526.16049.20.camel@deadeye.wl.decadent.org.uk>
Date: Sat, 26 Apr 2014 22:58:46 +0100
From: Ben Hutchings <ben@...adent.org.uk>
To: Tom Herbert <therbert@...gle.com>
Cc: davem@...emloft.net, netdev@...r.kernel.org
Subject: Re: [PATCH 9/9 v2] net: Add sysctl to trust checksum_complete
On Sat, 2014-04-26 at 14:26 -0700, Tom Herbert wrote:
> Currently if a device provides CHECKSUM_COMPLETE but the checksum
> is calculated to be invalid we recompute the checksum and try
> again in software. On the other hand, if device returns
> CHECKSUM_UNNECESSARY we implicitly trust it and don't verify what it
> did. This seems backwards!
>
> Add a sysctl to trust the device and report an invalid checksum when
> CHECKSUM_COMPLETE shows it is incorrect. sysctl defaults to enabled.
[...]
I think the sysctl and variable names need an '_error' or '_err' on the
end, to distinguish this from the NETIF_F_RXCSUM feature flag.
The new sysctl also needs to be documented, again making that
distinction clear.
Finally, if we're going to start trusting device checksum errors,
perhaps there should be a way to indicate a checksum error from a device
that only reports a checksum good/bad flag. I do understand that such
devices are more likely to have bugs in checksum validation, though.
Ben.
--
Ben Hutchings
The most exhausting thing in life is being insincere. - Anne Morrow Lindberg
Download attachment "signature.asc" of type "application/pgp-signature" (812 bytes)
Powered by blists - more mailing lists