aboutsummaryrefslogtreecommitdiffstats
path: root/src/vppinfra
AgeCommit message (Collapse)AuthorFilesLines
2024-02-13vppinfra: Only prealloc hugepages on LinuxTom Jones1-0/+2
FreeBSD doesn't support sysfs or preallocating hugepages directly. In lieu of refactoring clib_sysfs calls place this one behind an #ifdef linux. Type: improvement Change-Id: I4079ca70175e4cec44d913db2b0407a3ca6306c9 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-02-13vppinfra: Don't build perfmon on FreeBSDTom Jones1-3/+4
FreeBSD has platform specific APIs for interfacing with performance counters. Until we bring in FreeBSD support, don't build perfmon on platforms which aren't linux. Type: improvement Change-Id: Iabc418922c0d2e851c6098508761135f53433ae8 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-02-13vppinfra: Place SIGPWR behind a linux defineTom Jones1-0/+2
The SIGPWR signal is specific to Linux, place it behind a Linux flag to help the build on FreeBSD. Type: improvement Change-Id: Ie36c2ceb201afff98e92bbe64595c3953b11c457 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-01-23vppinfra: fix clib_array_mask_u32 OOB readsDmitry Valter2-7/+28
Handle non-even n_elts for the larger array instead of reading past the source buffer. Type: fix Fixes: f62ed3f9c1ec3e8db36f63d6a54f46b7bea43723 Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: Ic1708a3f33fe71ca752345b5c77b6ae7a2d42bcd
2024-01-19vppinfra: fix test_bihashDmitry Valter1-2/+2
Correctly wrap data indices in test_bihash. Type: fix Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: I740fa1cf9f8c382c12f01f607095c5995be6845f
2024-01-19vppinfra: fix bracket balanceGeorgy Borodin1-1/+2
fix bracket balance in pool_put_will_expand Type: fix Fixes: 66d4cb5a217d556aa7bd2471f02a39badb6d5cd2 Change-Id: I921366c0898cca39cc728b7c7ef4c4c725c6b87d Signed-off-by: Georgy Borodin <bor1-go@yandex-team.ru>
2024-01-19vppinfra: fix vec_prepend use-after-freeDmitry Valter1-7/+9
Don't access free'd memory in vec_prepend. Don't allow prepend when v1 == v2 as it also causes a use-after-free. Found via ASAN. Type: fix Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: I21f8422c007d07d40d237e873b84c042be1fe8e8
2024-01-17vppinfra: change fchmod to umask for unix socketGeorgy Borodin1-14/+17
Setting g+w permission for unix sockets didn't work. There were two problems: 1. new flag local_only wasn't set for all AF_UNIX sockets; 2. fchmod is not a good choice for sockets. fchmod was replaced with couple of umasks, and local_only with socket type check. Type: fix Fixes: 085757bb4930511928daa97f972cdca021e7a813 Change-Id: I8dc0fceb110a36bfa234f552bbdf182e09e55e27 Signed-off-by: Georgy Borodin <bor1-go@yandex-team.ru>
2024-01-16vppinfra: fix memcpy test buffer sizeDmitry Valter1-1/+1
Fix dst buffer size in memcpy_x86_64 test. Type: fix Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: I2b4502a62d9346d729b83522f4ea01c98a5b961c
2024-01-16vppinfra: enable AES tests on ARMDamjan Marion4-10/+3
Type: improvement Change-Id: I30f3b2924ab219a8bace87f358b1b823e8bc83bb Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-01-12vppinfra: native AES-CTR implementationDamjan Marion6-193/+868
Type: feature Change-Id: I7ef3277edaeb266fbd3c8c9355d4443002ed2311 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-12-11vppinfra : fix alignment issuehsandid1-1/+1
Type: fix Modified alignment cast causing crash issues Change-Id: Iae3bb767ef2ba81466bf1567264a4c76ae45bb92 Signed-off-by: hsandid <halsandi@cisco.com>
2023-11-14vppinfra: respect indent in format_tableDamjan Marion1-2/+3
Change-Id: Ib7e5cb5adfe81e5cc6243125d91f5179608a7733 Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-14vppinfra: add unformat_{single,double}_quoted_string functionDamjan Marion2-0/+44
Change-Id: I8ee90be1b772074c1130b98c71b3be48c973b2e2 Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-13ena: Amazon Elastic Network Adapter (ENA) native driverDamjan Marion1-1/+1
Type: feature Change-Id: Icd9de05f2cbac0e5a6dfb1f1414f21dc4b893104 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-09iavf: interrupt mode supportDamjan Marion1-0/+30
Type: improvement Change-Id: Ie5fcaa706ab0995e0021cf1ee74b95c5a3b30283 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-06vppinfra: fix ASAN issue in vec_foreach_pointer and pool_foreach_pointerDamjan Marion2-5/+6
Change-Id: If9381ae7283488b352a3c22f85732cd56ac6bfd9 Type: fix Fixes: 9937359, 91ff0e9 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-03vppinfra: refactor interrupt codeDamjan Marion4-138/+112
Type: improvement Change-Id: Ie6987736faf7d8a641762e276775da8ee0c03ea4 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-03dev: strip debig log function name prefix during compilationDamjan Marion1-0/+7
Type: improvement Change-Id: I9b9bb37a0895366b412f042b0e2da5bbdd477325 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-02iavf: new driver using new dev infraDamjan Marion1-4/+9
Type: feature Change-Id: I9ae0dbf28b4571a37c568b587b771f90c06f200d Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-11-02dev: new device driver infraDamjan Marion2-4/+14
Type: feature Change-Id: I20c56e0d3103624407f18365c2bc1273dea5c199 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-10-30ipsec: huge anti-replay window supportMaxime Peim1-1/+1
Type: improvement Since RFC4303 does not specify the anti-replay window size, VPP should support multiple window size. It is done through a clib_bitmap. Signed-off-by: Maxime Peim <mpeim@cisco.com> Change-Id: I3dfe30efd20018e345418bef298ec7cec19b1cfc
2023-10-09vppinfra: fix coverity issue CID 323952Dave Wallace1-1/+1
Type: fix Fixes: 08600ccfa Change-Id: I53ba0d96507b55ab7cd735073d6c4cf20a3cc948 Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2023-10-04vppinfra: fix string termination in clib_file_get_resolved_basenameDamjan Marion1-0/+2
Type: fix Fixes: 40f4810 Change-Id: Idf51462c8154663de23154f17a894b7245c9fbf0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-10-03vppinfra: add foreach_int macroDamjan Marion1-0/+6
foreach_int(x, 1, 3, 5, 7) { fformat(stdout, "x is %u\n", x); } Type: improvement Change-Id: Idc355f4a284f421b150e3acb7a3a57bcede408c7 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-10-03vppinfra: splat and gather vector inlinesDamjan Marion2-0/+24
Type: improvement Change-Id: I4b00b3a6ff63fc8b313c89217ccdea356c0783a3 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-09-13vppinfra: add ARM Neoverse-N2 supportDamjan Marion2-94/+124
Type: improvement Change-Id: Ief77ae7338667ede290aece6933bb5ae2e76ffc6 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-09-13vppinfra: fix coverity warning CID-313632Dave Wallace1-2/+0
Type: fix Change-Id: Idc036d5967495cc2522b2a30e3acd3ec4c0cd3ff Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2023-09-13vppinfra: fix setns typoArtem Glazychev1-1/+1
Type: fix Signed-off-by: Artem Glazychev <artem.glazychev@xored.com> Change-Id: Ib8eb70336956bc2e8d0454f3c1f2c62ec98cb009
2023-08-07vppinfra: add clib_file_get_resolved_basenameDamjan Marion4-28/+33
more generic version of clib_sysfs_link_to_name with support for format strings... Type: improvement Change-Id: I0cb263748970378c661415196eb7e08450370677 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-08-07vppinfra: add vec_foreach_pointer macroDamjan Marion1-0/+4
works with vectors of pointers... Type: improvement Change-Id: I530653978fcf981be299cf42a1133be000d74d0c Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-08-07vppinfra: add unformat_init_pathDamjan Marion4-49/+83
More conveninet way to unformat file by providing filesystem path. Takes format string for easier constuction of path... Type: improvement Change-Id: I433204fa20dc98e2b11c53914883d047a7fc62c6 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-08-02vppinfra: add pool_foreach_pointer()Damjan Marion1-0/+7
Works on pools of pointers... Type: improvement Change-Id: I194dec389ca4c5ec2ce3361b54a9968c9caecefc Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-07-31vppinfra: add unformat_c_string_arrayDamjan Marion2-0/+27
Type: improvement Change-Id: Iea5ecca5d4cbc6c7aea69104830afcfe78c708ee Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-05-27vppinfra: add bit_extract_u32 and bit_extract_u64Damjan Marion1-0/+42
Type: improvement Change-Id: Icfaa856aa4b50ad5c6828f1690ce3fb6ba08ec00 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-05-16dpdk: fix format rx/tx burst function name failedXiaoming Jiang2-6/+21
Type: fix Signed-off-by: Xiaoming Jiang <jiangxiaoming@outlook.com> Change-Id: I9971e69135e0652a36e4b4754774a43ea1d92e8b
2023-05-16misc: make format_hexdump length u32Benoît Ganne1-1/+1
format_hexdump currently requires the length parameter to be uword (64-bits) hence all callers must make sure to cast the length to uword. Use u32 instead to benefit from C automatic integer promotion: any length smaller or equal to u32 will be promoted to int fitting in u32). Only callers using a length of u64 needs to downcast. It also makes it similar to other variants. Type: fix Change-Id: I09b52fdde3970cec0be4150a29126ff63106c75b Signed-off-by: Benoît Ganne <bganne@cisco.com>
2023-05-16vppinfra: add aarch64 support for format_ucontext_pcTianyu Li1-0/+4
Add the missing AArch64 support for printing program counter. Type: improvement Signed-off-by: Tianyu Li <tianyu.li@arm.com> Change-Id: Idb63737ed72e10fa29fd61e1eab5af059e2b8e28
2023-04-28session: update due to clib_socket refactoringNathan Skrzypczak2-41/+11
After the clib_socket_init syntax changed, the behavior of VCL socket creation was broken. This patch introduces app_namespace_add_del_v4 to address the behavioral change. Type: refactor Change-Id: Ice016bdb372233fd3317f166d45625e086e9b4df Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2023-04-18vppinfra: Multiarch support for AMD EPYC processorsSivaprasad Tummala1-2/+21
Type: feature - Added multiarch support for AMD Zen architectures Change-Id: I65d3fe94b6cc622ebecbe1ac803efa674e87c87a Signed-off-by: Sivaprasad Tummala <sivaprasad.tummala@amd.com>
2023-04-18vppinfra: missing static_always_inline in crc32c.hDamjan Marion1-2/+2
Change-Id: Ie7ee71af7dbbc23de3f413423070ea87fb36ed8c Type: fix Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-04-17vppinfra: SFENCE requires SSE2 to be enabledDamjan Marion1-1/+1
Change-Id: I0469bb91107cf0acced3cd19820db8d3712701c0 Type: fix Fixes: eaabe07 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-04-17vppinfra: add AMD EPYC cpu family detailsSivaprasad Tummala2-2/+27
Type: feature - Added support for AMD EPYC processor family Change-Id: I60da87cca429117c209d240e5a5f3b4d9f4981d8 Signed-off-by: Sivaprasad Tummala <sivaprasad.tummala@amd.com>
2023-04-17vppinfra: native poly1305 implementationDamjan Marion5-6/+544
Type: feature Signed-off-by: Damjan Marion <damarion@cisco.com> Change-Id: Ic170464d7c63f243e7e676567d41d800647ebec3
2023-04-17build: add scalar (no-simd) march variantDamjan Marion3-3/+13
for testing purposes, disabled by default Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com> Change-Id: Id616e2b3b21ae0f0b44e2b55ecefd501afacc7f2
2023-04-17vppinfra: table based crc32c for targets without crc32c instructionsDamjan Marion1-0/+71
Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com> Change-Id: I45cef390c72f2102c8c3d94f49bed7d0e0e0d7b2
2023-04-17vppinfra: add format_hexdump_u{16,32,64}Damjan Marion2-0/+69
Change-Id: I0eeccfc5739276d58a81a6552a043c6c105fe67a Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-04-06vppinfra: refactor uword bitmapsDamjan Marion4-18/+92
Type: improvement Change-Id: I4f05a0435825cd23b8ad8a6f8f1397e60c522319 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-03-27vppinfra: small improvement and polishing of AES GCM codeDamjan Marion2-74/+95
Type: improvement Change-Id: Ie9661792ec68d4ea3c62ee9eb31b455d3b2b0a42 Signed-off-by: Damjan Marion <damarion@cisco.com>
2023-03-23vppinfra: AES-CBC and AES-GCM refactor and optimizationsDamjan Marion13-656/+4048
- crypto code moved to vppinfra for better testing and reuse - added 256-bit VAES support (Intel Client CPUs) - added AES_GMAC functions Change-Id: I960c8e14ca0a0126703e8f1589d86f32e2a98361 Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com>