Example application which queries and prints out various system information and capabilities which are available through ODP APIs.
Example application which queries and prints out various system information and capabilities which are available through ODP APIs.
#ifndef _GNU_SOURCE
#define _GNU_SOURCE
#endif
#include <getopt.h>
#include <stdio.h>
#include <string.h>
#include <stdint.h>
#include <inttypes.h>
#include <odp/helper/odph_api.h>
#define KB 1024
#define MB (1024 * 1024)
#define MAX_HUGE_PAGES 32
#define MAX_IFACES 32
#define MAX_NAME_LEN 128
#define PROG_NAME "odp_sysinfo"
typedef struct {
char name[MAX_NAME_LEN];
} pktio_t;
typedef struct {
int num_pktio;
pktio_t pktio[MAX_IFACES];
struct {
int num;
} timer;
} appl_args_t;
ODP_STATIC_ASSERT(
sizeof(
unsigned int) >=
sizeof(uint32_t),
"unsigned int smaller than uint32_t");
{
switch (support) {
default: return "UNKNOWN";
}
}
{
switch (cpu_arch) {
return "ARM";
return "MIPS";
return "PPC";
return "RISC-V";
return "x86";
default:
return "Unknown";
}
}
{
switch (isa) {
return "ARMv6";
return "ARMv7-A";
return "ARMv8.0-A";
return "ARMv8.1-A";
return "ARMv8.2-A";
return "ARMv8.3-A";
return "ARMv8.4-A";
return "ARMv8.5-A";
return "ARMv8.6-A";
return "ARMv8.7-A";
return "ARMv8.8-A";
return "ARMv8.9-A";
return "ARMv9.0-A";
return "ARMv9.1-A";
return "ARMv9.2-A";
return "ARMv9.3-A";
default:
return "Unknown";
}
}
{
switch (isa) {
return "x86_i686";
return "x86_64";
default:
return "Unknown";
}
}
{
switch (cpu_arch) {
if (isa_sw)
else
return "Unknown";
return "Unknown";
return "Unknown";
if (isa_sw)
else
default:
return "Unknown";
}
}
{
switch (cipher) {
return "null";
return "des";
return "3des_cbc";
return "3des_ecb";
return "aes_cbc";
return "aes_ctr";
return "aes_ecb";
return "aes_cfb128";
return "aes_xts";
return "aes_gcm";
return "aes_ccm";
return "chacha20_poly1305";
return "kasumi_f8";
return "snow3g_uea2";
return "snow5g_nea4";
return "aes_eea2";
return "zuc_eea3";
return "zuc_nea6";
return "snow_v";
return "snow_v_gcm";
return "sm4_ecb";
return "sm4_cbc";
return "sm4_ctr";
return "sm4_gcm";
return "sm4_ccm";
default:
return "Unknown";
}
}
{
switch (auth) {
return "null";
return "md5_hmac";
return "sha1_hmac";
return "sha224_hmac";
return "sha256_hmac";
return "sha384_hmac";
return "sha512_hmac";
return "sha3_224_hmac";
return "sha3_256_hmac";
return "sha3_384_hmac";
return "sha3_512_hmac";
return "aes_gcm";
return "aes_gmac";
return "aes_ccm";
return "aes_cmac";
return "aes_xcbc_mac";
return "chacha20_poly1305";
return "kasumi_f9";
return "snow3g_uia2";
return "snow5g_nia4";
return "aes_eia2";
return "zuc_eia3";
return "zuc_nia6";
return "snow_v_gcm";
return "snow_v_gmac";
return "sm3_hmac";
return "sm4_gcm";
return "sm4_gmac";
return "sm4_ccm";
return "md5";
return "sha1";
return "sha224";
return "sha256";
return "sha384";
return "sha512";
return "sha3_224";
return "sha3_256";
return "sha3_384";
return "sha3_512";
return "sm3";
default:
return "Unknown";
}
}
{
}
{
}
{
int rc, i;
if (caps <= 0)
return;
if (rc < 0)
return;
printf(" %s:\n", cipher_alg_name(cipher));
for (i = 0; i < rc; i++)
printf(" key %d iv %d\n",
capa[i].key_len, capa[i].iv_len);
}
{
int rc, i;
if (caps <= 0)
return;
if (rc < 0)
return;
printf(" %s:\n", auth_alg_name(auth));
for (i = 0; i < rc; i++) {
printf(" digest %d", capa[i].digest_len);
if (capa[i].key_len != 0)
printf(" key %d", capa[i].key_len);
if (capa[i].iv_len != 0)
printf(" iv %d", capa[i].iv_len);
if (capa[i].aad_len.max != 0)
printf(" aad %d, %d, %d",
capa[i].aad_len.min, capa[i].aad_len.max,
capa[i].aad_len.inc);
printf("\n");
}
}
{
printf("%s ", cipher_alg_name(alg));
}
{
printf("%s ", auth_alg_name(alg));
}
static void print_atomic_lock_free(void)
{
printf("\n");
printf(" ATOMICS\n");
printf(" Lock-free odp_atomic_u64_t ops\n");
printf(
" load: %s\n", lock_free_u64.
op.
load ?
"yes" :
"no");
printf(
" store: %s\n", lock_free_u64.
op.
store ?
"yes" :
"no");
printf(
" fetch_add: %s\n", lock_free_u64.
op.
fetch_add ?
"yes" :
"no");
printf(
" add: %s\n", lock_free_u64.
op.
add ?
"yes" :
"no");
printf(
" fetch_sub: %s\n", lock_free_u64.
op.
fetch_sub ?
"yes" :
"no");
printf(
" sub: %s\n", lock_free_u64.
op.
sub ?
"yes" :
"no");
printf(
" fetch_inc: %s\n", lock_free_u64.
op.
fetch_inc ?
"yes" :
"no");
printf(
" inc: %s\n", lock_free_u64.
op.
inc ?
"yes" :
"no");
printf(
" fetch_dec: %s\n", lock_free_u64.
op.
fetch_dec ?
"yes" :
"no");
printf(
" dec: %s\n", lock_free_u64.
op.
dec ?
"yes" :
"no");
printf(
" min: %s\n", lock_free_u64.
op.
min ?
"yes" :
"no");
printf(
" fetch_min: %s\n", lock_free_u64.
op.
fetch_min ?
"yes" :
"no");
printf(
" max: %s\n", lock_free_u64.
op.
max ?
"yes" :
"no");
printf(
" fetch_max: %s\n", lock_free_u64.
op.
fetch_max ?
"yes" :
"no");
printf(
" cas: %s\n", lock_free_u64.
op.
cas ?
"yes" :
"no");
printf(
" xchg: %s\n", lock_free_u64.
op.
xchg ?
"yes" :
"no");
printf(
" bit_fetch_set: %s\n", lock_free_u64.
op.
bit_fetch_set ?
"yes" :
"no");
printf(
" bit_set: %s\n", lock_free_u64.
op.
bit_set ?
"yes" :
"no");
printf(
" bit_fetch_clr: %s\n", lock_free_u64.
op.
bit_fetch_clr ?
"yes" :
"no");
printf(
" bit_clr: %s\n", lock_free_u64.
op.
bit_clr ?
"yes" :
"no");
printf(" Lock-free odp_atomic_u128_t ops\n");
printf(
" load: %s\n", lock_free_u128.
op.
load ?
"yes" :
"no");
printf(
" store: %s\n", lock_free_u128.
op.
store ?
"yes" :
"no");
printf(
" cas: %s\n", lock_free_u128.
op.
cas ?
"yes" :
"no");
}
static int pktio_capability(appl_args_t *appl_args)
{
int ret = 0;
ODPH_ERR("Creating packet pool failed\n");
return -1;
}
for (int i = 0; i < appl_args->num_pktio; i++) {
ODPH_ERR("Opening pktio %s failed\n", appl_args->pktio[i].name);
ret = -1;
break;
}
ODPH_ERR("Reading pktio %s capa failed\n", appl_args->pktio[i].name);
ret = -1;
}
ODPH_ERR("Reading pktio %s proto stats capa failed\n",
appl_args->pktio[i].name);
ret = -1;
}
ODPH_ERR("Closing pktio %s failed\n", appl_args->pktio[i].name);
ret = -1;
}
if (ret)
break;
}
ODPH_ERR("Destroying pktio pool failed\n");
return -1;
}
return ret;
}
static void print_pktio_capa(appl_args_t *appl_args)
{
for (int i = 0; i < appl_args->num_pktio; i++) {
printf("\n");
printf(" PKTIO (%s)\n", appl_args->pktio[i].name);
printf(" (in_mode: ODP_PKTIN_MODE_SCHED)\n");
printf(" (out_mode: ODP_PKTOUT_MODE_DIRECT)\n");
printf(" config.pktin: 0x%" PRIx64 "\n",
printf(" config.pktout: 0x%" PRIx64 "\n",
printf(" vector.supported: %s\n",
printf(" vector.max_tmo_ns: %" PRIu64 " ns\n",
printf(" vector.min_tmo_ns: %" PRIu64 " ns\n",
printf(" lso.mod_op.add_payload_offset: %u\n",
printf(" max_tx_aging_tmo_ns: %" PRIu64 " ns\n",
printf(" reassembly.max_wait_time: %" PRIu64 " ns\n",
printf(" stats.pktio: 0x%" PRIx64 "\n",
printf(" stats.pktin_queue: 0x%" PRIx64 "\n",
printf(" stats.pktout_queue: 0x%" PRIx64 "\n",
}
}
static void print_proto_stats_capa(appl_args_t *appl_args)
{
for (int i = 0; i < appl_args->num_pktio; i++) {
printf("\n");
printf(" PROTO STATS (%s)\n", appl_args->pktio[i].name);
}
}
static int timer_capability(appl_args_t *appl_args)
{
int ret;
ODPH_ERR("odp_timer_capability() failed for default clock source: %d\n",
ret);
return -1;
}
if (ret == -1)
continue;
if (ret < -1) {
ODPH_ERR("odp_timer_capability() for clock source %d failed: %d\n", i, ret);
return -1;
}
ODPH_ERR("odp_timer_pool_create() failed for clock source: %d\n", i);
return -1;
}
ODPH_ERR("odp_timer_pool_start_multi() failed for clock source: %d\n", i);
return -1;
}
if (ret) {
ODPH_ERR("odp_timer_pool_info() for clock source %d failed: %d\n", i, ret);
return -1;
}
appl_args->timer.num++;
}
return 0;
}
static void print_timer_capa(appl_args_t *appl_args)
{
for (int i = 0; i < appl_args->timer.num; i++) {
printf("\n");
printf(" TIMER (SRC %d)\n", i);
printf(" maximum resolution\n");
printf(" maximum timeout\n");
printf(" periodic\n");
printf(" min_base_freq_hz: %" PRIu64 " %" PRIu64 "/%" PRIu64 " Hz\n",
printf(" max_base_freq_hz: %" PRIu64 " %" PRIu64 "/%" PRIu64 " Hz\n",
printf(" min_freq_hz: %" PRIu64 " %" PRIu64 "/%" PRIu64 " Hz\n",
printf(" max_freq_hz: %" PRIu64 " %" PRIu64 "/%" PRIu64 " Hz\n",
printf(" timer pool tick info (max_res)\n");
printf(" freq: %" PRIu64 " %" PRIu64 "/%" PRIu64 " Hz\n",
printf(" nsec: %" PRIu64 " %" PRIu64 "/%" PRIu64 " ns\n",
printf(" clk_cycle: %" PRIu64 " %" PRIu64 "/%" PRIu64 " cycles\n",
}
}
static void usage(void)
{
printf("\n"
"System Information\n"
"\n"
"Usage: %s OPTIONS\n"
" E.g. %s -i eth0\n"
"\n"
"Optional OPTIONS:\n"
" -i, --interfaces Ethernet interfaces for packet I/O, comma-separated, no\n"
" spaces.\n"
" -h, --help Display help and exit.\n"
"\n", PROG_NAME, PROG_NAME);
}
static void parse_interfaces(appl_args_t *config, const char *optarg)
{
char *tmp_str = strdup(optarg), *tmp;
if (tmp_str == NULL)
return;
tmp = strtok(tmp_str, ",");
while (tmp && config->num_pktio < MAX_IFACES) {
if (strlen(tmp) + 1 > MAX_NAME_LEN) {
ODPH_ERR("Unable to store interface name (MAX_NAME_LEN=%d)\n",
MAX_NAME_LEN);
exit(EXIT_FAILURE);
}
odph_strcpy(config->pktio[config->num_pktio].name, tmp, MAX_NAME_LEN);
config->num_pktio++;
tmp = strtok(NULL, ",");
}
free(tmp_str);
}
static void parse_args(int argc, char *argv[], appl_args_t *appl_args)
{
int opt;
static const struct option longopts[] = {
{"interfaces", required_argument, NULL, 'i'},
{"help", no_argument, NULL, 'h'},
{NULL, 0, NULL, 0}
};
static const char *shortopts = "i:h";
while (1) {
opt = getopt_long(argc, argv, shortopts, longopts, NULL);
if (opt == -1)
break;
switch (opt) {
case 'i':
parse_interfaces(appl_args, optarg);
break;
case 'h':
usage();
exit(EXIT_SUCCESS);
case '?':
default:
usage();
exit(EXIT_FAILURE);
}
}
}
int main(int argc, char **argv)
{
int i, num_hp, num_hp_print;
int num_ava, num_work, num_ctrl;
appl_args_t appl_args;
uint64_t huge_page[MAX_HUGE_PAGES];
int crypto_ret;
int ipsec_ret;
int num_engines;
memset(&appl_args, 0, sizeof(appl_args_t));
printf("\n");
printf("ODP system info example\n");
printf("***********************************************************\n");
printf("\n");
parse_args(argc, argv, &appl_args);
ODPH_ERR("Global init failed.\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("Local init failed.\n");
exit(EXIT_FAILURE);
}
printf("\n");
printf("odp_sys_info_print()\n");
printf("***********************************************************\n");
printf("\n");
printf("odp_sys_config_print()\n");
printf("***********************************************************\n");
ODPH_ERR("system info call failed\n");
exit(EXIT_FAILURE);
}
num_hp_print = num_hp;
if (num_hp_print > MAX_HUGE_PAGES)
num_hp_print = MAX_HUGE_PAGES;
ODPH_ERR("shm capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("pool capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("external packet pool capability failed\n");
exit(EXIT_FAILURE);
}
if (pktio_capability(&appl_args)) {
ODPH_ERR("pktio capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("classifier capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("compression capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("dma capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("queue capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("schedule capability failed\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("stash capability failed\n");
exit(EXIT_FAILURE);
}
if (timer_capability(&appl_args)) {
ODPH_ERR("timer capability failed\n");
exit(EXIT_FAILURE);
}
if (num_engines > 0) {
if (ml_capa == NULL) {
ODPH_ERR("Failed to allocate memory for ML capabilities\n");
exit(EXIT_FAILURE);
}
for (i = 0; i < num_engines; i++) {
ODPH_ERR("ML engine %u capability failed\n", i + 1);
free(ml_capa);
exit(EXIT_FAILURE);
}
}
}
if (crypto_ret < 0)
ODPH_ERR("crypto capability failed\n");
if (ipsec_ret < 0)
ODPH_ERR("IPsec capability failed\n");
printf("\n");
printf("S Y S T E M I N F O R M A T I O N\n");
printf("***********************************************************\n");
printf("\n");
printf(" CPU arch: %s\n", cpu_arch_name(&sysinfo));
printf(" CPU ISA version: %s\n", cpu_arch_isa(&sysinfo, 0));
printf(" SW ISA version: %s\n", cpu_arch_isa(&sysinfo, 1));
printf(
" Current CPU freq: %" PRIu64
" hz\n",
odp_cpu_hz());
printf(" CPU available num: %i\n", num_ava);
printf(" CPU available mask: %s\n", ava_mask_str);
printf(" CPU worker num: %i\n", num_work);
printf(" CPU worker mask: %s\n", work_mask_str);
printf(" CPU control num: %i\n", num_ctrl);
printf(" CPU control mask: %s\n", ctrl_mask_str);
printf(" Byte order: %s (%i / %i)\n",
printf(" Bitfield order: %s (%i / %i)\n",
"big" : "little",
printf(" Num huge page sizes: %i\n", num_hp);
for (i = 0; i < num_hp_print; i++)
printf(" Huge page size [%i]: %" PRIu64 " kB\n",
i, huge_page[i] / KB);
printf("\n");
printf(" SHM\n");
printf(
" max_size: %" PRIu64
" MB\n", shm_capa.
max_size / MB);
printf(
" max_align: %" PRIu64
" B\n", shm_capa.
max_align);
printf(
" flags: 0x%x: %s%s%s%s%s%s\n", shm_capa.
flags,
print_atomic_lock_free();
printf("\n");
printf(" POOL\n");
printf(
" max_pools: %u\n", pool_capa.
max_pools);
printf(
" buf.max_size: %u kB\n", pool_capa.
buf.
max_size / KB);
printf(
" buf.max_num: %u\n", pool_capa.
buf.
max_num);
printf(
" buf.stats: 0x%" PRIx64
"\n", pool_capa.
buf.
stats.
all);
printf(
" pkt.max_len: %u kB\n", pool_capa.
pkt.
max_len / KB);
printf(
" pkt.max_num: %u\n", pool_capa.
pkt.
max_num);
printf(
" pkt.stats: 0x%" PRIx64
"\n", pool_capa.
pkt.
stats.
all);
printf(
" tmo.max_num: %u\n", pool_capa.
tmo.
max_num);
printf(
" tmo.stats: 0x%" PRIx64
"\n", pool_capa.
tmo.
stats.
all);
#define capa pool_capa.event_vector
printf(
" event_vector.max_pools: %u\n", capa.
max_pools);
printf(" event_vector.max_num: %u\n", capa.max_num);
printf(" event_vector.max_size: %u\n", capa.max_size);
printf(" event_vector.max_uarea_size: %u B\n", capa.max_uarea_size);
printf(" event_vector.uarea_persistence: %i\n", capa.uarea_persistence);
printf(" event_vector.min_cache_size: %u\n", capa.min_cache_size);
printf(" event_vector.max_cache_size: %u\n", capa.max_cache_size);
printf(" event_vector.stats: 0x%" PRIx64 "\n", capa.stats.all);
#undef capa
printf("\n");
printf(" POOL EXT (pkt)\n");
printf(
" max_pools: %u\n", pool_ext_capa.
max_pools);
printf(
" stats: 0x%" PRIx64
"\n", pool_ext_capa.
stats.
all);
}
print_pktio_capa(&appl_args);
print_proto_stats_capa(&appl_args);
printf("\n");
printf(" CLASSIFIER\n");
printf(
" max_pmr: %u\n", cls_capa.
max_pmr);
printf(
" max_cos: %u\n", cls_capa.
max_cos);
printf(
" back_pressure: %s\n", support_level(cls_capa.
back_pressure));
printf(
" max_mark: %" PRIu64
"\n", cls_capa.
max_mark);
#define aep_type cls_capa.aggr.enq_profile_type
printf(" aggr.enq_profile_type.ipv4_frag: %u\n", aep_type.ipv4_frag);
printf(" aggr.enq_profile_type.ipv6_frag: %u\n", aep_type.ipv6_frag);
printf(" aggr.enq_profile_type.custom: %u\n", aep_type.custom);
#undef aep_type
printf("\n");
printf(" COMPRESSION\n");
printf(
" sync support: %i\n", comp_capa.
sync);
printf(
" async support: %i\n", comp_capa.
async);
printf("\n");
printf(" DMA\n");
printf(
" max_segs: %u\n", dma_capa.
max_segs);
printf("\n");
printf(" QUEUE\n");
printf(
" max queues: %u\n", queue_capa.
max_queues);
printf("\n");
printf(" SCHEDULER\n");
printf(
" max_groups: %u\n", schedule_capa.
max_groups);
printf(
" min_prio: %u\n", schedule_capa.
min_prio);
printf(
" max_prios: %u\n", schedule_capa.
max_prios);
printf(
" max_queues: %u\n", schedule_capa.
max_queues);
printf(
" max_flow_id: %u\n", schedule_capa.
max_flow_id);
printf(
" lockfree_queues: %s\n", support_level(schedule_capa.
lockfree_queues));
printf(
" waitfree_queues: %s\n", support_level(schedule_capa.
waitfree_queues));
printf(
" order_wait: %s\n", support_level(schedule_capa.
order_wait));
printf(
" aggr.max_num: %u\n", schedule_capa.
aggr.
max_num);
printf(
" aggr.max_size: %u\n", schedule_capa.
aggr.
max_size);
printf(
" aggr.min_size: %u\n", schedule_capa.
aggr.
min_size);
printf(
" aggr.max_tmo_ns: %" PRIu64
"\n", schedule_capa.
aggr.
max_tmo_ns);
printf(
" aggr.min_tmo_ns: %" PRIu64
"\n", schedule_capa.
aggr.
min_tmo_ns);
printf("\n");
printf(" STASH\n");
printf(
" max_num_obj: %" PRIu64
"\n", stash_capa.
max_num_obj);
printf(
" max_num.u8: %" PRIu64
"\n", stash_capa.
max_num.
u8);
printf(
" max_num.u16: %" PRIu64
"\n", stash_capa.
max_num.
u16);
printf(
" max_num.u32: %" PRIu64
"\n", stash_capa.
max_num.
u32);
printf(
" max_num.u64: %" PRIu64
"\n", stash_capa.
max_num.
u64);
printf(
" max_num.u128: %" PRIu64
"\n", stash_capa.
max_num.
u128);
printf(
" stats: 0x%" PRIx64
"\n", stash_capa.
stats.
all);
printf("\n");
printf(" ML\n");
printf(" num_engines: %u\n", num_engines);
for (i = 0; i < num_engines; i++) {
printf(" engine %u:\n", i + 1);
printf(" max_models: %u\n", ml_capa[i].max_models);
printf(" max_models_loaded: %u\n", ml_capa[i].max_models_loaded);
printf(" max_model_size: %" PRIu64 "B\n", ml_capa[i].max_model_size);
printf(" max_compl_id: %u\n", ml_capa[i].max_compl_id);
printf(" max_inputs: %u\n", ml_capa[i].max_inputs);
printf(" max_outputs: %u\n", ml_capa[i].max_outputs);
printf(" max_segs_per_input: %u\n", ml_capa[i].max_segs_per_input);
printf(" max_segs_per_output:%u\n", ml_capa[i].max_segs_per_output);
printf(" min_input_align: %u\n", ml_capa[i].min_input_align);
printf(" min_output_align: %u\n", ml_capa[i].min_output_align);
printf(" packed_input_data: %u\n", ml_capa[i].packed_input_data);
printf(" packed_output_data: %u\n", ml_capa[i].packed_output_data);
printf(" load.compl_mode_mask: 0x%x\n", ml_capa[i].load.compl_mode_mask);
printf(" load.compl_queue_plain: %i\n", ml_capa[i].load.compl_queue_plain);
printf(" load.compl_queue_sched: %i\n", ml_capa[i].load.compl_queue_sched);
printf(" run.compl_mode_mask: 0x%x\n", ml_capa[i].run.compl_mode_mask);
printf(" run.compl_queue_plain: %i\n", ml_capa[i].run.compl_queue_plain);
printf(" run.compl_queue_sched: %i\n", ml_capa[i].run.compl_queue_sched);
printf(" pool.max_pools: %u\n", ml_capa[i].pool.max_pools);
printf(" pool.max_num: %u\n", ml_capa[i].pool.max_num);
printf(" pool.max_uarea_size:%u B\n", ml_capa[i].pool.max_uarea_size);
printf(" pool.uarea_persistence: %u\n", ml_capa[i].pool.uarea_persistence);
printf(" pool.min_cache_size: %u\n", ml_capa[i].pool.min_cache_size);
printf(" pool.max_cache_size: %u\n", ml_capa[i].pool.max_cache_size);
}
if (ml_capa)
free(ml_capa);
print_timer_capa(&appl_args);
if (crypto_ret == 0) {
printf("\n");
printf(" CRYPTO\n");
printf(
" sync mode support: %s\n", support_level(crypto_capa.
sync_mode));
printf(
" async mode support: %s\n", support_level(crypto_capa.
async_mode));
printf(" cipher algorithms: ");
foreach_cipher(crypto_capa.
ciphers, print_cipher);
printf("\n");
foreach_cipher(crypto_capa.
ciphers, print_cipher_capa);
printf(" cipher algorithms (HW): ");
foreach_cipher(crypto_capa.
hw_ciphers, print_cipher);
printf("\n");
foreach_cipher(crypto_capa.
hw_ciphers, print_cipher_capa);
printf(" auth algorithms: ");
foreach_auth(crypto_capa.
auths, print_auth);
printf("\n");
foreach_auth(crypto_capa.
auths, print_auth_capa);
printf(" auth algorithms (HW): ");
foreach_auth(crypto_capa.
hw_auths, print_auth);
printf("\n");
foreach_auth(crypto_capa.
hw_auths, print_auth_capa);
}
if (ipsec_ret == 0) {
printf("\n");
printf(" IPSEC\n");
printf(" sync mode support: %s\n",
printf(" async mode support: %s\n",
printf(" inline inbound mode support: %s\n",
printf(" inline outbound mode support: %s\n",
printf(" AH support: %s\n",
printf(" post-IPsec fragmentation: %s\n",
printf(" pre-IPsec fragmentation: %s\n",
printf(" post-IPsec classification: %s\n",
printf(" retaining outer headers: %s\n",
printf(" outbound operation options:\n");
printf(" frag_mode: %i\n",
printf(" tfc_pad: %i\n",
printf(" tfc_dummy: %i\n",
printf(" ip_param: %i\n",
printf(" inbound checksum offload support:\n");
printf(" IPv4 header checksum: %s\n",
printf(" UDP checksum: %s\n",
printf(" TCP checksum: %s\n",
printf(" SCTP checksum: %s\n",
printf(
" max destination CoSes: %u\n", ipsec_capa.
max_cls_cos);
printf(
" max destination queues: %u\n", ipsec_capa.
max_queues);
printf(" vector support: %s\n",
printf(" min_tmo_ns: %" PRIu64 " ns\n",
printf(" max_tmo_ns: %" PRIu64 " ns\n",
printf(" max anti-replay window size: %u\n",
printf(" inline TM pipelining: %s\n",
printf(" testing capabilities:\n");
printf(" sa_operations.seq_num: %i\n",
printf(" sa_operations.antireplay_window_top: %i\n",
printf(" post-IPsec reassembly support:\n");
printf(" max_wait_time: %" PRIu64 "\n",
printf(" max_num_frags: %" PRIu16 "\n",
printf(" cipher algorithms: ");
foreach_cipher(ipsec_capa.
ciphers, print_cipher);
printf("\n");
printf(" auth algorithms: ");
foreach_auth(ipsec_capa.
auths, print_auth);
printf("\n");
}
printf("\n");
printf(" SHM MEMORY BLOCKS:\n");
printf("\n");
printf("***********************************************************\n");
printf("\n");
ODPH_ERR("Local term failed.\n");
exit(EXIT_FAILURE);
}
ODPH_ERR("Global term failed.\n");
exit(EXIT_FAILURE);
}
return EXIT_SUCCESS;
}
int odp_atomic_lock_free_u64(odp_atomic_op_t *atomic_op)
Query which atomic uint64 operations are lock-free.
int odp_atomic_lock_free_u128(odp_atomic_op_t *atomic_op)
Query which atomic odp_atomic_u128_t operations are lock-free.
int odp_cls_capability(odp_cls_capability_t *capability)
Query classification capabilities.
#define ODP_BIG_ENDIAN_BITFIELD
Big endian bit field.
#define ODP_LITTLE_ENDIAN
Little endian byte order.
#define ODP_BITFIELD_ORDER
Selected bitfield order.
#define ODP_BIG_ENDIAN
Big endian byte order.
#define ODP_BYTE_ORDER
Selected byte order.
#define ODP_LITTLE_ENDIAN_BITFIELD
Little endian bit field.
int odp_comp_capability(odp_comp_capability_t *capa)
Query compression capabilities.
int odp_cpu_id(void)
CPU identifier.
int odp_cpu_count(void)
CPU count.
uint64_t odp_cpu_hz_max(void)
Maximum CPU frequency in Hz.
uint64_t odp_cpu_hz(void)
Current CPU frequency in Hz.
const char * odp_cpu_model_str(void)
CPU model name of this CPU.
int odp_cpumask_default_worker(odp_cpumask_t *mask, int num)
Default CPU mask for worker threads.
int odp_cpumask_all_available(odp_cpumask_t *mask)
Report all the available CPUs.
int odp_cpumask_default_control(odp_cpumask_t *mask, int num)
Default CPU mask for control threads.
int32_t odp_cpumask_to_str(const odp_cpumask_t *mask, char *str, int32_t size)
Format a string from CPU mask.
#define ODP_CPUMASK_STR_SIZE
The maximum number of characters needed to record any CPU mask as a string (output of odp_cpumask_to_...
int odp_crypto_cipher_capability(odp_cipher_alg_t cipher, odp_crypto_cipher_capability_t capa[], int num)
Query supported cipher algorithm capabilities.
odp_cipher_alg_t
Crypto API cipher algorithm.
int odp_crypto_capability(odp_crypto_capability_t *capa)
Query crypto capabilities.
odp_auth_alg_t
Crypto API authentication algorithm.
int odp_crypto_auth_capability(odp_auth_alg_t auth, odp_crypto_auth_capability_t capa[], int num)
Query supported authentication algorithm capabilities.
@ ODP_CIPHER_ALG_KASUMI_F8
Confidentiality F8 algorithm (UEA1)
@ ODP_CIPHER_ALG_AES_CFB128
AES with 128-bit cipher feedback.
@ ODP_CIPHER_ALG_ZUC_NEA6
NEA6 confidentiality algorithm.
@ ODP_CIPHER_ALG_SNOW5G_NEA4
NEA4 confidentiality algorithm.
@ ODP_CIPHER_ALG_SNOW3G_UEA2
Confidentiality UEA2 algorithm (128-EEA1)
@ ODP_CIPHER_ALG_SNOW_V_GCM
SNOW-V-GCM AEAD algorithm.
@ ODP_CIPHER_ALG_AES_CCM
AES-CCM.
@ ODP_CIPHER_ALG_SM4_CCM
SM4-CCM AEAD algorithm.
@ ODP_CIPHER_ALG_AES_ECB
AES with electronic codebook.
@ ODP_CIPHER_ALG_AES_CTR
AES with counter mode.
@ ODP_CIPHER_ALG_CHACHA20_POLY1305
ChaCha20-Poly1305.
@ ODP_CIPHER_ALG_AES_CBC
AES with cipher block chaining.
@ ODP_CIPHER_ALG_SM4_ECB
SM4 block cipher in ECB mode.
@ ODP_CIPHER_ALG_AES_GCM
AES-GCM.
@ ODP_CIPHER_ALG_3DES_CBC
Triple DES with cipher block chaining.
@ ODP_CIPHER_ALG_AES_EEA2
Confidentiality 128-EEA2 algorithm.
@ ODP_CIPHER_ALG_SM4_CBC
SM4 block cipher in CBC mode.
@ ODP_CIPHER_ALG_AES_XTS
AES with XEX-based tweaked-codebook mode with ciphertext stealing (XTS)
@ ODP_CIPHER_ALG_SM4_GCM
SM4-GCM AEAD algorithm.
@ ODP_CIPHER_ALG_NULL
No cipher algorithm specified.
@ ODP_CIPHER_ALG_ZUC_EEA3
ZUC based confidentiality algorithm.
@ ODP_CIPHER_ALG_SNOW_V
SNOW-V stream cipher.
@ ODP_CIPHER_ALG_3DES_ECB
Triple DES with Electronic Codebook.
@ ODP_CIPHER_ALG_SM4_CTR
SM4 block cipher in CTR mode.
@ ODP_AUTH_ALG_ZUC_NIA6
NIA6 integrity algorithm.
@ ODP_AUTH_ALG_SM4_GCM
SM4-GCM AEAD algorithm.
@ ODP_AUTH_ALG_MD5
MD5 algorithm.
@ ODP_AUTH_ALG_SHA384_HMAC
HMAC-SHA-384.
@ ODP_AUTH_ALG_CHACHA20_POLY1305
ChaCha20-Poly1305 AEAD.
@ ODP_AUTH_ALG_AES_CMAC
AES-CMAC.
@ ODP_AUTH_ALG_SHA384
384 bit SHA2 algorithm
@ ODP_AUTH_ALG_SM3
SM3 hash function.
@ ODP_AUTH_ALG_NULL
No authentication algorithm specified.
@ ODP_AUTH_ALG_SM4_CCM
SM4-CCM AEAD algorithm.
@ ODP_AUTH_ALG_SHA512
512 bit SHA2 algorithm
@ ODP_AUTH_ALG_SHA3_256
SHA-3 hash function producing 256-bit digests.
@ ODP_AUTH_ALG_MD5_HMAC
HMAC-MD5.
@ ODP_AUTH_ALG_SHA512_HMAC
HMAC-SHA-512.
@ ODP_AUTH_ALG_SHA1_HMAC
HMAC-SHA-1.
@ ODP_AUTH_ALG_SNOW5G_NIA4
NIA4 integrity algorithm.
@ ODP_AUTH_ALG_SHA256_HMAC
HMAC-SHA-256.
@ ODP_AUTH_ALG_SHA3_224_HMAC
HMAC using SHA3-224.
@ ODP_AUTH_ALG_SHA256
256 bit SHA2 algorithm
@ ODP_AUTH_ALG_SHA1
SHA1 algorithm.
@ ODP_AUTH_ALG_SNOW_V_GMAC
SNOW-V-GMAC.
@ ODP_AUTH_ALG_SNOW3G_UIA2
Integrity UIA2 algorithm (128-EIA1)
@ ODP_AUTH_ALG_SHA3_512
SHA-3 hash function producing 512-bit digests.
@ ODP_AUTH_ALG_SM3_HMAC
HMAC using SM3.
@ ODP_AUTH_ALG_SHA224_HMAC
HMAC-SHA-224.
@ ODP_AUTH_ALG_AES_GMAC
AES-GMAC.
@ ODP_AUTH_ALG_AES_XCBC_MAC
AES-XCBC-MAC.
@ ODP_AUTH_ALG_AES_GCM
AES-GCM.
@ ODP_AUTH_ALG_KASUMI_F9
Integrity F9 algorithm (UIA1)
@ ODP_AUTH_ALG_SHA3_256_HMAC
HMAC using SHA3-256.
@ ODP_AUTH_ALG_SHA3_384
SHA-3 hash function producing 384-bit digests.
@ ODP_AUTH_ALG_SM4_GMAC
SM4-GMAC.
@ ODP_AUTH_ALG_AES_CCM
AES-CCM.
@ ODP_AUTH_ALG_SHA3_224
SHA-3 hash function producing 224-bit digests.
@ ODP_AUTH_ALG_SNOW_V_GCM
SNOW-V-GCM AEAD algorithm.
@ ODP_AUTH_ALG_SHA3_384_HMAC
HMAC using SHA3-384.
@ ODP_AUTH_ALG_AES_EIA2
Integrity 128-EIA2 algorithm.
@ ODP_AUTH_ALG_SHA3_512_HMAC
HMAC using SHA3-512.
@ ODP_AUTH_ALG_ZUC_EIA3
ZUC-based integrity algorithm.
@ ODP_AUTH_ALG_SHA224
224 bit SHA2 algorithm
int odp_dma_capability(odp_dma_capability_t *capa)
Query DMA capabilities.
#define ODP_STATIC_ASSERT(cond, msg)
Compile time assertion macro.
int odp_init_local(odp_instance_t instance, odp_thread_type_t thr_type)
Thread local ODP initialization.
int odp_init_global(odp_instance_t *instance, const odp_init_t *params, const odp_platform_init_t *platform_params)
Global ODP initialization.
int odp_term_local(void)
Thread local ODP termination.
int odp_term_global(odp_instance_t instance)
Global ODP termination.
uint64_t odp_instance_t
ODP instance ID.
int odp_ipsec_capability(odp_ipsec_capability_t *capa)
Query IPSEC capabilities.
int odp_ml_num_engines(void)
Query number of ML engines.
int odp_ml_engine_capability(uint32_t engine_id, odp_ml_capability_t *capa)
Query ML capabilities of a specific engine.
void odp_pktio_param_init(odp_pktio_param_t *param)
Initialize pktio params.
int odp_pktio_close(odp_pktio_t pktio)
Close a packet IO interface.
odp_pktio_t odp_pktio_open(const char *name, odp_pool_t pool, const odp_pktio_param_t *param)
Open a packet IO interface.
#define ODP_PKTIO_INVALID
Invalid packet IO handle.
int odp_pktio_capability(odp_pktio_t pktio, odp_pktio_capability_t *capa)
Query packet IO interface capabilities.
@ ODP_PKTOUT_MODE_DIRECT
Direct packet output on the interface.
@ ODP_PKTIN_MODE_SCHED
Packet input through scheduler and scheduled event queues.
odp_pool_t odp_pool_create(const char *name, const odp_pool_param_t *param)
Create a pool.
int odp_pool_capability(odp_pool_capability_t *capa)
Query pool capabilities.
void odp_pool_param_init(odp_pool_param_t *param)
Initialize pool params.
int odp_pool_destroy(odp_pool_t pool)
Destroy a pool previously created by odp_pool_create()
int odp_pool_ext_capability(odp_pool_type_t type, odp_pool_ext_capability_t *capa)
Query capabilities of an external memory pool type.
#define ODP_POOL_INVALID
Invalid pool.
@ ODP_POOL_PACKET
Packet pool.
int odp_proto_stats_capability(odp_pktio_t pktio, odp_proto_stats_capability_t *capa)
Get proto stats capability.
int odp_queue_capability(odp_queue_capability_t *capa)
Query queue capabilities.
int odp_schedule_capability(odp_schedule_capability_t *capa)
Query scheduler capabilities.
void odp_shm_print_all(void)
Print all shared memory blocks.
#define ODP_SHM_EXPORT
Export memory.
#define ODP_SHM_SINGLE_VA
Single virtual address.
int odp_shm_capability(odp_shm_capability_t *capa)
Query shared memory capabilities.
#define ODP_SHM_PROC
Share with external processes.
#define ODP_SHM_HP
Use huge pages.
#define ODP_SHM_NO_HP
Don't use huge pages.
#define ODP_SHM_HW_ACCESS
Share memory with HW accelerators.
int odp_stash_capability(odp_stash_capability_t *capa, odp_stash_type_t type)
Query stash capabilities.
@ ODP_STASH_TYPE_DEFAULT
The default stash type.
odp_support_t
ODP support.
@ ODP_SUPPORT_PREFERRED
Feature is supported and preferred.
@ ODP_SUPPORT_YES
Feature is supported.
@ ODP_SUPPORT_NO
Feature is not supported.
odp_cpu_arch_x86_t
x86 ISA versions
int odp_sys_cache_line_size(void)
Cache line size in bytes.
uint64_t odp_sys_huge_page_size(void)
Default system huge page size in bytes.
uint64_t odp_sys_page_size(void)
Page size in bytes.
int odp_system_info(odp_system_info_t *info)
Retrieve system information.
int odp_sys_huge_page_size_all(uint64_t size[], int num)
System huge page sizes in bytes.
odp_cpu_arch_arm_t
ARM ISA versions.
void odp_sys_info_print(void)
Print system info.
void odp_sys_config_print(void)
Print configuration.
odp_cpu_arch_t
CPU instruction set architecture (ISA) families.
@ ODP_CPU_ARCH_X86_I686
x86 32bit ISA
@ ODP_CPU_ARCH_X86_64
x86 64bit ISA
@ ODP_CPU_ARCH_ARMV8_1
ARMv8.1-A ISA.
@ ODP_CPU_ARCH_ARMV8_0
ARMv8.0-A ISA.
@ ODP_CPU_ARCH_ARMV9_1
ARMv9.1-A ISA.
@ ODP_CPU_ARCH_ARMV8_4
ARMv8.4-A ISA.
@ ODP_CPU_ARCH_ARMV8_8
ARMv8.8-A ISA.
@ ODP_CPU_ARCH_ARMV8_9
ARMv8.9-A ISA.
@ ODP_CPU_ARCH_ARMV7
ARMv7-A ISA.
@ ODP_CPU_ARCH_ARMV6
ARMv6 ISA.
@ ODP_CPU_ARCH_ARMV9_3
ARMv9.3-A ISA.
@ ODP_CPU_ARCH_ARMV8_6
ARMv8.6-A ISA.
@ ODP_CPU_ARCH_ARMV9_2
ARMv9.2-A ISA.
@ ODP_CPU_ARCH_ARMV8_3
ARMv8.3-A ISA.
@ ODP_CPU_ARCH_ARMV8_2
ARMv8.2-A ISA.
@ ODP_CPU_ARCH_ARMV9_0
ARMv9.0-A ISA.
@ ODP_CPU_ARCH_ARMV8_5
ARMv8.5-A ISA.
@ ODP_CPU_ARCH_ARMV8_7
ARMv8.7-A ISA.
@ ODP_CPU_ARCH_PPC
PowerPC.
@ ODP_CPU_ARCH_RISCV
RISC-V.
#define ODP_THREAD_COUNT_MAX
Maximum number of threads supported in build time.
int odp_thread_count_max(void)
Maximum thread count.
@ ODP_THREAD_CONTROL
Control thread.
int odp_timer_pool_start_multi(odp_timer_pool_t timer_pool[], int num)
Start timer pools.
#define ODP_TIMER_POOL_INVALID
Invalid timer pool handle.
odp_timer_pool_t odp_timer_pool_create(const char *name, const odp_timer_pool_param_t *params)
Create a timer pool.
int odp_timer_capability(odp_timer_clk_src_t clk_src, odp_timer_capability_t *capa)
Query timer capabilities per clock source.
int odp_timer_pool_info(odp_timer_pool_t timer_pool, odp_timer_pool_info_t *info)
Query timer pool configuration and current state.
#define ODP_CLOCK_DEFAULT
The default clock source.
void odp_timer_pool_param_init(odp_timer_pool_param_t *param)
Initialize timer pool parameters.
void odp_timer_pool_destroy(odp_timer_pool_t timer_pool)
Destroy a timer pool.
@ ODP_CLOCK_NUM_SRC
Number of clock source enumerations.
const char * odp_version_impl_str(void)
Implementation version string.
const char * odp_version_impl_name(void)
Implementation name string.
const char * odp_version_api_str(void)
ODP API version string.
Classification capabilities This capability structure defines system level classification capability.
uint32_t max_pmr
Maximum number of single-term PMRs.
uint64_t max_mark
Maximum value of odp_pmr_create_opt_t::mark.
uint32_t max_hash_queues
Maximum number of queues supported per CoS.
odp_threshold_types_t threshold_red
Supported threshold type for RED.
odp_support_t back_pressure
Support for Back Pressure to the remote peer.
uint32_t max_terms_per_pmr
Maximum number of terms per composite PMR.
odp_threshold_types_t threshold_bp
Supported threshold type for BP.
odp_cls_pmr_terms_t supported_terms
PMR terms supported by the classifier.
uint32_t max_cos
Maximum number of CoS supported.
odp_support_t random_early_detection
Support for Random Early Detection.
odp_pktin_hash_proto_t hash_protocols
Protocol header combination supported for Hashing.
uint32_t max_pmr_priority
Maximum priority value of a PMR.
odp_bool_t pmr_range_supported
A Boolean to denote support of PMR range.
uint32_t max_pmr_per_cos
Maximum number of PMRs per CoS.
odp_cls_stats_capability_t stats
Statistics counters capabilities.
struct odp_cls_stats_capability_t::@9 queue
Queue level capabilities.
uint64_t all_counters
All bits of the bit field structure.
Compression Interface Capabilities.
odp_support_t sync
Synchronous compression mode support (ODP_COMP_OP_MODE_SYNC)
uint32_t max_sessions
Maximum number of sessions.
odp_support_t async
Asynchronous compression mode support (ODP_COMP_OP_MODE_ASYNC)
odp_comp_hash_algos_t hash_algos
Supported hash algorithms.
odp_comp_algos_t comp_algos
Supported compression algorithms.
Authentication algorithm capabilities.
odp_support_t async_mode
Supported packet operation in ASYNC mode.
odp_bool_t queue_type_sched
Scheduled crypto completion queue support.
odp_crypto_cipher_algos_t ciphers
Supported cipher algorithms.
odp_crypto_auth_algos_t hw_auths
Authentication algorithms implemented with HW offload.
odp_crypto_cipher_algos_t hw_ciphers
Cipher algorithms implemented with HW offload.
odp_support_t sync_mode
Supported packet operation in SYNC mode.
odp_bool_t queue_type_plain
Plain crypto completion queue support.
odp_crypto_auth_algos_t auths
Supported authentication algorithms.
uint32_t max_sessions
Maximum number of crypto sessions.
Cipher algorithm capabilities.
uint32_t max_sessions
Maximum number of DMA sessions.
uint32_t max_transfers
Maximum number of transfers per DMA session.
odp_bool_t dst_seg_alloc
Destination segment allocation support for data format ODP_DMA_FORMAT_PACKET.
odp_dma_pool_capability_t pool
DMA completion event pool capabilities.
uint32_t max_segs
Maximum number of destination and source segments combined in a single transfer.
uint32_t max_dst_segs
Maximum number of destination segments in a single transfer.
uint32_t max_src_segs
Maximum number of source segments in a single transfer.
odp_bool_t queue_type_sched
Scheduled queue support.
odp_dma_compl_mode_t compl_mode_mask
Supported completion modes.
uint32_t max_seg_len
Maximum segment length in bytes.
odp_bool_t queue_type_plain
Plain queue support.
odp_bool_t src_seg_free
Source segment free support for data format ODP_DMA_FORMAT_PACKET.
odp_bool_t uarea_persistence
Pool user area persistence.
uint32_t min_cache_size
Minimum size of thread local cache.
uint32_t max_cache_size
Maximum size of thread local cache.
uint32_t max_uarea_size
Maximum user area size in bytes.
uint32_t max_pools
Maximum number of DMA completion event pools.
uint32_t max_num
Maximum number of DMA completion events in a pool.
uint32_t max_size
Maximum number of events that can be aggregated into an event vector.
uint64_t min_tmo_ns
Minimum time in nanoseconds for an aggregator to form an event vector.
uint32_t max_num_per_queue
Maximum number of event aggregators per queue.
uint32_t min_size
Minimum number of events that can be aggregated into an event vector.
uint64_t max_tmo_ns
Maximum allowed value of odp_event_aggr_config_t::max_tmo_ns.
uint32_t max_num
Maximum number of event aggregators for this queue type.
uint64_t integer
Integer part.
uint64_t denom
Denominator of the fraction part.
uint64_t numer
Numerator of the fraction part.
odp_reass_capability_t reassembly
Post-IPsec reassembly capability.
odp_ipsec_out_op_capability_t out_op
Outbound operation specific capabilities.
odp_bool_t reass_inline
Support of reassembly after inline inbound IPsec processing.
uint32_t max_cls_cos
Maximum number of different destination CoSes in classification pipelining.
odp_crypto_cipher_algos_t ciphers
Supported cipher algorithms.
odp_support_t frag_after
Fragment after IPsec support.
odp_support_t inline_ipsec_tm
Support of traffic manager (TM) after inline outbound IPSEC processing.
odp_pktin_vector_capability_t vector
Support for returning completion packets as vectors.
odp_bool_t queue_type_sched
Scheduled queue support.
odp_support_t op_mode_sync
Synchronous IPSEC operation mode (ODP_IPSEC_OP_MODE_SYNC) support.
odp_support_t frag_before
Fragment before IPsec support.
odp_support_t op_mode_inline_in
Inline inbound IPSEC operation mode (ODP_IPSEC_OP_MODE_INLINE) support.
odp_support_t op_mode_inline_out
Inline outgoing IPSEC operation mode (ODP_IPSEC_OP_MODE_INLINE) support.
odp_support_t pipeline_cls
Support of pipelined classification (ODP_IPSEC_PIPELINE_CLS) of resulting inbound packets.
uint32_t max_antireplay_ws
Maximum anti-replay window size.
uint32_t max_num_sa
Maximum number of IPSEC SAs.
odp_proto_chksums_t chksums_in
Inner packet checksum check offload support in inbound direction.
odp_support_t op_mode_async
Asynchronous IPSEC operation mode (ODP_IPSEC_OP_MODE_ASYNC) support.
odp_crypto_auth_algos_t auths
Supported authentication algorithms.
uint32_t max_queues
Maximum number of different destination queues.
odp_support_t retain_header
Support of retaining outer headers (retain_outer) in inbound inline processed packets.
odp_bool_t queue_type_plain
Plain queue support.
odp_bool_t reass_async
Support of reassembly after inbound processing in odp_ipsec_in_enq()
odp_ipsec_test_capability_t test
IPSEC TEST capabilities.
odp_support_t proto_ah
IP Authenticated Header (ODP_IPSEC_AH) support.
uint8_t ip_param
IP parameters option supported.
uint8_t tfc_dummy
TFC dummy packet option supported.
uint8_t frag_mode
fragmentation mode option supported
uint8_t tfc_pad
TFC padding length option supported.
struct odp_ipsec_out_op_capability_t::@46 opt
Supported outbound operation option flags.
odp_bool_t antireplay_window_top
Highest authenticated sequence number.
odp_bool_t seq_num
Next sequence number value.
struct odp_ipsec_test_capability_t::@47 sa_operations
Parameters supported for sa_update.
uint32_t max_payload_len
Maximum payload length per an LSO generated packet (in bytes).
uint32_t max_packet_segments
Maximum number of segments in an input packet.
uint32_t max_segments
Maximum number of segments an LSO operation may create.
uint32_t max_profiles
Maximum number of LSO profiles.
uint32_t sctp_ipv4
ODP_LSO_PROTO_SCTP_IPV4 support.
uint32_t max_profiles_per_pktio
Maximum number of LSO profiles per packet IO interface.
uint16_t add_payload_len
ODP_LSO_ADD_PAYLOAD_LEN support.
uint8_t max_num_custom
Maximum number of custom fields supported per LSO profile.
uint16_t write_bits
ODP_LSO_WRITE_BITS support.
uint32_t tcp_ipv4
ODP_LSO_PROTO_TCP_IPV4 support.
uint16_t add_segment_num
ODP_LSO_ADD_SEGMENT_NUM support.
uint32_t ipv4
ODP_LSO_PROTO_IPV4 support.
uint32_t max_payload_offset
Maximum supported offset to the packet payload (in bytes).
struct odp_lso_capability_t::@113 mod_op
Supported LSO custom modification options.
struct odp_lso_capability_t::@114 proto
Supported LSO protocol options.
uint32_t tcp_ipv6
ODP_LSO_PROTO_TCP_IPV6 support.
uint32_t custom
ODP_LSO_PROTO_CUSTOM support.
uint32_t sctp_ipv6
ODP_LSO_PROTO_SCTP_IPV6 support.
uint32_t ipv6
ODP_LSO_PROTO_IPV6 support.
uint16_t add_payload_offset
ODP_LSO_ADD_PAYLOAD_OFFSET support.
Machine learning capabilities.
uint8_t static_ref
Static reference.
uint8_t referenced_pkt
A packet referenced by another packet (excluding static references)
uint8_t referencing_pkt
Referencing packet, created using odp_packet_ref()
uint64_t max_tmo_ns
Maximum timeout in nanoseconds for the producer to wait for the vector of packets.
uint64_t min_tmo_ns
Minimum value allowed to be configured to odp_pktin_vector_config_t::max_tmo_ns.
uint32_t min_size
Minimum value allowed to be configured to odp_pktin_vector_config_t::max_size.
uint32_t max_size
Maximum number of packets that can be accumulated into a packet vector by a producer.
odp_support_t supported
Packet input vector availability.
struct odp_pktio_capability_t::@117 free_ctrl
Supported packet free control options.
odp_bool_t queue_type_sched
Scheduled queue support.
odp_bool_t equal
Equal maximum frame length for both packet input and output.
uint32_t mode_poll
Packet transmit completion mode ODP_PACKET_TX_COMPL_POLL support.
odp_pktio_set_op_t set_op
Supported set operations.
uint32_t pfc_tx
Generation of PFC frames.
uint32_t max_output
Maximum valid value for 'maxlen_output'.
uint32_t pfc_rx
Reception of PFC frames.
odp_pktin_vector_capability_t vector
Packet input vector capability.
uint32_t max_input_queues
Maximum number of input queues.
uint32_t max_input
Maximum valid value for 'maxlen_input'.
odp_pktio_config_t config
Supported pktio configuration options.
odp_packet_ref_types_t packet_ref
Supported packet reference types.
struct odp_pktio_capability_t::@115 maxlen
Supported frame lengths for odp_pktio_maxlen_set()
uint32_t min_output
Minimum valid value for 'maxlen_output'.
uint32_t max_output_queue_size
Maximum output queue size.
uint32_t max_output_queues
Maximum number of output queues.
uint32_t max_compl_id
Maximum supported completion ID value.
uint32_t min_output_queue_size
Minimum output queue size.
uint64_t max_tx_aging_tmo_ns
Max Tx aging timeout in nano seconds supported when packet aging feature is supported.
uint32_t dont_free
Packet free control option ODP_PACKET_FREE_CTRL_DONT_FREE support with odp_packet_free_ctrl_set().
uint32_t min_input
Minimum valid value for 'maxlen_input'.
odp_pktio_stats_capability_t stats
Statistics counters capabilities.
odp_lso_capability_t lso
LSO capabilities.
uint32_t mode_event
Packet transmit completion mode ODP_PACKET_TX_COMPL_EVENT support.
uint32_t max_input_queue_size
Maximum input queue size.
struct odp_pktio_capability_t::@116 tx_compl
Supported packet Tx completion options.
odp_bool_t queue_type_plain
Plain queue support.
uint32_t pause_tx
Generation of traditional Ethernet pause frames.
uint32_t pause_rx
Reception of traditional Ethernet pause frames.
struct odp_pktio_capability_t::@118 flow_control
Supported flow control modes.
uint32_t min_input_queue_size
Minimum input queue size.
odp_reass_capability_t reassembly
Packet input reassembly capability.
odp_pktout_config_opt_t pktout
Packet output configuration options bit field.
odp_pktin_config_opt_t pktin
Packet input configuration options bit field.
odp_pktin_mode_t in_mode
Packet input mode.
odp_pktout_mode_t out_mode
Packet output mode.
uint64_t all_counters
All bits of the bit field structure.
struct odp_pktio_stats_capability_t::@95 pktio
Interface level capabilities.
struct odp_pktio_stats_capability_t::@96 pktin_queue
Input queue level capabilities.
struct odp_pktio_stats_capability_t::@97 pktout_queue
Output queue level capabilities.
uint32_t max_align
Maximum buffer data alignment in bytes.
uint32_t max_headroom
Maximum packet level headroom length in bytes.
uint32_t min_headroom
Minimum packet level headroom length in bytes.
uint32_t max_num
Maximum number of buffers of any size.
uint32_t min_cache_size
Minimum size of thread local cache.
struct odp_pool_capability_t::@133 buf
Buffer pool capabilities
struct odp_pool_capability_t::@135 tmo
Timeout pool capabilities
uint32_t max_segs_per_pkt
Maximum number of segments per packet.
odp_bool_t uarea_persistence
Pool user area persistence.
uint32_t max_uarea_size
Maximum user area size in bytes.
struct odp_pool_capability_t::@134 pkt
Packet pool capabilities
uint32_t max_size
Maximum buffer data size in bytes.
struct odp_pool_capability_t::@136 vector
Vector pool capabilities.
uint8_t max_num_subparam
Maximum number of subparameters.
odp_pool_stats_opt_t stats
Supported statistics counters.
uint32_t max_cache_size
Maximum size of thread local cache.
uint32_t min_seg_len
Minimum packet segment data length in bytes.
uint32_t max_pools
Maximum number of pools of any type (odp_pool_type_t)
uint32_t min_tailroom
Minimum packet level tailroom length in bytes.
uint32_t max_seg_len
Maximum packet segment data length in bytes.
uint32_t max_len
Maximum packet data length in bytes.
External memory pool capabilities.
uint16_t buf_size_aligned
Packet buffers are size aligned.
uint32_t max_pools
Maximum number of pools.
uint32_t max_num_buf
Maximum number of packet buffers.
odp_bool_t uarea_persistence
Pool user area persistence.
uint32_t max_segs_per_pkt
Maximum number of segments per packet.
uint32_t max_headroom
Maximum headroom parameter value.
uint32_t odp_trailer_size
ODP trailer size in bytes.
uint32_t min_mem_align
Minimum packet pool memory area alignment in bytes.
uint32_t max_uarea_size
Maximum user area size in bytes.
uint32_t min_head_align
Minimum packet headroom alignment in bytes.
uint32_t min_cache_size
Minimum size of thread local cache.
odp_pool_stats_opt_t stats
Supported statistics counters.
uint32_t max_headroom_size
Maximum headroom size in bytes.
struct odp_pool_ext_capability_t::@144 pkt
Packet pool capabilities
uint32_t max_cache_size
Maximum size of thread local cache.
uint32_t odp_header_size
ODP header size in bytes.
uint32_t max_buf_size
Maximum packet buffer size in bytes.
uint32_t min_buf_align
Minimum packet buffer pointer alignment in bytes.
uint32_t num
Number of buffers in the pool.
struct odp_pool_param_t::@139 pkt
Parameters for packet pools.
odp_pool_type_t type
Pool type.
Proto stats capabilities.
odp_proto_stats_counters_t counters
Stats counters supported.
odp_bool_t oct_count1_adj
Packet adjust support for Octet counter 1.
odp_bool_t oct_count0_adj
Packet adjust support for Octet counter 0.
struct odp_proto_stats_capability_t::@153 tx
Tx capabilities.
struct odp_queue_capability_t::@155 plain
Plain queue capabilities.
uint32_t max_size
Maximum number of events a plain (ODP_BLOCKING) queue can store simultaneously.
uint32_t max_num
Maximum number of plain (ODP_BLOCKING) queues of the default size.
struct odp_queue_capability_t::@155::@156 lockfree
Lock-free (ODP_NONBLOCKING_LF) implementation capabilities.
struct odp_queue_capability_t::@155::@157 waitfree
Wait-free (ODP_NONBLOCKING_WF) implementation capabilities.
uint32_t max_queues
Maximum number of event queues of any type (default size).
odp_event_aggr_capability_t aggr
Event vector generation capabilities.
uint16_t max_num_frags
Maximum number of fragments that can be reassembled.
odp_bool_t ipv4
Reassembly offload for IPv4 packets.
odp_bool_t ipv6
Reassembly offload for IPv6 packets.
odp_bool_t ip
Reassembly offload for both IPv4 and IPv6 packets.
uint64_t max_wait_time
Maximum time in ns that a fragment can wait in the reassembly offload for the arrival of further frag...
uint32_t max_flow_id
Maximum flow ID per queue.
odp_support_t order_wait
Order wait support.
uint32_t max_groups
Maximum number of scheduling groups.
uint32_t max_queues
Maximum number of scheduled (ODP_BLOCKING) queues of the default size.
odp_support_t waitfree_queues
Wait-free (ODP_NONBLOCKING_WF) queues support.
odp_support_t lockfree_queues
Lock-free (ODP_NONBLOCKING_LF) queues support.
uint32_t max_queue_size
Maximum number of events a scheduled (ODP_BLOCKING) queue can store simultaneously.
odp_schedule_prio_t min_prio
Minimum scheduling priority value.
uint32_t max_group_prios
Maximum simultaneous number of group and priority combinations.
uint32_t max_ordered_locks
Maximum number of ordered locks per queue.
uint32_t max_prios
Number of scheduling priorities.
odp_event_aggr_capability_t aggr
Event aggregator capabilities for scheduled queues.
Shared memory capabilities.
uint32_t max_blocks
Maximum number of shared memory blocks.
uint32_t flags
Supported shared memory flags.
uint64_t max_size
Maximum memory block size in bytes.
uint64_t max_align
Maximum memory block alignment in bytes.
Stash capabilities (per stash type)
uint64_t u16
Maximum number of 2 byte object handles.
uint32_t max_stashes_any_type
Maximum number of stashes of any type.
uint32_t max_get_batch
Maximum number of object handles in batch get operations.
uint64_t u128
Maximum number of 16 byte object handles.
uint32_t max_put_batch
Maximum number of object handles in batch put operations.
uint64_t max_obj_size
Maximum number of 'max_obj_size' object handles.
uint32_t max_stashes
Maximum number of stashes of this type.
uint64_t u64
Maximum number of 8 byte object handles.
odp_stash_stats_opt_t stats
Supported statistics counters.
uint32_t max_cache_size
Maximum size of thread local cache.
uint64_t u32
Maximum number of 4 byte object handles.
uint64_t max_num_obj
Maximum common number of object handles per stash for any object size.
uint64_t u8
Maximum number of 1 byte object handles.
struct odp_stash_capability_t::@171 max_num
Maximum number of object handles per stash for each object size.
odp_cpu_arch_isa_t cpu_isa_hw
ISA version of CPU hardware.
odp_cpu_arch_t cpu_arch
CPU architecture.
odp_cpu_arch_isa_t cpu_isa_sw
ISA version of ODP software.
odp_fract_u64_t min_base_freq_hz
Minimum supported base frequency value.
uint16_t max_priority
Maximum single shot timer pool priority.
uint32_t max_pending_tmo
Maximum value for odp_timer_pool_param_t::periodic::max_pending_tmo.
struct odp_timer_capability_t::@186 periodic
Periodic timer capabilities.
uint32_t max_timers
Maximum number of single shot timers in a pool.
struct odp_timer_capability_t::@186::@187 support
Supported period configuration types.
uint32_t max_pools_combined
Maximum number of timer pools.
uint32_t max_pools
Maximum number of timer pools for single shot timers (per clock source)
uint32_t freq
ODP_TIMER_TYPE_PERIODIC_FREQ supported.
odp_timer_res_capability_t max_tmo
Maximum timeout length.
odp_fract_u64_t max_base_freq_hz
Maximum supported base frequency value.
odp_timer_res_capability_t max_res
Maximum resolution.
uint32_t min_pending_tmo
Minimum value for odp_timer_pool_param_t::periodic::max_pending_tmo.
odp_bool_t queue_type_plain
Plain queue destination support.
odp_fract_u64_t max_freq_hz
Maximum supported periodic timer frequency value.
uint32_t base_mul
ODP_TIMER_TYPE_PERIODIC_BASE_MUL supported.
uint64_t highest_res_ns
Highest timer resolution in nanoseconds.
odp_bool_t queue_type_sched
Scheduled queue destination support.
odp_fract_u64_t min_freq_hz
Minimum supported periodic timer frequency value.
ODP timer pool information and configuration.
odp_timer_tick_info_t tick_info
Timer pool tick information.
uint64_t res_ns
Timeout resolution in nanoseconds.
uint64_t min_tmo
Minimum relative timeout in nanoseconds.
uint32_t num_timers
Number of timers in the pool.
odp_timer_clk_src_t clk_src
Clock source for timers.
uint64_t max_tmo
Maximum relative timeout in nanoseconds.
uint64_t res_hz
Timeout resolution in hertz.
uint64_t max_tmo
Maximum relative timeout in nanoseconds.
uint64_t min_tmo
Minimum relative timeout in nanoseconds.
uint64_t res_ns
Timeout resolution in nanoseconds.
odp_fract_u64_t clk_cycle
One timer tick in source clock cycles.
odp_fract_u64_t freq
Timer tick frequency in hertz.
odp_fract_u64_t nsec
One timer tick in nanoseconds.
uint32_t fetch_max
Atomic fetch and maximum.
struct odp_atomic_op_t::@2 op
Operation flags.
uint32_t bit_clr
Atomic bit clear.
uint32_t fetch_add
Atomic fetch and add.
uint32_t fetch_sub
Atomic fetch and subtract.
uint32_t xchg
Atomic exchange.
uint32_t bit_set
Atomic bit set.
uint32_t sub
Atomic subtract.
uint32_t load
Atomic load.
uint32_t fetch_dec
Atomic fetch and decrement.
uint32_t fetch_inc
Atomic fetch and increment.
uint32_t inc
Atomic increment.
uint32_t bit_fetch_set
Atomic bit fetch and set.
uint32_t min
Atomic minimum.
uint32_t max
Atomic maximum.
uint32_t cas
Atomic compare and swap.
uint32_t store
Atomic store.
uint32_t fetch_min
Atomic fetch and minimum.
uint32_t dec
Atomic decrement.
uint32_t bit_fetch_clr
Atomic bit fetch and clear.
uint64_t all_bits
All bits of the bit field structure.
uint32_t all_bits
All bits of the bit field structure This field can be used to set/clear all flags,...
uint32_t all_bits
All bits of the bit field structure.
odp_cpu_arch_arm_t arm
ARM ISA versions.
odp_cpu_arch_x86_t x86
x86 ISA versions
Authentication algorithms in a bit field structure.
uint32_t md5
ODP_AUTH_ALG_MD5.
uint32_t sha3_512_hmac
ODP_AUTH_ALG_SHA3_512_HMAC.
uint32_t sha384
ODP_AUTH_ALG_SHA384.
uint32_t sha224
ODP_AUTH_ALG_SHA224.
uint32_t sha3_224
ODP_AUTH_ALG_SHA3_224.
uint32_t sm3
ODP_AUTH_ALG_SM3.
uint32_t null
ODP_AUTH_ALG_NULL.
uint32_t sha1_hmac
ODP_AUTH_ALG_SHA1_HMAC.
uint32_t sha512_hmac
ODP_AUTH_ALG_SHA512_HMAC.
uint32_t sha256
ODP_AUTH_ALG_SHA256.
uint32_t sha224_hmac
ODP_AUTH_ALG_SHA224_HMAC.
uint32_t sm4_gmac
ODP_AUTH_ALG_SM4_GMAC.
uint32_t sha3_512
ODP_AUTH_ALG_SHA3_512.
uint32_t aes_cmac
ODP_AUTH_ALG_AES_CMAC.
uint32_t zuc_eia3
ODP_AUTH_ALG_ZUC_EIA3.
uint32_t kasumi_f9
ODP_AUTH_ALG_KASUMI_F9.
uint32_t sm4_ccm
ODP_AUTH_ALG_SM4_CCM.
uint32_t snow3g_uia2
ODP_AUTH_ALG_SNOW3G_UIA2.
uint32_t snow_v_gmac
ODP_AUTH_ALG_SNOW_V_GMAC.
uint32_t aes_gmac
ODP_AUTH_ALG_AES_GMAC.
uint32_t sm4_gcm
ODP_AUTH_ALG_SM4_GCM.
uint32_t sha3_224_hmac
ODP_AUTH_ALG_SHA3_224_HMAC.
uint32_t aes_gcm
ODP_AUTH_ALG_AES_GCM.
uint32_t sm3_hmac
ODP_AUTH_ALG_SM3_HMAC.
uint32_t snow_v_gcm
ODP_AUTH_ALG_SNOW_V_GCM.
uint32_t md5_hmac
ODP_AUTH_ALG_MD5_HMAC.
uint32_t sha1
ODP_AUTH_ALG_SHA1.
uint32_t sha3_384_hmac
ODP_AUTH_ALG_SHA3_384_HMAC.
uint32_t aes_xcbc_mac
ODP_AUTH_ALG_AES_XCBC_MAC.
uint32_t sha3_256
ODP_AUTH_ALG_SHA3_256.
uint32_t sha384_hmac
ODP_AUTH_ALG_SHA384_HMAC.
uint32_t sha256_hmac
ODP_AUTH_ALG_SHA256_HMAC.
uint32_t aes_eia2
ODP_AUTH_ALG_AES_EIA2.
uint32_t sha3_256_hmac
ODP_AUTH_ALG_SHA3_256_HMAC.
uint32_t chacha20_poly1305
ODP_AUTH_ALG_CHACHA20_POLY1305.
uint32_t sha512
ODP_AUTH_ALG_SHA512.
struct odp_crypto_auth_algos_t::@25 bit
Authentication algorithms.
uint32_t zuc_nia6
ODP_AUTH_ALG_ZUC_NIA6.
uint32_t aes_ccm
ODP_AUTH_ALG_AES_CCM.
uint32_t snow5g_nia4
ODP_AUTH_ALG_SNOW5G_NIA4.
uint32_t sha3_384
ODP_AUTH_ALG_SHA3_384.
Cipher algorithms in a bit field structure.
uint32_t snow_v
ODP_CIPHER_ALG_SNOW_V.
struct odp_crypto_cipher_algos_t::@24 bit
Cipher algorithms.
uint32_t sm4_cbc
ODP_CIPHER_ALG_SM4_CBC.
uint32_t aes_cfb128
ODP_CIPHER_ALG_AES_CFB128.
uint32_t zuc_nea6
ODP_CIPHER_ALG_ZUC_NEA6.
uint32_t aes_gcm
ODP_CIPHER_ALG_AES_GCM.
uint32_t trides_cbc
ODP_CIPHER_ALG_3DES_CBC.
uint32_t snow_v_gcm
ODP_CIPHER_ALG_SNOW_V_GCM.
uint32_t sm4_ecb
ODP_CIPHER_ALG_SM4_ECB.
uint32_t aes_eea2
ODP_CIPHER_ALG_AES_EEA2.
uint32_t aes_ctr
ODP_CIPHER_ALG_AES_CTR.
uint32_t aes_cbc
ODP_CIPHER_ALG_AES_CBC.
uint32_t sm4_ctr
ODP_CIPHER_ALG_SM4_CTR.
uint32_t des
ODP_CIPHER_ALG_DES.
uint32_t aes_xts
ODP_CIPHER_ALG_AES_XTS.
uint32_t snow5g_nea4
ODP_CIPHER_ALG_SNOW5G_NEA4.
uint32_t zuc_eea3
ODP_CIPHER_ALG_ZUC_EEA3.
uint32_t null
ODP_CIPHER_ALG_NULL.
uint32_t sm4_gcm
ODP_CIPHER_ALG_SM4_GCM.
uint32_t kasumi_f8
ODP_CIPHER_ALG_KASUMI_F8.
uint32_t sm4_ccm
ODP_CIPHER_ALG_SM4_CCM.
uint32_t aes_ecb
ODP_CIPHER_ALG_AES_ECB.
uint32_t chacha20_poly1305
ODP_CIPHER_ALG_CHACHA20_POLY1305.
uint32_t trides_ecb
ODP_CIPHER_ALG_3DES_ECB.
uint32_t snow3g_uea2
ODP_CIPHER_ALG_SNOW3G_UEA2.
uint32_t aes_ccm
ODP_CIPHER_ALG_AES_CCM.
uint64_t all_bits
All bits of the bit field structure.
uint32_t all_bits
All bits of the bit field structure.
uint32_t all_bits
All bits of the bit field structure.
uint64_t all_bits
All bits of the bit field structure.
uint64_t all
All bits of the bit field structure.
uint32_t sctp
SCTP checksum.
uint32_t ipv4
IPv4 header checksum.
struct odp_proto_chksums_t::@124 chksum
Individual checksum bits.
uint32_t tcp
TCP checksum.
uint32_t udp
UDP checksum.
uint64_t all_bits
All bits of the bit field structure.
uint64_t all
All bits of the bit field structure.
uint8_t all_bits
All bits of the bit field structure.