aboutsummaryrefslogtreecommitdiffstats
path: root/test
AgeCommit message (Collapse)AuthorFilesLines
2021-04-28bump dpdk version to 20.05Konstantin Ananyev3-38/+38
Bump dpdk version to 20.05 and adjust tldk source. Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com> Change-Id: Id2ce864ad20b3b347f1ac05cd67c15384e454c52
2020-03-09test/memtank: extend with extra statsKonstantin Ananyev1-85/+281
- Add min/max cycles stat for alloc/free - Add stats after cleanup - dynamically calculate max objs based on '-w' and number of lcores - Remove code duplication Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com> Change-Id: I44748c76abadcb5adc5252fcc5120ccda01e6cd3
2019-12-31v6: make TCP stream alloc/free to use memtank APIKonstantin Ananyev2-1/+5
Introduce two extra parameters for TCP context creation: struct { uint32_t min; /**< min number of free streams (grow threshold). */ uint32_t max; /**< max number of free streams (shrink threshold). */ } free_streams; By default these params are equal to max_streams value (avoid dynamic allocation and preserve current beahviour). grow() is invoked from accept() FE call to refill streams tank for BE. shrink() is invoked from close() FE call. Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com> Change-Id: I7af6a76d64813ee4a535323e27ffbfd75037fc92
2019-12-31v6: memtank introductionKonstantin Ananyev3-0/+836
For analogy with mempool, named this structure memtank. Same a s mempool it allows to alloc/free objects of fixed size in a lightweight manner (not as lightweight as mempool, but hopefully close enough). The whole idea is that alloc/free is used at fast-path and don't allocate/free more than *min_free* objects at one call. So for majority of cases our fast-path alloc/free should be lightweight (LIFO enqueue/dequeue operations). Also user will need to call grow/shrink periodically (ideally from the slow-path) to make sure there is enough free objects in the tank. Internally it is just a simple LIFO for up to *max_free* objects plus a list of memory buffers (memchunk) from where these objects were allocated. v1 -> v2 - Added UT - Fixed few bugs v2 -> v3 - extend UT with more parameters v3 -> v4 - add object alignement as parameter for memtank_create - extend UT with more parameters - added memtank dump routine v4 -> v5 - fixed few bugs inside memtank lib - extend UT with: - new test case - new command-line options: '-s <obj_size>', '-m <mem_func>' v5 -> v6 - extend memtank dump to collect/display extra information - make memtank dump routine MT safe - add memtank sanity check function - add proper comments for pubic API Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com> Change-Id: I8939772577f5d9e293088eaa9a9fe316c3fe8f87
2019-06-14dpdk: move to v18.11 as default DPDK versionJianfeng Tan1-4/+5
DPDK v18.11 is the latest LTS verison. As of the API/ABI changes introduced in ether at v18.08, we cannot compile l4fwd and nginx with old DPDK versions. Change-Id: I225302d9a257e9bce4aa22ff84d76a57170e7eb7 Signed-off-by: Jianfeng Tan <henry.tjf@antfin.com> Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2019-05-22test/gtest: fix issue with CIKonstantin Ananyev1-3/+3
New googletest version changed default location of builded libraries. Update gtest Makefile to work with both locations. Change-Id: I4bddb257f1edef875c4675bb669b5d2308f6fe0f Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2018-02-09tldk: introduce versioning, follow DPDK notationv18.02Konstantin Ananyev1-0/+4
Change-Id: I9d83b254fa66ff72dd2faddf366f35ecda13a6ea Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2018-02-07tldk: make sure it builds/works with latest dpdk (17.11/18.02)Konstantin Ananyev4-19/+26
Change-Id: I460b88661656b64558b442c7800b4edc20ad4b56 Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2017-07-27- Introduce tle_tcp_stream_readv() and tle_tcp_stream_writev().Konstantin Ananyev3-6/+6
- Introduce flags for tle_ctx_param. - Introduce TLE_CTX_FLAG_ST - indicates that given ctx will be used by single thread only. - Introduce new parameters for tcp context: timewait - allows user to configure max timeout in TCP_TIMEWAIT state. icw - allows user to specify desired initial congestion window for new connections. -Few optimisations: cache tx.ol_flags inside tle destination. calcualte and cache inside ctx cycles_to_ms shift value. reorder restoring SYN opts and filling TCB a bit. Change-Id: Ie05087783b3b7f1e4ce99d3555bc5bd098f83fe0 Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com> Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
2017-05-15Added rte_ring wrapper functions to support dpdk-17.05 and older versionMohammad Abdul Awal2-2/+2
Change-Id: I5cfcff8be275ab2a2fb4ad6a62777a8cb88f425b Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
2017-05-09Merge "tldk_test: added copy command to makefile to make test_scapy_gen.py ↵Konstantin Ananyev4-2/+14
visible"
2017-05-09tldk_test: added copy command to makefile to make test_scapy_gen.py visibleKopec, TomaszX4-2/+14
Change-Id: Iedad6db1808a20d0bd00b9d23f489dffd3ef0a4b Signed-off-by: Kopec, TomaszX <tomaszx.kopec@intel.com> Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
2017-04-10tcp_stream_close issue fixed, added tcp_stream tests (FPP-350)Tomasz Kopec1-1/+1
Change-Id: I0332d1cc4ce3acc993da0037614f59102d059690 Signed-off-by: Tomasz Kopec <tomaszx.kopec@intel.com>
2017-02-28test/gtest: enable unit test with scapyMohammad Abdul Awal1-1/+1
Change-Id: I658b68c4a4cd5a28e3dd6c37bba6e8d96475a948 Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
2017-02-24Introduce first version of TCP code.Konstantin Ananyev23-194/+2670
Supported functionality: - open/close - listen/accept/connect - send/recv In order to achieve that libtle_udp library was reworked into libtle_l4p library that supports both TCP and UDP protocols. New libtle_timer library was introduced (thanks to Cisco guys and Dave Barach <dbarach@cisco.com> for sharing their timer code with us). Sample application was also reworked significantly to support both TCP and UDP traffic handling. New UT were introduced. Change-Id: I806b05011f521e89b58db403cfdd484a37beb775 Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com> Signed-off-by: Karol Latecki <karolx.latecki@intel.com> Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com> Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2017-02-22gtest: disable test_tle_udp_devMohammad Abdul Awal1-1/+1
Change-Id: I2433b70e380583bd112248a62b25894efc36dfa6 Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
2017-01-24Merge "tldk test: Update tle_dev unit tests"Konstantin Ananyev2-2/+31
2017-01-24tldk_test: fix add define for older gccDaniel Mrzyglod1-0/+10
In CentOS 7 __STDC_FORMAT_MACROS define was missing. Change-Id: I4d2a6d4984edb8be3c15b6ae9d6db7a5b578d1a4 Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com>
2017-01-19tldk test: Update tle_dev unit testsKarol Latecki2-2/+31
Added new unit tests for add_dev and del_dev. Also updated previous tests which were missing cleaning up of devices in cases where they were actually created. Change-Id: I6d91cac54b34d4419147c125b7a13b780e1cc001 Signed-off-by: Karol Latecki <karolx.latecki@intel.com>
2017-01-19Merge "tldk: fix possibility of tle_event_active() from DOWN to UP"Konstantin Ananyev1-0/+1
2017-01-19tldk: fix possibility of tle_event_active() from DOWN to UPKarol Latecki1-0/+1
Docstring in tle_event.h for tle_event_active() only describes possibility of activating event from IDLE state. Also re-added previously failing test case. Change-Id: Ib9e19b6b3e64cc2836337b6a86884f312df73858 Signed-off-by: Karol Latecki <karolx.latecki@intel.com> Signed-off-by: Mohammad Abdul Awal <mohammad.abdul.awal@intel.com>
2017-01-16tldk/gtest: Modify makefile to allow compiling with DPDK 16.04Karol Latecki1-2/+2
Change-Id: I1cfcbd3a62fae0964ef7f239cfdcdf5abe2f024d Signed-off-by: Karol Latecki <karolx.latecki@intel.com>
2016-10-21tldk: fix for positive errno return values in udp_ctl.cKarol Latecki1-5/+5
'Public' functions should return negative values. Change-Id: I88eaf76f882eee08a4198543d0c8531656530360 Signed-off-by: Karol Latecki <karolx.latecki@intel.com>
2016-10-21tldk: fix for wrong rte_errno value in event.cKarol Latecki1-1/+1
Change-Id: Ia4890e174fa5e19ccfaeb23c1ba3e3d69f841af7 Signed-off-by: Karol Latecki <karolx.latecki@intel.com>
2016-10-17test/gtest: fix stream open test-cases failKonstantin Ananyev1-1/+25
Update gtest code to spify lookup callback routinies at context creation. fixes 2fea8d3d522d31cb ("don't allow to open stream for unsupported family"). Change-Id: Idf89be22d60ee7e2707efab5f4c6abb0220f47a9 Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2016-10-07makefiles: don't assume that output and target is always the sameKonstantin Ananyev2-4/+4
Change-Id: I7d313c74e2daf4d75c5c11460bdb87737cd46851 Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2016-10-07tldk_test: Add TLDK unit testsDaniel Mrzyglod16-0/+1551
Unit tests for TLDK libtle_udp & libtle_dring libraries Change-Id: I6818c72ca0260f1af784e758bfe21118c395afcf Signed-off-by: Karol Latecki <karolx.latecki@intel.com> Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com>
2016-10-06Enable C++ files compilationKonstantin Ananyev1-1/+1
Change-Id: I28b180a6c91165049cd7cc58a64f1e5e1698da61 Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2016-07-07initial tle_dring implementationKonstantin Ananyev3-0/+593
The Dynamic Ring (dring) is a implementation of unbounded FIFO queue, that supports lockless bulk enqueue/dequeue for multiple producers/consumers. Internally it contains producer/consumer head/tail indexes (same as DPDK rte_ring), plus linked list of Dynamic Ring Blocks (drb)s. Each drb contains some metadata plus array of pointers to queued objects. It is a caller responsibility to provide sufficient number of drbs for enqueue operation, and manage unused drbs returned by dequeue operation. dring features: - FIFO (First In First Out) - Lockless implementation. - Multi- or single-consumer dequeue. - Multi- or single-producer enqueue. - Bulk dequeue. - Bulk enqueue. Change-Id: I3621c99c6b114a387036a397e79baa8d1588bdb5 Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>