lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] TCP checksum error for big sized packets on lwip 1.3.0


From: address@hidden
Subject: Re: [lwip-users] TCP checksum error for big sized packets on lwip 1.3.0
Date: Wed, 07 May 2008 19:22:40 +0200
User-agent: Thunderbird 2.0.0.14 (Macintosh/20080421)

Muhamad Ikhwan Ismail wrote:
I found out the problem already. My driver was set up to transfer out one buffer per frame only (1520 bytes) since we want to spare processing power as much as we can and also due to the fact we have ample memory, and the 1.3.0 seems to chain the TCP packets to form frames(multiple buffers per frame). Is there any thing i can setup to force
TCP packs 1520 bytes per buffer (pbufs) ?
As Jonathan already said, lwIP chains pbufs. I strongly suggest you change your driver to handle that if possible. If this is not possible, you will have to copy chained pbufs into a newly allocated contiguous pbuf: allocate a PBUF_RAM with length p->tot_len of the original pbuf and use pbuf_copy to make a copy.

The reason you might not have seen this before 1.3.0 is that with 1.3.0, the nagle algorithm was improved. This algorithm is responsible for chaining multiple pbufs into one packet. You can try to turn it off for your socket (using setsockopt / TCP_NODELAY option), but that will have a negative effect on throughput!

Simon




reply via email to

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