|
From: | David Empson |
Subject: | Re: [lwip-users] TCP transmission issue, with linux server. |
Date: | Mon, 10 Aug 2009 10:29:25 +1200 |
In this particular case, packet 9 (from Linux)
acknowledged the data your LWIP device sent in packet 8, so packet 10 does seem
odd. The Linux system must have had some reason it wanted to send data at that
point. Perhaps the application wrote the data in two or more separate write
calls, and Linux decided to transmit some of it just before the last block was
available. Another possibile explanation: I note that your LWIP
device is advertising a window size of 1500, and the Linux system sent 750
bytes. The fact that this is half the window size seems to be too much of a
coincidence. Perhaps the Linux TCP/IP stack has a rule that it will never send a
block of data which is greater than half the window size. You could test this by
increasing your advertised window, e.g. to 3K instead of 1.5K.
IP reassembly won't make any difference - you aren't
getting IP fragmentation. This is a simple case of TCP sending a block of data
which is less than MSS.
In general, your
application should able to cope with receiving arbitrarily sized blocks of
data via TCP, and reassembling received data as required if you
need logical blocks of data of a certain size. There are many reasons why
TCP might deliver data in blocks smaller than MSS. ----- Original Message -----
|
[Prev in Thread] | Current Thread | [Next in Thread] |