]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Implement TSO for BCM5755 or newer controllers. Some controllers
authorPyun YongHyeon <yongari@FreeBSD.org>
Sun, 22 Nov 2009 21:16:30 +0000 (21:16 +0000)
committerPyun YongHyeon <yongari@FreeBSD.org>
Sun, 22 Nov 2009 21:16:30 +0000 (21:16 +0000)
commitca3f1187f154de5329921d158d37177641a3f20b
tree72737c0c382c4cbcf61b624d35d9b23da511bcea
parentf681b29a6ddc07657deef1445e85acf98a4545a3
Implement TSO for BCM5755 or newer controllers. Some controllers
seem to require a special firmware to use TSO. But the firmware is
not available to FreeBSD and Linux claims that the TSO performed by
the firmware is slower than hardware based TSO. Moreover the
firmware based TSO has one known bug which can't handle TSO if
ethernet header + IP/TCP header is greater than 80 bytes. The
workaround for the TSO bug exist but it seems it's too expensive
than not using TSO at all. Some hardwares also have the TSO bug so
limit the TSO to the controllers that are not affected TSO issues
(e.g. 5755 or higher).
While I'm here set VLAN tag bit to all descriptors that belengs to
a frame instead of the first descriptor of a frame. The datasheet
is not clear how to handle VLAN tag bit but it worked either way in
my testing. This makes it simplify TSO configuration a little bit.

Big thanks to davidch@ who sent me detailed TSO information.
Without this I was not able to implement it.

Tested by: current
sys/dev/bge/if_bge.c
sys/dev/bge/if_bgereg.h