summaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/tcp_input.c
AgeCommit message (Collapse)AuthorFilesLines
2020-08-03tcp: improve timestamp rtt accuracyFlorin Coras1-22/+21
- switch to using vlib_time as reference for timestamps - use us precision ticks for tcp but keep using ms precision for timestamps. As a result, srtt, rttvar and rto are now measured in us instead of ms. MRTT samples from timestamps are converted from ms to us (not accurate under ms) while high precision samples are used with us precision, i.e., they're no longer converted to ms precision samples. Type: improvement Change-Id: Ibda559575d9b4fdc85b0985264f7c865ff367e34 Signed-off-by: Florin Coras <fcoras@cisco.com>
2020-07-30tcp: process syn in fin-wait-2Florin Coras1-0/+1
Type: improvement Change-Id: I379ba4270dad56fb0a06427a43e97bed36bdaa13 Signed-off-by: Florin Coras <fcoras@cisco.com>
2020-07-29tcp: fix skipping RSTs in SYN_SENT stateIvan Shvedunov1-0/+1
Type: fix Signed-off-by: Ivan Shvedunov <ivan4th@gmail.com> Change-Id: Ieddf8f03fdd14e71efaf4c78fe5b7f0d15c5cf5a
2020-07-29tcp: process syn in close-waitFlorin Coras1-0/+1
Type: improvement Change-Id: I0cafe08d21e02094dda203c5eb60601b5953425d Signed-off-by: Florin Coras <fcoras@cisco.com>
2020-07-27tcp: fix tcp_connection_cleanup() with uninitialized elogIvan Shvedunov1-3/+7
This fixes TCP connection cleanup crash when TCP debugging is enabled. It could happen if session_stream_accept() returned an error. Type: fix Signed-off-by: Ivan Shvedunov <ivan4th@gmail.com> Change-Id: I0df08969d82bb0f44def81b9e47195bd15502831
2020-07-24tcp: fix synack elog crashFlorin Coras1-2/+3
The elog track, if enabled, must be initalized before synack is sent. Type: fix Signed-off-by: Ivan Shvedunov <ivan4th@gmail.com> Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I0c585f466c9a5cbc13af971ae4951b93f9913c5f
2020-07-23tcp: track pending timersFlorin Coras1-28/+0
Also removes delack timer and reuses the u32 for the pending timers list. Type: fix Ticket: VPP-1923 Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I4edbb72d5b2aa5e14f87659f49e675af1e834aca
2020-06-08tcp: improve rtt estimation with rate samplingFlorin Coras1-18/+29
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I25043da84b2f2b3f37024ecfedac535df3004ea5
2020-05-15misc: removed executable bits from source filesRay Kinsella1-0/+0
Identified and removed executable bit from source files in the tree. find . -perm 755 -name *.[ch] -exec chmod a-x {} \; Type: improvement Signed-off-by: Ray Kinsella <mdr@ashroe.eu> Change-Id: I00710d59fcc46ce5be5233109af4c8077daff74b
2020-04-17session tcp: track half open in app wrkFlorin Coras1-8/+10
Type: improvement Do extra checks when establishing an active connect and cleanup pending connects if application detaches. Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ibe9349db57b313ba2aa5ea3960ef5cf755f5098a
2020-04-09tcp: avoid regrabing error node in input and outputFlorin Coras1-10/+8
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I2dd0187d069783ac8bc445a70f99934d91ae0e63
2020-04-03session: improve error reportingFlorin Coras1-2/+4
Type: improvement Change-Id: I9dd850a1ce85b0adb5136233f176117e0ee38817 Signed-off-by: Florin Coras <fcoras@cisco.com>
2020-04-02tcp: explicit use of timer wheel in timer apisFlorin Coras1-17/+33
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I06120d43c15b2fa3f437ef235bf5f83ec2beb45e
2020-04-02tcp: move features to separate filesFlorin Coras1-863/+1
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ia477b8dba9266f47907967e363c11048e5cd95ab
2020-04-02tcp: count zero wnd enqueue attemptsFlorin Coras1-0/+4
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: If22bad96a9102bc4058d52fc8565bd6a14c3c66c
2020-03-20tcp: avoid spurious retransmit attemptFlorin Coras1-4/+2
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I6ce6fb0fe0ceb8a70b6a13e6a72fdb842bfded7a
2020-03-19tcp: move accept init to separate reusable functionFlorin Coras1-102/+54
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I5120eb321e9e2050eb64dca9e2dfb6256ff2b62d
2020-03-19tcp: force deschedule if no send space availableFlorin Coras1-0/+7
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Iae9f118f710153b6c0e390265039db7434e67ed8
2020-03-19session tcp udp: consolidate transport snd apisFlorin Coras1-1/+3
Type: improvement Use only one api to retrieve transport send parameters. Additionally, allow transports to request postponing and descheduling of events. With this, tcp now requests descheduling of sessions when the connections are stuck probing for zero snd_wnd Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I722c974f3e68fa15424c519a1fffacda43af050c
2020-03-19tcp: count dupacks with no sacksFlorin Coras1-1/+2
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ia2e29b4776c0f8df666da39a14c5ef2fa1693c21
2020-02-25tcp: handle cleanups without timersFlorin Coras1-7/+4
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ida896e9fbe83b4c76578b089bb3fd2bef5e07fd2
2020-02-22tcp: remove useless predictionSimon Zhang1-3/+1
Type: fix Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com> Change-Id: Ie2dc2653baec92347eb2cbcd197a2e5ec6a80c79
2020-02-19tcp: fix syn-sent resetFlorin Coras1-2/+2
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I2799ac9723ec3e7effe910bba401fc486c552cac
2020-02-14tcp: improve reset generation in reset nodeFlorin Coras1-5/+1
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I7a4a4a52c3e4ad47aabb2ef5f53a0e0bb7e71690
2020-02-12tcp: improve invalid packet handling in syn-rcvdFlorin Coras1-3/+6
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ie356b4d45d47e30c185caf2e66cdb16f1a97046f
2020-02-12tcp: postpone rst handlingFlorin Coras1-15/+123
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id09fa54cc5657b3b5616ea6a6180c1344b0141d4
2020-02-11tcp: fix input error countersFlorin Coras1-17/+30
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I87940d02813b66616f1944e41b16c8cc16f5dac0
2020-01-28session tcp: fix packet tracingFlorin Coras1-4/+4
Type: fix Change-Id: Ib823d016c64998779fb1d00b8aad3acb5e8340be Signed-off-by: Florin Coras <fcoras@cisco.com>
2020-01-16tcp: fix rxt delivered without sacksFlorin Coras1-1/+1
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I69c245cb0e3f6d599a3270a485fa0a5845cde8eb
2020-01-16tcp: fix listen node coverity warningFlorin Coras1-11/+12
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: If5ec3ec4f46d3840c2b3c3005f093b5dddefc289
2020-01-15tcp: fix tcp check tx offload issueSimon Zhang1-2/+6
Type: fix Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com> Change-Id: I3b8755831d762abf51e1cbe1b57024f9297de9a4 Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
2020-01-14tcp: handle ack advancement with no holes and renegingFlorin Coras1-1/+1
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I9afba8dc9e087b8c436fe568531c02614a577a7c
2020-01-08tcp: fix scoreboard assertFlorin Coras1-1/+1
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I3c70b331932708a1b773392e089aed9dba9b3b31
2020-01-08tcp: fix last sacked with no holesFlorin Coras1-0/+2
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id12b0a9b8bc47aef8b393544e5b4c8228ed6a606
2020-01-07tcp: fix duplicate sack whith renegingFlorin Coras1-6/+9
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I6f7fb91e059996ff702eb9c36e3abaed237fe221
2020-01-03tcp: fix rate samples for old acksFlorin Coras1-2/+24
Type: fix Change-Id: Ieab35bbfba81faae61b1267d8661df5195877824 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-12-27tcp: validate port reuseFlorin Coras1-3/+8
Type: fix Make sure existing connection is in time-wait Change-Id: I8e8bef151f81bcd589b4da0d4bf63cc59f9f451b Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-12-27tcp: Enable TCP timewait port useYu Ping1-1/+40
Improve host stack CPS test, and it help improve 10x performance Type: feature Change-Id: I6af61e0bad7c16ee2d30a1422cc46bb89f1cedb4 Signed-off-by: Yu Ping <ping.yu@intel.com> Signed-off-by: Yuwei Zhang <yuwei1.zhang@intel.com>
2019-12-23tcp: accept sack reneging as a cc eventFlorin Coras1-4/+4
Type: fix Change-Id: Iead1303ca3dec7593eb3ce54f291b82d94c821a4 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-11-20session tcp: support pacer idle timeoutsFlorin Coras1-40/+19
Type: feature To avoid excessive bursts, pacer must be provided with an estimated rtt for the connection. That's used to compute an idle timeout, i.e., time after which the bucket is reset to 1 mtu due to inactivity. For now, idle timeout is computed as 5% of the rtt. Change-Id: Ia0b752fe7b4ad0ce97b477fb886b0133a2321541 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-11-11tcp: improve lost rxt heuristicFlorin Coras1-32/+42
Type: feature - retransmit first unacked segment if newer retransmitted packets are acked - avoid spurious retransmits if recovery ends with sacked bytes Change-Id: Ic1b56d22e025822edb7609afb136e47440ea6032 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-11-08tcp: fix ip check in lookup validationFlorin Coras1-11/+17
Type: fix Change-Id: Ia18632c8fe22bdcfdf3cb48a4234f8703a7ac1d7 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-11-07tcp: fix retransmit with no sacksFlorin Coras1-2/+5
Type: fix Change-Id: I6f7df0d358f57f7feadb9b7a3fcffb99558b2af8 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-11-06tcp: validate the IP address while checking TCP connectionSrikanth Akula1-9/+31
Type: feature Along with the port information, we need to validate the IP address details as well. This is very useful in the case port re-use scenario Signed-off-by: Srikanth Akula <srakula@cisco.com> Change-Id: I11e1ebcd3e56aae47ac235a89606a83c928aa6bb
2019-11-05session tcp: refactor pacer timeFlorin Coras1-3/+1
Type: refactor Change-Id: Ic1c3e1f7987702cd88972acc34849dc1f585d5fe Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-11-05tcp: correct validity check return valueRyujiro Shibuya1-0/+1
Type: fix Signed-off-by: Ryujiro Shibuya <ryujiro.shibuya@owmobility.com> Change-Id: Ib59bf664d8da20516d8f16d716c5e8698675da4b
2019-10-29tcp: correct tcp connection lookup conditionRyujiro Shibuya1-7/+10
Type: fix Signed-off-by: Ryujiro Shibuya <ryujiro.shibuya@owmobility.com> Change-Id: Ibdbac568d5f765e6b5c959cab5e32dc33335064d
2019-10-23tcp: fix sack retransmit beyond snd_nxtFlorin Coras1-0/+6
Type: fix Ensure that sack retransmit logic does not try to inadvertently send new data. Change-Id: Idfda19643577d9c1b58e2af8d8283cabfbaf98e6 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-10-17tcp: avoid sending acks when data availableFlorin Coras1-1/+4
Type: fix Change-Id: I02e2cb2d349f9ddb2bfed040a08ca448f379d565 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-10-17tcp: fix mss flag in option parsingFlorin Coras1-1/+1
Type: fix Change-Id: Ib03151a097caf15e4e8285afea83d1b930a874b0 Signed-off-by: Florin Coras <fcoras@cisco.com>