aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/session_node.c
AgeCommit message (Collapse)AuthorFilesLines
2020-08-13session: fix use-after-free in input nodeBenoît Ganne1-1/+2
Type: fix Change-Id: Ie60b07abe76ad166f048f5885accd7038d8153b2 Signed-off-by: Benoît Ganne <bganne@cisco.com> (cherry picked from commit 7ce23f25bbc01d534ca294ce88ab0d709e3e03a7)
2020-08-12session: avoid scanning new io list under loadFlorin Coras1-21/+9
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Idaa7cc26ad941be86daec4ed5920727237712f4a (cherry picked from commit 16d974ec59776f0103ad62d0d04dc57989eef7ed)
2020-08-12session tcp: fix packet tracingFlorin Coras1-2/+2
Type: fix Change-Id: Ib823d016c64998779fb1d00b8aad3acb5e8340be Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 30928f87a3c9d98e288d1364d50c032e052e69ab)
2020-08-12session: fix node runtime in pre-input queue handlerFlorin Coras1-0/+1
Call session queue node with the right node runtime instead of the pre-input node runtime. Type: fix Change-Id: I43d20bed4930fc877b187ce7ecdce62034b393c5 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 2d8829cbb5f3d214fbc09bf4258573659e0c5e60)
2020-08-12session: remove io event dispatch dbg msgFlorin Coras1-4/+1
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I166ab7b96444587a3252925d3a28505e0db52d74 (cherry picked from commit 87b0c892947006cbfa80fd2af15e8edb4029f327)
2020-08-12session: close for reset replies independent of stateFlorin Coras1-2/+2
Type: fix Change-Id: I8b8875f1dc9203dfbb443ac43df8250cbb0b1edc Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit f1910326d537ad7692d4a9b807ebbef93106acea)
2020-02-06session: re-set tx fifo event if out of buffersFlorin Coras1-1/+2
Type: fix Change-Id: I7416e827fbc5c63d082273656441c81dd6246d8a Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit aa43914df656bbd7340b8dbd68f23f8fe0aabfd5)
2019-11-28session tcp: refactor pacer timeFlorin Coras1-7/+3
Type: refactor Change-Id: Ic1c3e1f7987702cd88972acc34849dc1f585d5fe Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit a8e71c8981f039588a7ca94e6ab66b4ebac784a5)
2019-11-18session: unify buffer tx dispatchingFlorin Coras1-26/+11
Type: refactor Use pending tx buffer vector to postpone dispatching of all buffers, i.e., either generated as a result of tx events or custom tx event. Change-Id: Ic5894c4653c338cfb04555d20857f954b245ee83 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 8a754f1a55fb16a4d42efd5c606e5a07b4afffe9)
2019-11-18session: reschedule asap when snd space constrainedFlorin Coras1-7/+20
Type: feature Improves fairness for sessions that are snd space or pacer constrained. Change-Id: Ida5f523090f1dcbfb17bf5116bc7917747ac8593 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit dd97a48d9fac91c7f16a31aa661dd6c968c3b760)
2019-11-18session tcp: infra for transports to send buffersFlorin Coras1-0/+14
Type: feature Add infra that allows transpors to enqueue pending buffers without the need to build and manage their own pending frames. An important benefit is the fact that buffer wire/tx ordering is ensured by session layer. Change-Id: I764fd1693d610b321a1d0c84b648a314f14583db Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 2a7ea2ee92d6dc4800ee21323d3324a9e8449dcf)
2019-11-15session: avoid double dispatch of new eventsFlorin Coras1-14/+17
Type: fix Avoid re-dispatching new events if they've just been added to the old events linked list. Change-Id: Ie5d0b799eae6cebb118d97204e5111eb194c0b8e Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 45b7973dddc9f1b50d7f20cc1abe150b2ad9931f)
2019-11-15vcl: add api to set lcl ipFlorin Coras1-0/+1
Type: feature Change-Id: I40169fbbe8a20670dd612c341b6c78b5c925bf74 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit ef7cbf6adf1882af4d4ae8657632d4a2a59efcb2)
2019-11-05session: avoid old io dispatch if no slots left to sendRyujiro Shibuya1-2/+3
Type: fix Signed-off-by: Ryujiro Shibuya <Ryujiro.Shibuya@owmobility.com> Change-Id: I8e1f6cbd905ad5c21aed1b2e358540d0fbd7fc47 (cherry picked from commit 2a1118411deed799e079bf34d3f6d8bccb37f8c5)
2019-10-29tcp: improve pacing after idle send periodsFlorin Coras1-1/+7
Rest pacer on ack reception if we haven't recently sent anything. Type: feature Change-Id: I820bacd81b65130052dfafbfcbe6ca4553069fbc Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit c31dc31f84961033ecb6354811e0c360b6cf5f79)
2019-10-27tcp: retry lost retransmitsFlorin Coras1-4/+18
Add heuristic that detects lost retransmitted segments and retries sending them. Type: feature Change-Id: I34d1bb16799e1993779222eb2bfad4b40704159e Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit be237bf02382854118986e8ea84c7544e42023f2)
2019-10-04session: Fix missing elt regrabNathan Skrzypczak1-0/+1
Type: fix Change-Id: Ie756c5477d989702e633aa0d42ca154ff32b4c9a Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> (cherry picked from commit 19e52c96dcd5f523c2b97aee56cb2e7751d4690a)
2019-10-03vlib: add flag to explicitelly mark nodes which can init per-node packet traceDamjan Marion1-0/+1
Type: feature Change-Id: I913f08383ee1c24d610c3d2aac07cef402570e2c Signed-off-by: Damjan Marion <damarion@cisco.com> (cherry picked from commit 7ca5aaac10e95306f74ea4afd52110dd46aa0381)
2019-09-30session: move ctrl messages from bapi to mqFlorin Coras1-53/+319
Type:refactor Moves connect, disconnect, bind, unbind and app detach to message queue from binary api. Simplifies app/vcl interaction with the session layer since all session control messages are now handled over the mq. Add/del segment messages require internal C api changes which affect all builtin applications. They'll be moved in a different patch and might not be back portable to 19.08. Change-Id: I93f6d18e551b024effa75d47f5ff25f23ba8aff5 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 458089bbad9cf5bef6cf8119f23fc44e66b36ad3)
2019-09-20session: add explicit reset apiFlorin Coras1-0/+6
Type: feature This can be used to forcefully close a session. It's only available to builtin applications for now. Transports must support the reset api otherwise normal close is used. Change-Id: I5e6d681cbc4c8045385e293e0e9d86fa2bf45849 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit dfb3b8771292e4c863ca266856aa2b5eb7cc7518)
2019-08-09session: allow closed transports to sendFlorin Coras1-4/+16
Type:fix Transports like tcp may notify session layer of a close but they may defer the connection's deletion (e.g., tcp time-wait). During that time, transports may still want to send packets. So, unless the session has no transport (transport-deleted state), allow the transport to send. Change-Id: I3ae335c7b951ff64be8529a5e3f3ad790feddc84 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit a678974cc52ac61dd6094c3f6649f9e3202be1cb)
2019-08-05session: cache align transport base classFlorin Coras1-1/+1
Type:refactor Also remove tx stats. Expectation is that transports will keep track of them. Change-Id: I083b328d87d0ad3688b630ddb5ef97827a4dbc2b Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-29session: fix vpp to app msg generationFlorin Coras1-6/+3
Type:fix Freeing mq messages in vpp (producer), if enqueueing fails, invalidates consumer assumption that messages can be freed without a lock. Change-Id: I748a33b8846597bdad865945d8e899346d482434 Signed-off-by: Florin Coras <fcoras@cisco.com> Signed-off-by: Tal Saiag <tal.saiag@gmail.com>
2019-07-26session: separate ctrl, new and old eventsFlorin Coras1-48/+76
Type: feature Change-Id: I5e030b23943c012d8191ff657165055d33ec87a2 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-26session tcp: handle rxt and acks as custom eventsFlorin Coras1-4/+19
Type: feature Control ack generation and retransmissions with session layer scheduler. Change-Id: Iacdf9f84ab81f44851980aa45a83e75f29be2b7b Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-23session: reorganize dispatch logicFlorin Coras1-132/+129
Type:refactor Change-Id: Id796d0103e61e15c35a586d8cbd3d8916487b84d Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-23session: avoid postponing closeFlorin Coras1-14/+0
Type: feature Change-Id: I96e850fc15b79349abbb52d91c0314f255d635be Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-19session: improve event loggingFlorin Coras1-13/+5
Type:feature Change-Id: I67a52ee48963a66915e2ebd116626eb9c296a9a5 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-17session: use llist in session node evt handlingFlorin Coras1-43/+61
Type: refactor Change-Id: I24159e0a848f552b4e27acfb5fe6f2cd91b50a19 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-07-09tcp: remove warning for multi-seg scnario.Simon Zhang1-1/+0
Type: fix Change-Id: I64e2082bd8ac5b0be21e10407dc29ba4c3f4cab3 Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
2019-06-29svm: rename fifo tx notifications to reflect useFlorin Coras1-1/+1
Type: refactor Change-Id: I651db44acdcb666a9c63e1037352cf88c68795b5 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-06-27session: Add transport vft protocol optionsNathan Skrzypczak1-4/+6
Type: refactor Change-Id: I4e0afc206e4871596c2ed8a6ca00914a379f1526 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-05-08session: send tx events when data is dequeuedFlorin Coras1-10/+5
Change-Id: Ib8cb19361c42e38e3f68d7147358378fff161eb1 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-30svm: more fifo refactor/cleanupFlorin Coras1-4/+4
Change-Id: Ie76c69641c8598164d0d00fd498018037258fd86 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-17vcl/session: tx notifications for cut-thru sessionsFlorin Coras1-0/+7
Change-Id: I076c753e419bbb177d2d28609190715e9895b398 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-16svm_fifo rework to avoid contention on cursizeSirshak Das1-4/+6
Problems Addressed: - Contention of cursize by producer and consumer. - Reduce the no of modulo operations. Changes: - Synchronization between producer and consumer changed from cursize to head and tail indexes Implications: reduces the usable size of fifo by 1. - Using weaker memory ordering C++11 atomics to access head and tail based on producer and consumer role. - Head and tail indexes are unsigned 32 bit integers. Additions and subtraction on them are implicit 32 bit Modulo operation. - Adding weaker memory ordering variants of max_enq, max_deq, is_empty and is_full Using them appropriately in all places. Perfomance improvement (iperf3 via Hoststack): iperf3 Server: Marvell ThunderX2(AArch64) - iperf3 Client: Skylake(x86) ~6%(256 rxd/txd) - ~11%(2048 rxd/txd) Change-Id: I1d484e000e437430fdd5a819657d1c6b62443018 Signed-off-by: Sirshak Das <sirshak.das@arm.com> Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
2019-04-02session: use app cb function wrappersFlorin Coras1-3/+2
Change-Id: I77ad9eb4d4c7699397aa4be6a973ef37c60db4c5 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-11tls: fixes and improvementsFlorin Coras1-3/+1
- disconnect sessions through session layer apis instead of directly notifying the app worker. - improve cli - increase fifo sizes for tls app Change-Id: I8a7d2865b3b00724e2a9da29fa4a906ea867da9b Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-08session/tcp/vcl: fixes and optimizationsFlorin Coras1-0/+1
Change-Id: Idc7dfe743399dd8dee0f6b3ec83f194f3fca580b Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-07session: use transport custom tx for app transportsFlorin Coras1-3/+1
Change-Id: I675f7090fa6b2ffdfb4ee748df858bfb7e39ce5a Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-06session: use session index instead of fifo for evtFlorin Coras1-3/+3
Avoids derefrencing fifo pointers whose segments could have been unmapped. Change-Id: Ifb0b7399e424f145f3f94b769391a6f4e31bb4e6 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-06session: use vpp to switch io events for ct sessionsFlorin Coras1-1/+21
Instead of allocating pairs of message queues per cut-thru session and having the applications map them, this uses vpp as an io event message switch. Change-Id: I51db1c7564df479a7d1a3288342394251fd188bb Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-02session: cleanup/rename functionsFlorin Coras1-13/+13
- remove unused functions - rename old "stream" functions Change-Id: Icbb03daa9f9f1c58b5be5c38aa8a9cbcf9159b47 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-02session: cleanup session event typesFlorin Coras1-18/+18
Change-Id: I87bdf705341dd760f0be907a663aa64140977d39 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-03-01session: refactor local connectsFlorin Coras1-28/+32
- Switches local connects to cut-thru transport - Removes local sessions as a separate session type Change-Id: I997c6355d8c8e4f2110678f785b0f5d96bba47f7 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-02-23session: separate local session logicFlorin Coras1-0/+1
Move local session to separate header and source files. First step to refactoring local sessions. Change-Id: I280fdfef20ba8a0977d15c1c8ce030ea2fb72dde Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-02-09buffers: fix typoDamjan Marion1-1/+1
Change-Id: I4e836244409c98739a13092ee252542a2c5fe259 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-02-06buffers: make buffer data size configurable from startup configDamjan Marion1-1/+1
Example: buffers { default data-size 1536 } Change-Id: I5b4436850ca18025c9fdcfc7ed648c2c2732d660 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-02-06transport: cleanupFlorin Coras1-4/+5
- move transport specific types to transport_types - add transport wrapper functions for interaction with transport protocol vfts Change-Id: I93f70d884585fc2f41c4a605e310c80e8a8972f2 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-02-05session: cleanup part 2Florin Coras1-2/+2
Move app worker logic to app_worker.c Change-Id: Ic5e5735b2884f006c064d023f491aa6888114810 Signed-off-by: Florin Coras <fcoras@cisco.com>