lwip-devel
[Top][All Lists]
Advanced

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

Re: [lwip-devel] tcp_input: order of processing question/comment


From: address@hidden
Subject: Re: [lwip-devel] tcp_input: order of processing question/comment
Date: Wed, 04 Feb 2009 18:06:21 +0100
User-agent: Thunderbird 2.0.0.19 (Macintosh/20081209)

I guess the intention was to be able to output data enqueued in the recv callback. _If_ changing anything, we could add a _second_ call to tcp_output _before_ calling the recv callback, but the call _after_ the recv callback has to remain there, I think.


Simon


bill wrote:

Currently In tcp_input, towards the end of the function, the tcp_recv callback is called and if there is no error returned, tcp_output is called to process any pending outgoing data.

The questions are: Why would we want an error returned by the receive callback to prevent us from sending any pending data? Wouldn’t we still want to send queued ACKs or queued data?

The comment is: It would seem to be better to call tcp_output **before** calling the tcp_recv callback. This would allow the other end of the connection to process any data that may be sent in that call while the lwIP side goes off and processes its data in the receive callback. In my bandwidth testing I do see slightly better performance by adding a tcp_output call before the receive callback.

Bill

------------------------------------------------------------------------

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





reply via email to

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