Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ defaults:
env:
REF_GIT_BRANCH: main
REF_GIT_REPO: https://github.com/DPDK/dpdk
REF_GIT_TAG: none
REF_GIT_TAG: v25.11

jobs:
checkpatch:
Expand Down Expand Up @@ -96,7 +96,7 @@ jobs:
checks: stdatomic
- os: ubuntu-22.04
compiler: gcc
checks: debug+doc+examples+tests
checks: abi+debug+doc+examples+tests
- os: ubuntu-22.04
compiler: clang
checks: asan+doc+tests
Expand Down
2 changes: 1 addition & 1 deletion ABI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
26.0
26.1
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
25.11.0-rc4
26.03.0-rc0
2 changes: 1 addition & 1 deletion app/test-bbdev/test_vectors/bbdev_null.data
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# Copyright(c) 2017 Intel Corporation

op_type =
RTE_BBDEV_OP_NONE
RTE_BBDEV_OP_NONE
Original file line number Diff line number Diff line change
Expand Up @@ -637,4 +637,4 @@ RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE, RTE_BBDEV_TURBO_CRC_TYPE_24B,
RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN

expected_status =
OK
OK
Original file line number Diff line number Diff line change
Expand Up @@ -637,4 +637,4 @@ RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE, RTE_BBDEV_TURBO_CRC_TYPE_24B,
RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN

expected_status =
OK
OK
Original file line number Diff line number Diff line change
Expand Up @@ -1219,4 +1219,4 @@ RTE_BBDEV_TURBO_SOFT_OUTPUT, RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE, RTE_BBDEV_TU
RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT

expected_status =
OK
OK
Original file line number Diff line number Diff line change
Expand Up @@ -674,4 +674,4 @@ RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE, RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN,
RTE_BBDEV_TURBO_CRC_TYPE_24B, RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP

expected_status =
OK
OK
Original file line number Diff line number Diff line change
Expand Up @@ -156,4 +156,4 @@ op_flags =
RTE_BBDEV_TURBO_CRC_24A_ATTACH

expected_status =
OK
OK
Original file line number Diff line number Diff line change
Expand Up @@ -150,4 +150,4 @@ op_flags =
RTE_BBDEV_TURBO_CRC_24B_ATTACH

expected_status =
OK
OK
28 changes: 27 additions & 1 deletion app/test/process.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

#include <rte_string_fns.h> /* strlcpy */
#include <rte_devargs.h>
#include <rte_eal.h>

#ifdef RTE_EXEC_ENV_FREEBSD
#define self "curproc"
Expand All @@ -36,6 +37,7 @@ extern uint16_t flag_for_send_pkts;
#endif

#define PREFIX_ALLOW "--allow="
#define PREFIX_DRIVER_PATH "--driver-path="

static int
add_parameter_allow(char **argv, int max_capacity)
Expand Down Expand Up @@ -63,6 +65,23 @@ add_parameter_allow(char **argv, int max_capacity)
return count;
}

static int
add_parameter_driver_path(char **argv, int max_capacity)
{
const char *driver_path;
int count = 0;

RTE_EAL_DRIVER_PATH_FOREACH(driver_path, true) {
if (asprintf(&argv[count], PREFIX_DRIVER_PATH"%s", driver_path) < 0)
break;

if (++count == max_capacity)
break;
}

return count;
}

/*
* launches a second copy of the test process using the given argv parameters,
* which should include argv[0] as the process name. To identify in the
Expand All @@ -75,6 +94,7 @@ process_dup(const char *const argv[], int numargs, const char *env_value)
int num = 0;
char **argv_cpy;
int allow_num;
int driver_path_num;
int argv_num;
int i, status;
char path[32];
Expand All @@ -90,7 +110,8 @@ process_dup(const char *const argv[], int numargs, const char *env_value)
return -1;
else if (pid == 0) {
allow_num = rte_devargs_type_count(RTE_DEVTYPE_ALLOWED);
argv_num = numargs + allow_num + 1;
driver_path_num = rte_eal_driver_path_count(true);
argv_num = numargs + allow_num + driver_path_num + 1;
argv_cpy = calloc(argv_num, sizeof(char *));
if (!argv_cpy)
rte_panic("Memory allocation failed\n");
Expand All @@ -105,6 +126,11 @@ process_dup(const char *const argv[], int numargs, const char *env_value)
num = add_parameter_allow(&argv_cpy[i], allow_num);
num += numargs;

if (driver_path_num > 0) {
int added = add_parameter_driver_path(&argv_cpy[num], driver_path_num);
num += added;
}

#ifdef RTE_EXEC_ENV_LINUX
{
const char *procdir = "/proc/" self "/fd/";
Expand Down
14 changes: 12 additions & 2 deletions app/test/suites/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,19 @@ foreach suite:test_suites
# special fast-test handling here
foreach t: suite_tests
params = t.split(':')
# check for valid options for asan and nohuge. Note, the extraction script runs tolower()
if params[1] != 'NOHUGE_OK' and params[1] != 'NOHUGE_SKIP'
error('Invalid parameter "@0@" for test "@1@". Must be NOHUGE_OK or NOHUGE_SKIP.'
.format(params[1], params[0]))
endif
if params[2] != 'ASAN_OK' and params[2] != 'ASAN_SKIP'
error('Invalid parameter "@0@" for test "@1@". Must be ASAN_OK or ASAN_SKIP.'
.format(params[2], params[0]))
endif

test_name = params[0]
nohuge = params[1] == 'true'
asan = params[2] == 'true'
nohuge = params[1] == 'NOHUGE_OK'
asan = params[2] == 'ASAN_OK'

test_args = []
if nohuge
Expand Down
9 changes: 8 additions & 1 deletion app/test/test.h
Original file line number Diff line number Diff line change
Expand Up @@ -207,9 +207,16 @@ void add_test_command(struct test_command *t);
/* Register a test function as a particular type.
* These can be used to build up test suites automatically
*/
#define REGISTER_FAST_TEST(cmd, no_huge, ASan, func) REGISTER_TEST_COMMAND(cmd, func)
#define REGISTER_PERF_TEST REGISTER_TEST_COMMAND
#define REGISTER_DRIVER_TEST REGISTER_TEST_COMMAND
#define REGISTER_STRESS_TEST REGISTER_TEST_COMMAND

/* fast tests are a bit special. They can be specified as supporting running without
* hugepages and/or under ASan.
* - The "no_huge" options should be passed as either "NOHUGE_OK" or "NOHUGE_SKIP"
* - The "ASan" options should be passed as either "ASAN_OK" or "ASAN_SKIP"
*/
#define REGISTER_FAST_TEST(cmd, no_huge, ASan, func) REGISTER_TEST_COMMAND(cmd, func)


#endif
2 changes: 1 addition & 1 deletion app/test/test_acl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1748,4 +1748,4 @@ test_acl(void)

#endif /* !RTE_EXEC_ENV_WINDOWS */

REGISTER_FAST_TEST(acl_autotest, true, true, test_acl);
REGISTER_FAST_TEST(acl_autotest, NOHUGE_OK, ASAN_OK, test_acl);
2 changes: 1 addition & 1 deletion app/test/test_alarm.c
Original file line number Diff line number Diff line change
Expand Up @@ -76,4 +76,4 @@ test_alarm(void)
return 0;
}

REGISTER_FAST_TEST(alarm_autotest, true, true, test_alarm);
REGISTER_FAST_TEST(alarm_autotest, NOHUGE_OK, ASAN_OK, test_alarm);
2 changes: 1 addition & 1 deletion app/test/test_argparse.c
Original file line number Diff line number Diff line change
Expand Up @@ -1618,4 +1618,4 @@ test_argparse(void)
return unit_test_suite_runner(&argparse_test_suite);
}

REGISTER_FAST_TEST(argparse_autotest, true, true, test_argparse);
REGISTER_FAST_TEST(argparse_autotest, NOHUGE_OK, ASAN_OK, test_argparse);
2 changes: 1 addition & 1 deletion app/test/test_atomic.c
Original file line number Diff line number Diff line change
Expand Up @@ -632,5 +632,5 @@ test_atomic(void)

return 0;
}
REGISTER_FAST_TEST(atomic_autotest, false, true, test_atomic);
REGISTER_FAST_TEST(atomic_autotest, NOHUGE_SKIP, ASAN_OK, test_atomic);
#endif /* RTE_TOOLCHAIN_MSVC */
2 changes: 1 addition & 1 deletion app/test/test_bitcount.c
Original file line number Diff line number Diff line change
Expand Up @@ -171,4 +171,4 @@ test_bitcount(void)
return unit_test_suite_runner(&bitcount_test_suite);
}

REGISTER_FAST_TEST(bitcount_autotest, true, true, test_bitcount);
REGISTER_FAST_TEST(bitcount_autotest, NOHUGE_OK, ASAN_OK, test_bitcount);
2 changes: 1 addition & 1 deletion app/test/test_bitmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,4 +269,4 @@ test_bitmap(void)
return test_bitmap_all_set();
}

REGISTER_FAST_TEST(bitmap_autotest, true, true, test_bitmap);
REGISTER_FAST_TEST(bitmap_autotest, NOHUGE_OK, ASAN_OK, test_bitmap);
2 changes: 1 addition & 1 deletion app/test/test_bitops.c
Original file line number Diff line number Diff line change
Expand Up @@ -438,4 +438,4 @@ test_bitops(void)
return unit_test_suite_runner(&test_suite);
}

REGISTER_FAST_TEST(bitops_autotest, true, true, test_bitops);
REGISTER_FAST_TEST(bitops_autotest, NOHUGE_OK, ASAN_OK, test_bitops);
2 changes: 1 addition & 1 deletion app/test/test_bitratestats.c
Original file line number Diff line number Diff line change
Expand Up @@ -249,4 +249,4 @@ test_bitratestats(void)
{
return unit_test_suite_runner(&bitratestats_testsuite);
}
REGISTER_FAST_TEST(bitratestats_autotest, true, true, test_bitratestats);
REGISTER_FAST_TEST(bitratestats_autotest, NOHUGE_OK, ASAN_OK, test_bitratestats);
2 changes: 1 addition & 1 deletion app/test/test_bitset.c
Original file line number Diff line number Diff line change
Expand Up @@ -909,4 +909,4 @@ test_bitset(void)
return unit_test_suite_runner(&bitset_tests);
}

REGISTER_FAST_TEST(bitset_autotest, true, true, test_bitset);
REGISTER_FAST_TEST(bitset_autotest, NOHUGE_OK, ASAN_OK, test_bitset);
6 changes: 3 additions & 3 deletions app/test/test_bpf.c
Original file line number Diff line number Diff line change
Expand Up @@ -3278,7 +3278,7 @@ test_bpf(void)

#endif /* !RTE_LIB_BPF */

REGISTER_FAST_TEST(bpf_autotest, true, true, test_bpf);
REGISTER_FAST_TEST(bpf_autotest, NOHUGE_OK, ASAN_OK, test_bpf);

#ifdef TEST_BPF_ELF_LOAD

Expand Down Expand Up @@ -3751,7 +3751,7 @@ test_bpf_elf(void)

#endif /* !TEST_BPF_ELF_LOAD */

REGISTER_FAST_TEST(bpf_elf_autotest, true, true, test_bpf_elf);
REGISTER_FAST_TEST(bpf_elf_autotest, NOHUGE_OK, ASAN_OK, test_bpf_elf);

#ifndef RTE_HAS_LIBPCAP

Expand Down Expand Up @@ -3969,4 +3969,4 @@ test_bpf_convert(void)

#endif /* RTE_HAS_LIBPCAP */

REGISTER_FAST_TEST(bpf_convert_autotest, true, true, test_bpf_convert);
REGISTER_FAST_TEST(bpf_convert_autotest, NOHUGE_OK, ASAN_OK, test_bpf_convert);
2 changes: 1 addition & 1 deletion app/test/test_byteorder.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,4 @@ test_byteorder(void)
return 0;
}

REGISTER_FAST_TEST(byteorder_autotest, true, true, test_byteorder);
REGISTER_FAST_TEST(byteorder_autotest, NOHUGE_OK, ASAN_OK, test_byteorder);
2 changes: 1 addition & 1 deletion app/test/test_cfgfile.c
Original file line number Diff line number Diff line change
Expand Up @@ -399,4 +399,4 @@ test_cfgfile(void)
return unit_test_suite_runner(&test_cfgfile_suite);
}

REGISTER_FAST_TEST(cfgfile_autotest, true, true, test_cfgfile);
REGISTER_FAST_TEST(cfgfile_autotest, NOHUGE_OK, ASAN_OK, test_cfgfile);
2 changes: 1 addition & 1 deletion app/test/test_cksum.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,4 +267,4 @@ test_cksum(void)
}
#undef GOTO_FAIL

REGISTER_FAST_TEST(cksum_autotest, true, true, test_cksum);
REGISTER_FAST_TEST(cksum_autotest, NOHUGE_OK, ASAN_OK, test_cksum);
2 changes: 1 addition & 1 deletion app/test/test_cmdline.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,4 @@ test_cmdline(void)
return 0;
}

REGISTER_FAST_TEST(cmdline_autotest, true, true, test_cmdline);
REGISTER_FAST_TEST(cmdline_autotest, NOHUGE_OK, ASAN_OK, test_cmdline);
2 changes: 1 addition & 1 deletion app/test/test_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,4 +354,4 @@ test_common(void)
return ret;
}

REGISTER_FAST_TEST(common_autotest, true, true, test_common);
REGISTER_FAST_TEST(common_autotest, NOHUGE_OK, ASAN_OK, test_common);
2 changes: 1 addition & 1 deletion app/test/test_compressdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -4255,4 +4255,4 @@ test_compressdev(void)
return unit_test_suite_runner(&compressdev_testsuite);
}

REGISTER_FAST_TEST(compressdev_autotest, false, true, test_compressdev);
REGISTER_FAST_TEST(compressdev_autotest, NOHUGE_SKIP, ASAN_OK, test_compressdev);
2 changes: 1 addition & 1 deletion app/test/test_cpuflags.c
Original file line number Diff line number Diff line change
Expand Up @@ -327,4 +327,4 @@ test_cpuflags(void)
return 0;
}

REGISTER_FAST_TEST(cpuflags_autotest, true, true, test_cpuflags);
REGISTER_FAST_TEST(cpuflags_autotest, NOHUGE_OK, ASAN_OK, test_cpuflags);
2 changes: 1 addition & 1 deletion app/test/test_crc.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,4 +140,4 @@ crc_autotest(void)
return ret;
}

REGISTER_FAST_TEST(crc_autotest, true, true, crc_autotest);
REGISTER_FAST_TEST(crc_autotest, NOHUGE_OK, ASAN_OK, crc_autotest);
2 changes: 1 addition & 1 deletion app/test/test_cryptodev_crosscheck.c
Original file line number Diff line number Diff line change
Expand Up @@ -1047,4 +1047,4 @@ test_crosscheck(void)
return ret;
}

REGISTER_TEST_COMMAND(cryptodev_crosscheck, test_crosscheck);
REGISTER_DRIVER_TEST(cryptodev_crosscheck, test_crosscheck);
2 changes: 1 addition & 1 deletion app/test/test_cycles.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,4 @@ test_user_delay_us(void)
return 0;
}

REGISTER_FAST_TEST(user_delay_us, true, true, test_user_delay_us);
REGISTER_FAST_TEST(user_delay_us, NOHUGE_OK, ASAN_OK, test_user_delay_us);
2 changes: 1 addition & 1 deletion app/test/test_debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -183,4 +183,4 @@ test_debug(void)

#endif /* !RTE_EXEC_ENV_WINDOWS */

REGISTER_FAST_TEST(debug_autotest, true, true, test_debug);
REGISTER_FAST_TEST(debug_autotest, NOHUGE_OK, ASAN_OK, test_debug);
2 changes: 1 addition & 1 deletion app/test/test_devargs.c
Original file line number Diff line number Diff line change
Expand Up @@ -320,4 +320,4 @@ test_devargs(void)
return 0;
}

REGISTER_FAST_TEST(devargs_autotest, true, true, test_devargs);
REGISTER_FAST_TEST(devargs_autotest, NOHUGE_OK, ASAN_OK, test_devargs);
2 changes: 1 addition & 1 deletion app/test/test_dispatcher.c
Original file line number Diff line number Diff line change
Expand Up @@ -1053,4 +1053,4 @@ test_dispatcher(void)
return unit_test_suite_runner(&test_suite);
}

REGISTER_FAST_TEST(dispatcher_autotest, false, true, test_dispatcher);
REGISTER_FAST_TEST(dispatcher_autotest, NOHUGE_SKIP, ASAN_OK, test_dispatcher);
2 changes: 1 addition & 1 deletion app/test/test_distributor.c
Original file line number Diff line number Diff line change
Expand Up @@ -953,4 +953,4 @@ test_distributor(void)

#endif /* !RTE_EXEC_ENV_WINDOWS */

REGISTER_FAST_TEST(distributor_autotest, false, true, test_distributor);
REGISTER_FAST_TEST(distributor_autotest, NOHUGE_SKIP, ASAN_OK, test_distributor);
24 changes: 12 additions & 12 deletions app/test/test_eal_flags.c
Original file line number Diff line number Diff line change
Expand Up @@ -1692,15 +1692,15 @@ test_memory_flags(void)

#endif /* !RTE_EXEC_ENV_WINDOWS */

REGISTER_FAST_TEST(eal_flags_c_opt_autotest, false, false, test_missing_c_flag);
REGISTER_FAST_TEST(eal_flags_main_opt_autotest, false, false, test_main_lcore_flag);
REGISTER_FAST_TEST(eal_flags_n_opt_autotest, false, false, test_invalid_n_flag);
REGISTER_FAST_TEST(eal_flags_hpet_autotest, false, false, test_no_hpet_flag);
REGISTER_FAST_TEST(eal_flags_no_huge_autotest, false, false, test_no_huge_flag);
REGISTER_FAST_TEST(eal_flags_a_opt_autotest, false, false, test_allow_flag);
REGISTER_FAST_TEST(eal_flags_b_opt_autotest, false, false, test_invalid_b_flag);
REGISTER_FAST_TEST(eal_flags_vdev_opt_autotest, false, false, test_invalid_vdev_flag);
REGISTER_FAST_TEST(eal_flags_r_opt_autotest, false, false, test_invalid_r_flag);
REGISTER_FAST_TEST(eal_flags_mem_autotest, false, false, test_memory_flags);
REGISTER_FAST_TEST(eal_flags_file_prefix_autotest, false, false, test_file_prefix);
REGISTER_FAST_TEST(eal_flags_misc_autotest, false, false, test_misc_flags);
REGISTER_FAST_TEST(eal_flags_c_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_missing_c_flag);
REGISTER_FAST_TEST(eal_flags_main_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_main_lcore_flag);
REGISTER_FAST_TEST(eal_flags_n_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_invalid_n_flag);
REGISTER_FAST_TEST(eal_flags_hpet_autotest, NOHUGE_SKIP, ASAN_SKIP, test_no_hpet_flag);
REGISTER_FAST_TEST(eal_flags_no_huge_autotest, NOHUGE_SKIP, ASAN_SKIP, test_no_huge_flag);
REGISTER_FAST_TEST(eal_flags_a_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_allow_flag);
REGISTER_FAST_TEST(eal_flags_b_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_invalid_b_flag);
REGISTER_FAST_TEST(eal_flags_vdev_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_invalid_vdev_flag);
REGISTER_FAST_TEST(eal_flags_r_opt_autotest, NOHUGE_SKIP, ASAN_SKIP, test_invalid_r_flag);
REGISTER_FAST_TEST(eal_flags_mem_autotest, NOHUGE_SKIP, ASAN_SKIP, test_memory_flags);
REGISTER_FAST_TEST(eal_flags_file_prefix_autotest, NOHUGE_SKIP, ASAN_SKIP, test_file_prefix);
REGISTER_FAST_TEST(eal_flags_misc_autotest, NOHUGE_SKIP, ASAN_SKIP, test_misc_flags);
2 changes: 1 addition & 1 deletion app/test/test_eal_fs.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,4 +185,4 @@ test_eal_fs(void)

#endif /* !RTE_EXEC_ENV_WINDOWS */

REGISTER_FAST_TEST(eal_fs_autotest, true, true, test_eal_fs);
REGISTER_FAST_TEST(eal_fs_autotest, NOHUGE_OK, ASAN_OK, test_eal_fs);
2 changes: 1 addition & 1 deletion app/test/test_errno.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,4 +94,4 @@ test_errno(void)
return 0;
}

REGISTER_FAST_TEST(errno_autotest, true, true, test_errno);
REGISTER_FAST_TEST(errno_autotest, NOHUGE_OK, ASAN_OK, test_errno);
2 changes: 1 addition & 1 deletion app/test/test_ethdev_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,4 +185,4 @@ test_ethdev_api(void)
/* TODO: Make part of the fast test suite, `REGISTER_FAST_TEST()`,
* when all drivers complies to the queue state requirement
*/
REGISTER_TEST_COMMAND(ethdev_api, test_ethdev_api);
REGISTER_DRIVER_TEST(ethdev_api, test_ethdev_api);
2 changes: 1 addition & 1 deletion app/test/test_ethdev_link.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,4 +172,4 @@ test_link_status(void)
return unit_test_suite_runner(&link_status_testsuite);
}

REGISTER_FAST_TEST(ethdev_link_status, true, true, test_link_status);
REGISTER_FAST_TEST(ethdev_link_status, NOHUGE_OK, ASAN_OK, test_link_status);
Loading