Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 Aug 2013 10:46:26 +0900
From:      Yonghyeon PYUN <pyunyh@gmail.com>
To:        freebsd-current@FreeBSD.org
Subject:   CFT: bge(4) TX/RX checksum offloading
Message-ID:  <20130830014626.GA3107@michelle.cdnetworks.com>

next in thread | raw e-mail | index | archive | help
Hi,

It was known that bge(4) generated wrong TCP/UDP checksum when the
frame length was less then 60 bytes.  So bge(4) implemented padding
workaround for such runt frames. bge(4) also ignored H/W assisted
TCP/UDP checksum result when the length of received frame was less
than 60 bytes.  This workaround came from NetBSD about 7 years ago.

Recently I started to wonder why bge(4) needs such workaround given
that 1) publicly available data sheet does not mention the issue
and 2) Linux tg3 does not have any workaround for the issue. I also
asked the question to Broadcom and I was told that they(both Linux
and Windows software developers) can't recall they have the issue.

Linux does not use IP checksum offloading feature of controller so
it's possible for the controller to have IP checksum offloading
issue on runt frames. But I was not able to reproduce the issue on
my box. Here is the patch that removes the workaround in bge(4).

http://people.freebsd.org/~yongari/bge/bge.csum.diff

The diff was generated against HEAD but it will also apply cleanly
to stable/9.  If you use bge(4) devices, please give it a whirl and
let me know how well it works on your configuration.

Thanks.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130830014626.GA3107>