API Reference Manual  1.45.0
odp_pktin_queue_param_t Struct Reference

Packet input queue parameters. More...

#include <packet_io_types.h>

Collaboration diagram for odp_pktin_queue_param_t:
[legend]

Data Fields

odp_pktio_op_mode_t op_mode
 Operation mode. More...
 
odp_bool_t classifier_enable
 Enable classifier. More...
 
odp_bool_t hash_enable
 Enable flow hashing. More...
 
odp_pktin_hash_proto_t hash_proto
 Protocol field selection for hashing. More...
 
uint32_t num_queues
 Number of input queues to be created. More...
 
uint32_t queue_size [ODP_PKTIN_MAX_QUEUES]
 Input queue size array. More...
 
odp_queue_param_t queue_param
 Queue parameters. More...
 
odp_pktin_queue_param_ovr_tqueue_param_ovr
 Queue parameters override. More...
 
odp_pktin_vector_config_t vector
 Packet input vector configuration.
 

Detailed Description

Field Documentation

◆ op_mode

odp_pktio_op_mode_t odp_pktin_queue_param_t::op_mode

Operation mode.

The default value is ODP_PKTIO_OP_MT. Application may enable performance optimization by defining ODP_PKTIO_OP_MT_UNSAFE when applicable.

Examples
odp_ipsecfwd.c, odp_l2fwd.c, odp_l2fwd_simple.c, odp_l3fwd.c, odp_packet_gen.c, odp_pktio_ordered.c, odp_simple_pipeline.c, and odp_switch.c.

Definition at line 235 of file api/spec/packet_io_types.h.

◆ classifier_enable

odp_bool_t odp_pktin_queue_param_t::classifier_enable

Enable classifier.

  • 0: Classifier is disabled (default)
  • 1: Classifier is enabled. Use classifier to direct incoming packets into pktin event queues. Classifier can be enabled only in ODP_PKTIN_MODE_SCHED and ODP_PKTIN_MODE_QUEUE modes. Both classifier and hashing cannot be enabled simultaneously ('hash_enable' must be 0).
Examples
odp_bench_pktio_sp.c, and odp_classifier.c.

Definition at line 245 of file api/spec/packet_io_types.h.

◆ hash_enable

odp_bool_t odp_pktin_queue_param_t::hash_enable

Enable flow hashing.

  • 0: Do not hash flows (default)
  • 1: Enable flow hashing. Use flow hashing to spread incoming packets into input queues. Hashing can be enabled in all modes. Both classifier and hashing cannot be enabled simultaneously ('classifier_enable' must be 0).
Examples
odp_bench_pktio_sp.c, odp_dmafwd.c, odp_ipsecfwd.c, odp_l2fwd.c, odp_l3fwd.c, odp_packet_gen.c, odp_pktio_ordered.c, odp_sched_pktio.c, and odp_switch.c.

Definition at line 254 of file api/spec/packet_io_types.h.

◆ hash_proto

odp_pktin_hash_proto_t odp_pktin_queue_param_t::hash_proto

Protocol field selection for hashing.

Multiple protocols can be selected. Ignored when 'hash_enable' is zero. The default value is all bits zero.

Examples
odp_bench_pktio_sp.c, odp_dmafwd.c, odp_ipsecfwd.c, odp_l2fwd.c, odp_l3fwd.c, odp_packet_gen.c, odp_pktio_ordered.c, odp_sched_pktio.c, and odp_switch.c.

Definition at line 260 of file api/spec/packet_io_types.h.

◆ num_queues

uint32_t odp_pktin_queue_param_t::num_queues

Number of input queues to be created.

When classifier is enabled in odp_pktin_queue_config() this value is ignored, otherwise at least one queue is required. More than one input queues require flow hashing configured. The maximum value is defined by pktio capability 'max_input_queues'. Queue type is defined by the input mode. The default value is 1.

Examples
odp_bench_pktio_sp.c, odp_dmafwd.c, odp_ipsecfwd.c, odp_l2fwd.c, odp_l3fwd.c, odp_packet_dump.c, odp_packet_gen.c, odp_ping.c, odp_pktio_ordered.c, odp_sched_pktio.c, and odp_switch.c.

Definition at line 269 of file api/spec/packet_io_types.h.

◆ queue_size

uint32_t odp_pktin_queue_param_t::queue_size[ODP_PKTIN_MAX_QUEUES]

Input queue size array.

An array containing queue sizes for each 'num_queues' input queues in ODP_PKTIN_MODE_DIRECT mode. The value of zero means implementation specific default size. Nonzero values must be between 'min_input_queue_size' and 'max_input_queue_size' capabilities. The implementation may round-up given values. The default value is zero.

Definition at line 279 of file api/spec/packet_io_types.h.

◆ queue_param

odp_queue_param_t odp_pktin_queue_param_t::queue_param

Queue parameters.

These are used for input queue creation in ODP_PKTIN_MODE_QUEUE or ODP_PKTIN_MODE_SCHED modes. Scheduler parameters are considered only in ODP_PKTIN_MODE_SCHED mode. Default values are defined in odp_queue_param_t documentation. The type field is ignored and the queue type is deduced from the pktio input mode. When classifier is enabled in odp_pktin_queue_config() this value is ignored.

Examples
ipsec_api/odp_ipsec.c, ipsec_crypto/odp_ipsec.c, odp_dmafwd.c, odp_ipsecfwd.c, odp_l2fwd.c, odp_packet_dump.c, odp_packet_gen.c, odp_ping.c, odp_pktio.c, odp_pktio_ordered.c, and odp_sched_pktio.c.

Definition at line 290 of file api/spec/packet_io_types.h.

◆ queue_param_ovr

odp_pktin_queue_param_ovr_t* odp_pktin_queue_param_t::queue_param_ovr

Queue parameters override.

When the override array is defined, the same parameter value in 'queue_param' is ignored and these per queue parameter values are used instead. Array elements are used in order (i.e. the first queue gets parameters from the first array element, etc). Must point to an array of num_queues elements or NULL to disable queue parameters override. The default value is NULL.

Definition at line 303 of file api/spec/packet_io_types.h.


The documentation for this struct was generated from the following file: