{
printf("%s [EAL options] --\n"
" --silent: disable options dump\n"
- " --ptest throughput / latency / verify / pmd-cycleount :"
+ " --ptest throughput / latency / verify / pmd-cyclecount :"
" set test type\n"
" --pool_sz N: set the number of crypto ops/mbufs allocated\n"
" --total-ops N: set the number of total operations performed\n"
" --pmd-cyclecount-delay-ms N: set delay between enqueue\n"
" and dequeue in pmd-cyclecount benchmarking mode\n"
" --csv-friendly: enable test result output CSV friendly\n"
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
" --pdcp-sn-sz N: set PDCP SN size N <5/7/12/15/18>\n"
" --pdcp-domain DOMAIN: set PDCP domain <control/user>\n"
" --pdcp-ses-hfn-en: enable session based fixed HFN\n"
{
cperf_op_type_strs[CPERF_DOCSIS],
CPERF_DOCSIS
+ },
+ {
+ cperf_op_type_strs[CPERF_IPSEC],
+ CPERF_IPSEC
+ },
+ {
+ cperf_op_type_strs[CPERF_ASYM_MODEX],
+ CPERF_ASYM_MODEX
}
};
{
char *test_name = (char *) rte_zmalloc(NULL,
sizeof(char) * (strlen(arg) + 3), 0);
+ if (test_name == NULL) {
+ RTE_LOG(ERR, USER1, "Failed to rte zmalloc with size: %zu\n",
+ strlen(arg) + 3);
+ return -1;
+ }
+
snprintf(test_name, strlen(arg) + 3, "[%s]", arg);
opts->test_name = test_name;
return parse_uint16_t(&opts->digest_sz, arg);
}
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
static int
parse_pdcp_sn_sz(struct cperf_options *opts, const char *arg)
{
const char *cperf_pdcp_domain_strs[] = {
[RTE_SECURITY_PDCP_MODE_CONTROL] = "control",
- [RTE_SECURITY_PDCP_MODE_DATA] = "data"
+ [RTE_SECURITY_PDCP_MODE_DATA] = "data",
+ [RTE_SECURITY_PDCP_MODE_SHORT_MAC] = "short_mac"
};
static int
cperf_pdcp_domain_strs
[RTE_SECURITY_PDCP_MODE_DATA],
RTE_SECURITY_PDCP_MODE_DATA
+ },
+ {
+ cperf_pdcp_domain_strs
+ [RTE_SECURITY_PDCP_MODE_SHORT_MAC],
+ RTE_SECURITY_PDCP_MODE_SHORT_MAC
}
};
{ CPERF_DIGEST_SZ, required_argument, 0, 0 },
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
{ CPERF_PDCP_SN_SZ, required_argument, 0, 0 },
{ CPERF_PDCP_DOMAIN, required_argument, 0, 0 },
{ CPERF_PDCP_SES_HFN_EN, no_argument, 0, 0 },
opts->digest_sz = 12;
opts->pmdcc_delay = 0;
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
opts->pdcp_sn_sz = 12;
opts->pdcp_domain = RTE_SECURITY_PDCP_MODE_CONTROL;
opts->pdcp_ses_hfn_en = 0;
{ CPERF_AEAD_IV_SZ, parse_aead_iv_sz },
{ CPERF_AEAD_AAD_SZ, parse_aead_aad_sz },
{ CPERF_DIGEST_SZ, parse_digest_sz },
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
{ CPERF_PDCP_SN_SZ, parse_pdcp_sn_sz },
{ CPERF_PDCP_DOMAIN, parse_pdcp_domain },
{ CPERF_PDCP_SES_HFN_EN, parse_pdcp_ses_hfn_en },
switch (opt) {
case 'h':
usage(argv[0]);
- rte_exit(EXIT_SUCCESS, "Displayed help\n");
+ exit(EXIT_SUCCESS);
break;
/* long options */
case 0:
return 0;
}
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
static int
check_docsis_buffer_length(struct cperf_options *options)
{
return -EINVAL;
}
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
if (options->op_type == CPERF_DOCSIS) {
if (check_docsis_buffer_length(options) < 0)
return -EINVAL;
printf("#\n");
}
-#ifdef RTE_LIBRTE_SECURITY
+#ifdef RTE_LIB_SECURITY
if (opts->op_type == CPERF_DOCSIS) {
printf("# docsis header size: %u\n", opts->docsis_hdr_sz);
printf("#\n");