netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC] skge csum problems
@ 2007-12-24  9:43 Al Viro
  2007-12-24 13:15 ` Andi Kleen
  0 siblings, 1 reply; 6+ messages in thread
From: Al Viro @ 2007-12-24  9:43 UTC (permalink / raw)
  To: netdev

	Both variants of skge (drivers/net and drivers/net/sk98lin/ resp.)
have the same problem with rx checksums.  They pick checksum from rx
descriptor and use it as-is.  Normally that would be the right thing to
do.  However, skge is told to byteswap descriptors on big-endian boxen.

Checksum is fixed-endian and we want it that way; IOW, what we end up
storing in skb->csum should be fixed-endian as well.  Unless the card
is smart enough to byteswap everything in rx descriptor _except_ the
checksum, we have a trouble - we get a value converted to host-endian
by the general byteswap in descriptor and we must convert it to fixed-endian
ourselves.

FWIW, FreeBSD sk_if sidesteps that mess by not telling the card to 
byteswap, so that's not too informative.  Datasheet on
http://people.freebsd.org/~wpaul/SysKonnect/xmacii_datasheet_rev_c_9-29.pdf
is not clear on what's going on with checksum in byteswapping mode either...

Could somebody with that sucker on a card (all instances I have here are
on-board ones in little-endian boxen) test what's really going on for
big-endian hosts with either driver?

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-12-27 19:32 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-24  9:43 [RFC] skge csum problems Al Viro
2007-12-24 13:15 ` Andi Kleen
2007-12-24 18:39   ` Al Viro
2007-12-24 19:36     ` Stephen Hemminger
2007-12-24 19:45       ` Al Viro
2007-12-27 19:31         ` Stephen Hemminger

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).