Re: How to verify RX checksum offload??
Re: How to verify RX checksum offload??
- Subject: Re: How to verify RX checksum offload??
- From: Terry Lambert <email@hidden>
- Date: Tue, 7 Jul 2009 16:00:54 -0700
On Jul 7, 2009, at 11:22 AM, Andrew Gallatin wrote:
Terry Lambert wrote:
> If receive checksum offloading is enabled then the hardware will
reject
> the packet when it sees the bad checksum and the OS will not get
to see
> it in the first place. That is more or less the point of checksum
> offloading, to avoid the bus transfer of the copy of the received
data
> from the Ethernet chip FIFO into mbufs and the subsequent receive
> interrupt, running the ISR, running ip_input and tcp_input, etc.,
only
> to have wasted all that work on a bad packet.
Avoiding the transfer of the rare (1 in a million? 100 million?
billion?) packets that are corrupt is not the point of checksum
offloading. The point of checksum offloading is to avoid the OS
needlessly reading the entire packet into memory to verify the
checksum, and thereby polluting its cache.
On the machines I was using it on (admittedly, they were 1/3 as
powerful compared to todays machines), the big bottleneck wasn't cache
shoot-down, it was I/O over the PCI bus. I did try to specify
multiple cards to push this more into the realm of an I/O bottleneck
rather than a cache bottleneck, even though we have faster processors
and busses today relative to a 1Gbit ethernet link.
Presumably if you are getting good inbound packets, they're going to
have to go to memory sooner or later, so it might as well be sooner,
and you will presumably be reading their payload in order to act on
it, so your cache is no worse off than otherwise.
I also mentioned DOS... as in a bunch of bad packets with good IP
header checksums and bad TCP checksums on payload.
-- Terry
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden