buglwIP - A Lightweight TCP/IP stack - Bugs: bug #46948, Default TCP_SNDLOWAT invalid when...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #46948: Default TCP_SNDLOWAT invalid when TCP_SND_BUF > 2*65535

Submitter:  Joel Cunningham <jcunningham>
Submitted:  Thu 21 Jan 2016 04:28:01 PM UTC
   
 
Category:  TCP Severity:  3 - Normal
Item Group:  Faulty Behaviour Status:  Fixed
Privacy:  Public Assigned to:  goldsimon
Open/Closed:  Closed Planned Release:  None
lwIP version:  git head

Thu 18 Feb 2016 08:37:18 AM UTC, comment #1: 

Fixed by checking TCP_SNDLOWAT in init.c.

Simon Goldschmidt <goldsimon>
Group administrator
Thu 21 Jan 2016 04:28:01 PM UTC, original submission:  

The calculation in opt.h for TCP_SNDLOWAT results in a invalid configuration when TCP_SND_BUF is greater than 2*66535.

Due to limitations of tcp_write, tcp_sndbuf() is limited to returning 65535 (even with large send buffers) and when TCP_SNDLOWAT is greater than 65535, we will never pass any checks where tcp_sndbuf() is compared against TCP_SNDLOWAT.  This happens once the send buffer is full and then drains, but we never mark the netconn/socket as writable again.

I've changed the value of TCP_SNDLOWAT in my port, but it would be good to update the opt.h calculation to prevent this from happening when TCP_SND_BUF is tuned to be large

Joel Cunningham <jcunningham>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by goldsimon (Posted a comment)
  • -email is unavailable- added by jcunningham (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-02-18 goldsimon StatusNone Fixed
        Assigned toNone goldsimon
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code