lkml.org 
[lkml]   [2000]   [Sep]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: zero-copy TCP

**ALL** Netware network drivers support a scatter/gather proramming
interface, whether the hardware does or not. In NetWare, the drivers
get passed a fragment list in what's called an ECB (Event Control
Block). It's the drivers responsiblity to assemble the fragment lists.
We did it this way to support scatter/gather cards and non-scatter
gather cards in one interface. Those drivers that do not support
scatter gather DMA operations copy to a local buffer to assemble the
packet. Those with a shared memory window copy data from the fragment
list into this window until a complete IEEE frame gets completed (since
it will get copied anyway), then hit the register bits to initiate a
send of the data.

Jeff

Jes Sorensen wrote:
>
> >>>>> "Jeff" == Jeff V Merkey <jmerkey@timpanogas.com> writes:
>
> Jeff> all over the place that increases latency. Not to mention the
> Jeff> overhead of the type of interrupt and trap gates that suck up
> Jeff> about 50 clocks to fetch the IDT, PDE, and GDT tables for every
> Jeff> interrupt. NetWare copies nothing in TCPIP except at the stream
> Jeff> head. Why do you need to copy data anyway to checksum an IP
> Jeff> packet anyway? I noticed you do the right thing and keep the
> Jeff> headers and data as separate fragments during header
> Jeff> construction, so why do you need to copy data for checksumming?
>
> Because your hardware doesn't do scatter/gather DMA *and* TCP TX
> checksumming - only very few cards do. You have to build every packet
> in memory if the card doesn't do sct/gat since you can't really send
> out data without IP headers in front of it. And if your card doesn't
> do TX transmit then you have to run over all the data with the CPU to
> calculate the checksum and once you do this you can just as well do
> the full copy. Also note that many cards that do sct/gth also have a
> bit of latency per descriptor so you do not want to use 10 descriptors
> for a 1500 byte packet.
>
> Jes
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:38    [W:0.173 / U:47.280 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site