net: tcp: Refactor in prep for SACKs
authorBarret Rhoden <brho@cs.berkeley.edu>
Fri, 14 Jul 2017 19:59:34 +0000 (15:59 -0400)
committerBarret Rhoden <brho@cs.berkeley.edu>
Fri, 21 Jul 2017 15:53:39 +0000 (11:53 -0400)
commit99f8cace6aa65006cb113cd0361c9bf61aa54af2
tree270a24f33979a60c44bfc67f948214b3b516d4f8
parentf575f97158b2028e6e43f6bc55668d0a79c13daf
net: tcp: Refactor in prep for SACKs

There were various things with the old code that made it hard to extend.
I added helper functions, clarified how flgcnt sent/ssize works, and
pulled out the recovery code enough so that I can add SACKs.

I also renamed snd.ptr.  It still does mostly what it did before.  In the
future, it will be used for retrans, but now it is also used for the
'leading edge' of new packets.

Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
kern/src/net/tcp.c