aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet
AgeCommit message (Collapse)AuthorFilesLines
2019-10-03session: fix unbind coverity warningFlorin Coras1-0/+7
Type:fix Change-Id: If4fce6bd9b06ed545d72df847afd6a74cdefe042 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit eef61bb81a22f4c61c01e5afc8bd3b8612a71534)
2019-10-03ipsec: add insecure option for format of SAChristian E. Hopps3-3/+9
If specified, shows keys, otherwise redacts. This change sets this flag in the existing CLI code (thus maintaining the old behavior). The use case for not specifying the insecure flag (and thus redacting the keys from the show output) is for log messages. Type: feature Signed-off-by: Christian E. Hopps <chopps@chopps.org> Change-Id: I8c0ab6a9a8aba7c687a2559fa1a23fac9d0aa111 (cherry picked from commit 01d61e7881432a2c508fecbbab804d9c776abe1a)
2019-10-03udp: do not send received packets to error-dropAloys Augustin1-192/+173
This tends to pollute the error counter. Type: fix Signed-off-by: Aloys Augustin <aloaugus@cisco.com> Change-Id: Idb628e767b074a5ee7e00d001bc88c378d7b8d0b (cherry picked from commit 8fadb658a1b91a92f174fcf29a3620b644d8fe21)
2019-10-03session: fix cleanup in closing statesFlorin Coras2-3/+3
Type: fix Change-Id: Iccc283bb98d3bb459a711ec2b74d6a32ad12903b Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 54c93cfc2556d9c6d2cf472f51d4c2866a556ef6)
2019-10-03fib: fix some typos in fib/mtrieLijian.Zhang19-34/+34
Type: fix Change-Id: I1af0e4a9bc23a3b6b6d3a74df093801ab6cae1f8 Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com> (cherry picked from commit 33af8c1ed89f15cf0601ee891e9603bef16f2c93)
2019-10-03ip: refactor reassemblyKlement Sekera10-829/+872
this is a preparation step for introducing other reassembly types Type: refactor Change-Id: I197e299dbd729b00eead31667913b8ceff915d63 Signed-off-by: Klement Sekera <ksekera@cisco.com> (cherry picked from commit 896c896a3c4ed563a270281ff8b50fd253f4833f)
2019-10-03vlib: add flag to explicitelly mark nodes which can init per-node packet traceDamjan Marion10-0/+10
Type: feature Change-Id: I913f08383ee1c24d610c3d2aac07cef402570e2c Signed-off-by: Damjan Marion <damarion@cisco.com> (cherry picked from commit 7ca5aaac10e95306f74ea4afd52110dd46aa0381)
2019-10-03classify: remove includes from classifier header fileDamjan Marion7-10/+7
Type: refactor Change-Id: I6f0af1c3078edce1c1b29a8b99c4a232d7084d33 Signed-off-by: Damjan Marion <damarion@cisco.com> (cherry picked from commit 864d857c6c223be8ec11c588d65e8c5c2e211814)
2019-10-02ip: mfib CLI 'via local' fixNeale Ranns1-0/+2
Type: fix Change-Id: I6fd7bb27b95a50d37424f65dc51e8b341f8b1b28 Signed-off-by: Neale Ranns <nranns@cisco.com> (cherry picked from commit eacc8c5943e44d19b5a65a68db3ad5adf9e37495)
2019-10-02session: validate connection in session lookup delFlorin Coras1-1/+1
Type: fix Change-Id: I4e2617f99064c5a96e4debae8b68716ca129ee73 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit e1e7fb88e47b0ec99d32ea0391d969542960391a)
2019-10-02tcp: use sacks for timer based recoveryFlorin Coras9-278/+337
Type: feature If available, reuse sack scoreboard in timer triggered retransmit to minimize spurious retransmits. Additional changes/refactoring: - limited transmit updates - add sacked rxt count to scoreboard - prr pacing of fast retransmits - startup pacing updates - changed loss window to flight + mss Change-Id: I057de6a9d6401698bd1031d5cf5cfbb62f2bdf61 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 36ebcfffbc7ab0e83b4bb8dfaec16bf16cafb954)
2019-10-02ip: fix memory leak in ip_dump handlerMatthew Smith1-0/+2
Type: fix A vector allocated by vl_api_ip_dump_t_handler() was not being freed. Change-Id: I13425b8087e60df60c6aaa1230aa7e6d60b101a8 Signed-off-by: Matthew Smith <mgsmith@netgate.com> (cherry picked from commit 6d5f6592559bc0db4294c53236177d4e35e603c6)
2019-10-01session: avoid transport cleanup if previously deletedFlorin Coras1-2/+3
Type: fix Change-Id: I485d38c7d9473e2ad1cbd8e17a788ec8d29ab001 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit cac31a4a23241eb94e6982c049c0feb8b180c868)
2019-09-30session: move ctrl messages from bapi to mqFlorin Coras9-106/+675
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-30tcp: fix unformat cwnd multiplierFlorin Coras1-16/+18
Type: fix Change-Id: Ife4e650cb8b16f84ca6f77ba7b1d17a0f452fc3f Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 1df833e6deecaa1ca68d6e98af7fb109fc0ca18a)
2019-09-30fib: do not dump no-longer valid adjacenciesBenoît Ganne4-3/+23
In some cases, we can refer to no-longer adjacencies (eg. in traces). Do not dump them in this case as they are probably incorrect (memory can be reused). Type: fix Change-Id: Ib653ba066bb6595ec6ec37d313a3124bce0eeed3 Signed-off-by: Benoît Ganne <bganne@cisco.com> (cherry picked from commit 138c37af5291e2045075052a4db036be03be4a85)
2019-09-30session: fix msg freeing on errorNathan Skrzypczak2-13/+7
Type: fix Change-Id: I0807f84737d5e98e69e9ed27a1de6813b2ddd138 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> (cherry picked from commit 1afa7afffad6e296a97556aa4c9482f4cd544074)
2019-09-30tcp: refactor congestion event handlingFlorin Coras1-40/+36
Type: refactor Minor cleanup to congestion event handling. Change-Id: I7179ff9e21c1853382ba814652c9024f3e5b8a37 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit afef8bf22369d10ab8107a63b1e3529ed7dd6c8d)
2019-09-30session: builtin app rx notifications regardless of stateFlorin Coras1-3/+5
Type: feature Provide rx notifications to builtin apps even after disconnect. Consequently tcp connections that are past FIN_WAIT_1 can still receive rx notifications. This is not currently supported for external applications. Change-Id: I529da7f7120b0e7c62c5026ac71f86d6b5196cf4 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 5c29029ef029edc96340f9eecf7fe24821f2ef2a)
2019-09-30tcp: compute snd time for rate sampleFlorin Coras2-6/+11
Type: feature Change-Id: I6bd675dc28dbc34293e895911efe986844c0564f Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 7436b436733ea7217e745f3cc9971aaff1e3dfa4)
2019-09-30session: limit pacer bucket sizeFlorin Coras2-2/+4
Type: feature Change-Id: I3ca27b09670716eba463d7b16771f765a1bd6dcd Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 7c8f828ba353472e27369a77574bca532147e458)
2019-09-30http_static: add dynamic GET / POST method hooksDave Barach1-3/+40
Add .json output to format_vnet_sw_interface_cntrs(...) Type: feature Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: Ied036ebfaaafbf1dfc2a4e396c00f09f40659400 (cherry picked from commit 5554c56a65cff3ef90844eb5e63d89283fae74df)
2019-09-30session: add session enable option in config fileNathan Skrzypczak1-0/+2
Type: feature Change-Id: I8f02873e75c6e890f6749806d4f02547f951c8ca Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> (cherry picked from commit 1292d19c79c2fd4f09ffcc43ebf39f5d9d485c35)
2019-09-30session: fix session filter rangeFlorin Coras1-1/+1
Type:fix Change-Id: I173f45bf3d90e6979675b2ac812a969539f02147 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 61a89f2b614184eeced3f67affed959897d4da18)
2019-09-30stats: add /if/<n>/<n>/state for lacp interface stateSteven Luong2-2/+31
Add /if/lacp/<bond-sw_if_index>/<slave-sw_if_index>/state <bond-sw_if_index> is a vector of the bond sw_if_index <slave-sw_if_index> is a vector of the slave sw_if_index Content is the integer value of the lacp actor state. The state is actually a bitfield as described in the lacp protocol spec. Type: feature Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: Ic6eca8ce2a1acd2d858e4e50b7eac1d000ea08e5 Signed-off-by: Ole Troan <ot@cisco.com> (cherry picked from commit 0f09a828ad2dc53d4f1e69de536f3104eaccc4b0)
2019-09-30session: improve cliFlorin Coras6-145/+345
Type: feature Allow session cli filtering based on thread index, transport protocol, session state and range of session pool indices. For instance show session thread 1 proto tcp state ready range 0 20 verbose Shows the session ids for the first 20 tcp sessions in thread 1 that are in ready state. To avoid excessive output that could reasult in the worker barrier being held by the main thread for long periods of time, the session cli will only output: - session ids (verbose == 1) for a maximum of 50 sessions / worker - verbose > 1 details for a maximum of 10 sessions Change-Id: I2cfb351b548e2e0a1d5b4345810be613e2917d17 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 5bb23ecd098eac639641e2b3d62eb8744e0efef0)
2019-09-29tcp: use rate sample rtt in recovery if possibleFlorin Coras1-6/+14
If in recovery and rate samples are taken for burts that have not been retransmitted, use the rtt estimate. Type: feature Change-Id: I95028f492008457c959157aa4ee4c3435fa9c3f0 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 1dbda64b467f020db131cb9a01422b8f3fbf58df)
2019-09-29tcp: cleanup scoreboard after recoveryFlorin Coras1-0/+7
Type: fix When recovering from congestion, remove last hole in scoreboard if it covers all bytes sent above snd_congestion. Change-Id: I752accd4590cd9bf553c35a1bb40a38c308c04f5 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 321cfa5fcb8f347329a5296e2024ef0e6cef319f)
2019-09-29tcp: handle sack renegingFlorin Coras3-92/+126
Type: feature Change-Id: I201155b1b92cf7e57310af726879dab039090582 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 558e3e09577a7b49e2fec58e8ac27f3f3ae0592f)
2019-09-29tcp: enable gso in tcp hoststackSimon Zhang6-3/+89
Type: feature Change-Id: If68d07fbe8c6f7fffd2f93c7e854367082927e4f Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com> (cherry picked from commit 1146ff4bcd336d8efc19405f1d83914e6115a01f)
2019-09-29tcp: cc algos handle cwnd on congestion signalFlorin Coras3-12/+11
Type: refactor Change-Id: I15b10a22d0d0b83075a0eef5ef8c09cf76989866 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 8b4114e52f69b9292efb282e49ed4d90699ceeb8)
2019-09-29tcp: send rwnd update only if wnd is large enoughFlorin Coras3-7/+15
Type: feature Change-Id: I3e97e05a31806afb6b2e84ecf05fb96d285db92e Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 017dc45243bad1b3708d0a9b902d23ca47859344)
2019-09-29tcp: force zero window on full rx fifoFlorin Coras1-1/+4
Type: feature Change-Id: I7c5684a9f88e56fd62d83a59c14c4e4a6f096b89 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 182d2198332c2a20891a7cdbceeaaf62b47924e8)
2019-09-29tcp: validate connections in outputFlorin Coras1-9/+46
Type: feature This shouldn't happen unless connections are removed after buffers were enqueued to tcp-output and before tcp-output runs. For instance, packet is enqueued to tcp output and cleanup is called for connection. Change-Id: Ib7dd82ffa6cfb21ff5068aba010e0a3497eeea13 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 78dae00881d26b205ee6721ce8c2bcae76996e79)
2019-09-29ethernet: move dmac filtering to inline functionMatthew Smith1-56/+63
In eth_input_process_frame(), destination MAC addresses are compared to the interface hardware address in a loop. Move this to a separate inline function to facilitate making changes to the filtering logic more cleanly. Type: refactor Change-Id: I0978f01667e78af5214dbbc9ba223f5b84ce6b7e Signed-off-by: Matthew Smith <mgsmith@netgate.com> (cherry picked from commit fa20d4c5375c02f61e565b5fc57c490145bc0919)
2019-09-29session: avoid bihash list for session tablesFlorin Coras1-12/+38
Type: fix Change-Id: I1dbc822061f43fcc25dfa5d1728f5c7575139f45 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 27eeb87f43d9d9dfab3d807f33fc5a4a68cb55d9)
2019-09-29tcp: fix rx min/max fifo size parsingFlorin Coras1-13/+14
Type: fix Change-Id: Iff4a13da654dbdf7f08bb6d0743b466a1e6be01b Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 4e1fcf49057b6bd9b4a3a32a8da20a721536c247)
2019-09-29tcp: improve mss computationFlorin Coras3-43/+48
Type: fix Use different mss for v4 and v6 packets. Change-Id: Ifcd322c1fd74f749a42bae671dd6cfed8c32b150 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit cedcf608fefc5bdeff13bb0914fa15266e971d7c)
2019-09-29session : make sure session layer is enabled when cli operate the sessions.Guanghua Zhang1-0/+4
Type: fix show session rules tcp vpp/src/vnet/session/application_namespace.c:34 (app_namespace_get) assertion `! pool_is_free (app_namespace_pool, _e)' fails Thread 1 "vpp_main" received signal SIGABRT, Aborted. Signed-off-by: Guanghua Zhang <ghzhang@fiberhome.com> Change-Id: I3430339a598a92d0a38826471adeb4547b0b7df4 (cherry picked from commit fcd5e12b1c879b27d9ed53c9c5b3ae98b0a04ccf)
2019-09-28ipsec ip tcp l2: multiarch nodes cannot be declared as staticDamjan Marion8-15/+15
Credits to ray.kinsella@intel.com who spotted the issue and identified root cause. Type: fix Change-Id: I4afe74c47769484309f6aebca2de56ad32c8041f Signed-off-by: Damjan Marion <damarion@cisco.com> (cherry picked from commit d770cfc96257f9bd9e0c96c8ebe50e4531dc1bc5)
2019-09-28session: move svm_fifo_clear_deq_ntf to before calling the app callbackVladimir Kropylev1-2/+2
Type: fix in case the app requests another dequeue notification, it should not be cleared Change-Id: I7e94e8e30ef098f87f5e7f4880af276970ee5b37 Signed-off-by: Vladimir Kropylev <vladimir.kropylev@enea.com> (cherry picked from commit 5c89fbf28665d13a0052fc88288c1524e0e93918)
2019-09-28devices: fix issue of per_interface_next_indexMichael Yu1-3/+4
Per interface, next hop graph node can be customized with vnet_hw_interface_rx_redirect_to_node function, but it doesn't work well for af-packet type interface. In current implementation, with function af_packet_set_interface_next_node invoked next hop graph node index can be set to apif->per_interface_next_index, but it's not set to next0 properly for packet processing in af_packet_device_input_fn. Type: fix Signed-off-by: Michael Yu <michael.a.yu@nokia-sbell.com> Change-Id: I8e132ddd1c3c01b6f476de78546d4a9389b3ff87 Signed-off-by: Michael Yu <michael.a.yu@nokia-sbell.com> (cherry picked from commit 90b34ed67a516c4391ad353ba431f8419b582d50)
2019-09-28tcp: track zero rwnd errorsFlorin Coras2-1/+9
Type: feature Distinguish between rcv window errors and errors after we advertised a zero rcv window, i.e., potential window probes. Change-Id: I6cb453c7aaae456c0a05a8328cfaa55eaca10bf7 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit a495a3ea146a8484dac9f6b594fb2b044437c7a4)
2019-09-27ip: remove unused function parameterSimon Zhang6-17/+12
Type: refactor Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com> Change-Id: I8674ff5f6f6336b256b7df8187afbb36ddef71fb (cherry picked from commit e7eba48937c52478d3844745ebb63a4b9ce8d681)
2019-09-27svm: fix fifo hdr freelist allocationFlorin Coras1-0/+2
Type: fix Change-Id: Ia362ad821db1fd506e973e1844cc3ec74703cc17 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 73cad33b56ffc08943e9c0d73ecb14466558baae)
2019-09-27tap: fix tap interface not working on Arm issueLijian.Zhang1-1/+6
The VPP code tries to set all userspace memory in the table via IOCTL to VHOST_SET_MEM_TABLE. But on aarch64, the userspace address range is larger (48 bits) than that on x86 (47 bits). Below is an segment from /proc/[vpp]/maps. fffb41200000-fffb43a00000 rw-s 00000000 00:0e 532232 /anon_hugepage (deleted) Instead of setting all userspace memory space to vhost-net, will only set the address space reserved by pmalloc module during initialization. Type: fix Change-Id: I91cb35e990869b42094cf2cd0512593733d33677 Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com> Reviewed-by: Steve Capper <Steve.Capper@arm.com> (cherry picked from commit ba0da570f264785f6b50eff7829f6653c0924069)
2019-09-25misc: improve pcap drop trace outputDave Barach1-0/+54
Append <nodename>: <error-string> to pcap drop traces. The data displays perfectly fine in [vanilla] wireshark, and makes it 100% obvious which node dropped the packet, and why. Type: feature Ticket: VPP-1776 Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I9b964b99da4011b93723354db6ef0b128fca20cb (cherry picked from commit 9382ad9b390e17c8bfd8229342656348d059becb)
2019-09-25misc: unify pcap rx / tx / drop traceDave Barach4-229/+152
Use a single vnet_pcap_t in vlib_global_main, specifically to support unified tracing Update sphinx docs, doxygen tags Type: refactor Ticket: VPP-1776 Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: Id15d41a596712968c0714cef1bd2cd5bc9cbdd55 (cherry picked from commit 33909777c63712ca397165cd92e7cc62208eb5c8)
2019-09-25interface: fix pcap drop trace in case of vlanBenoît Ganne1-1/+12
Type: fix Change-Id: If3c4e5c376b51a26143d8922dcacfbda534163bd Signed-off-by: Benoît Ganne <bganne@cisco.com> (cherry picked from commit 4e323cbdbd57fcd77db68e295f639288441ef3e3)
2019-09-25misc: classifier-based packet trace filterDave Barach8-7/+449
See .../src/vnet/classify/trace_classify.h for the business end of the scheme. It would be best to hash pkts, prefetch buckets, and do the primary table lookups two at a time. The inline as given works, but perf tuning will be required. "At least it works..." Add "classify filter" debug cli, for example: classify filter mask l3 ip4 src dst \ match l3 ip4 dst 192.168.2.10 src 192.168.1.10 Add "pcap rx | tx trace ... filter" to use the current classify filter chain Patch includes sphinx documentation and doxygen tags. Next step: device-driver integration Type: feature Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I05b1358a769f61e6d32470e0c87058f640486b26 (cherry picked from commit 9137e5400699bed9f7c0095187839a8b38273100)