offloading ip checksum calculation to the NIC
kamal kc
kamal_ckk at yahoo.com
Fri Feb 3 02:30:56 PST 2006
--- Gleb Smirnoff <glebius at FreeBSD.org> wrote:
> On Thu, Feb 02, 2006 at 10:20:46PM -0800, kamal kc wrote:
> k> i want to offload ip checksum calculation to the NIC.
> k> I use 3Com 3c905B-TX NIC cards.
> k>
> k> I found that there are variables::>>
> k>
> k> int csum_flags; /* flags regarding checksum */
> k> int csum_data; /* data field used by csum routines */
> k>
> k> in struct pkthdr in mbuf.h.
> k>
> k> also i found the various flags for the hardware checksumming.
> k> but i don't know the exact steps i need to do
> k> in order to offload checksumming.
> k>
> k> should i set the csum_flags to CSUM_IP and point
> k> csum_data to the start of the ip header ??
> k>
> k> it would be a great help if anybody
> k> could tell me what do i need to do ?
>
> afaik, the xl(4) driver already supports checksum calculation.
>
> --
so what do i need to do if i don't want to calculate
the ip checksum myself ?
right now i am taking off packet from the kernel
and modifying some of the data content, and
outputting to the IFQ_HANDOFF myself. and i
am calculating the checksum myself.
i guess if xl would support the
hardware checksumming i could use that
feature.
i am just a beginner and i am not getting
the clear picture.
thanks,
kamal
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
More information about the freebsd-net
mailing list