lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [task #6849] Test how checksum on copy could be integrated


From: Simon Goldschmidt
Subject: [lwip-devel] [task #6849] Test how checksum on copy could be integrated into the stack
Date: Sun, 10 May 2009 17:36:06 +0000
User-agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.4; de; rv:1.9.0.10) Gecko/2009042315 Firefox/3.0.10

Follow-up Comment #9, task #6849 (project lwip):

[Referring a little bit to the discussion in patch #6253: Added csum to
struct pbuf.]

My opinion on this has change a little: We have 2 main issues here, TX and
RX.

My current plans for TX:
- If the application already knows the checksum, let it pass the checksum to
the lwIP API (e.g. add u16_t chksum to a function udp_send_chksummed()) - this
would only allow all data to be checksummed, but I think that's OK
- If the application does NOT know the checksum: create it when copying
(introduce new functions checksum-memcpy, overridable for ports like current
checksum creation)

For UDP/RAW the checksum would only have to be passed down, for TCP, I'd
store it in the segment struct and update it when new data is appended to a
segment.

The only problem is real zero-copy (UDP sockets or TCP-no-copy).

For RX, I'm still convinced that the netif driver should discard packets with
invalid checksums if checksum is already created when copying the packet into
RAM. We could help driver developers by providing functions that take an
RX-pbuf and the checksum and do a fast check if that checksum is valid.


    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/task/?6849>

_______________________________________________
  Nachricht geschickt von/durch Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]