lwip-users
[Top][All Lists]
Advanced

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

RE: [lwip-users] Re: TCP payload is doubled (Hans-Joerg)


From: David Shmelzer
Subject: RE: [lwip-users] Re: TCP payload is doubled (Hans-Joerg)
Date: Tue, 20 Oct 2009 11:28:21 -0400

Simon,

It worked normally at normal speed, but the reported window size from
lwip kept decreasing until it got to less than the packet length at
which point it would pause as expected. I was having the same problem as
Jan Wester who captured the problem in wireshark. 
http://lists.nongnu.org/archive/html/lwip-users/2009-10/msg00113.html

The reason it is working now is that the window size does not decrement
all the way to 0 causing a timeout. It only goes down to TCP_MSS, sends
an explicit window update of 800 and continues.

3715    552.744385      192.168.2.2             192.168.2.99    TCP
40100 > canex-watch [PSH, ACK] Seq=7031 Ack=4799 Win=406 Len=6
3716    552.744464      192.168.2.99    192.168.2.2             TCP
canex-watch > 40100 [PSH, ACK] Seq=4799 Ack=7037 Win=65325 Len=6
3717    552.744895      192.168.2.2             192.168.2.99    TCP
40100 > canex-watch [ACK] Seq=7037 Ack=4805 Win=800 Len=0
3718    552.745146      192.168.2.2             192.168.2.99    TCP
40100 > canex-watch [PSH, ACK] Seq=7037 Ack=4805 Win=800 Len=6

my lwipopts:
#define TCP_MSS                         400
#define TCP_SND_BUF                     (4 * TCP_MSS)
#define TCP_WND                         (2 * TCP_MSS)
#define TCP_WND_UPDATE_THRESHOLD        (TCP_WND / 4)


Question is, why is the window size decremented? Are the packets being
buffered?
BTW, I like how you and Keiran have optimized the window updates. It
improves the speed of my protocol which, in itself, is an ACK/NAK type
protocol.
Thanks.

Dave


-----Original Message-----
From: address@hidden
[mailto:address@hidden On Behalf Of
address@hidden
Sent: Tuesday, October 20, 2009 10:49 AM
To: Mailing list for lwIP users
Subject: Re: [lwip-users] Re: TCP payload is doubled (Hans-Joerg)

David Shmelzer wrote:
> Thanks Hans.
> I was indeed calling tcp_recvd.
> Problem was my TCP_WND == TCP_MSS.
> I doubled TCP_WND and it now works.
>   
David, did it totally stop working or was it just slow (high latencies)?

The reason I ask is it could be slow with WND==MSS, but it shouldn't
stop working! If it does, we should have a look at the reason.

Simon


_______________________________________________
lwip-users mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/lwip-users




reply via email to

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