.TH "rte_event_timer_adapter.h" 3 "Version 25.11.0" "DPDK" \" -*- nroff -*-
.ad l
.nh
.SH NAME
rte_event_timer_adapter.h
.SH SYNOPSIS
.br
.PP
\fR#include 'rte_eventdev\&.h'\fP
.br
\fR#include 'rte_eventdev_trace_fp\&.h'\fP
.br

.SS "Data Structures"

.in +1c
.ti -1c
.RI "struct \fBrte_event_timer_adapter_conf\fP"
.br
.ti -1c
.RI "struct \fBrte_event_timer_adapter_stats\fP"
.br
.ti -1c
.RI "struct \fBrte_event_timer_adapter_info\fP"
.br
.ti -1c
.RI "struct \fBrte_event_timer\fP"
.br
.in -1c
.SS "Macros"

.in +1c
.ti -1c
.RI "#define \fBRTE_EVENT_TIMER_ADAPTER_F_ADJUST_RES\fP   (1ULL << 0)"
.br
.ti -1c
.RI "#define \fBRTE_EVENT_TIMER_ADAPTER_F_SP_PUT\fP   (1ULL << 1)"
.br
.ti -1c
.RI "#define \fBRTE_EVENT_TIMER_ADAPTER_F_PERIODIC\fP   (1ULL << 2)"
.br
.in -1c
.SS "Typedefs"

.in +1c
.ti -1c
.RI "\fBtypedef\fP int(* \fBrte_event_timer_adapter_port_conf_cb_t\fP) (uint16_t id, uint8_t event_dev_id, uint8_t *event_port_id, void *conf_arg)"
.br
.in -1c
.SS "Enumerations"

.in +1c
.ti -1c
.RI "enum \fBrte_event_timer_adapter_clk_src\fP { \fBRTE_EVENT_TIMER_ADAPTER_CPU_CLK\fP, \fBRTE_EVENT_TIMER_ADAPTER_EXT_CLK0\fP, \fBRTE_EVENT_TIMER_ADAPTER_EXT_CLK1\fP, \fBRTE_EVENT_TIMER_ADAPTER_EXT_CLK2\fP, \fBRTE_EVENT_TIMER_ADAPTER_EXT_CLK3\fP }"
.br
.ti -1c
.RI "enum \fBrte_event_timer_state\fP { \fBRTE_EVENT_TIMER_NOT_ARMED\fP = 0, \fBRTE_EVENT_TIMER_ARMED\fP = 1, \fBRTE_EVENT_TIMER_CANCELED\fP = 2, \fBRTE_EVENT_TIMER_ERROR\fP = -1, \fBRTE_EVENT_TIMER_ERROR_TOOEARLY\fP = -2, \fBRTE_EVENT_TIMER_ERROR_TOOLATE\fP = -3 }"
.br
.in -1c
.SS "Functions"

.in +1c
.ti -1c
.RI "struct rte_event_timer_adapter * \fBrte_event_timer_adapter_create\fP (const struct \fBrte_event_timer_adapter_conf\fP *conf)"
.br
.ti -1c
.RI "struct rte_event_timer_adapter * \fBrte_event_timer_adapter_create_ext\fP (const struct \fBrte_event_timer_adapter_conf\fP *conf, \fBrte_event_timer_adapter_port_conf_cb_t\fP conf_cb, void *conf_arg)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_get_info\fP (const struct rte_event_timer_adapter *adapter, struct \fBrte_event_timer_adapter_info\fP *adapter_info)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_start\fP (const struct rte_event_timer_adapter *adapter)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_stop\fP (const struct rte_event_timer_adapter *adapter)"
.br
.ti -1c
.RI "struct rte_event_timer_adapter * \fBrte_event_timer_adapter_lookup\fP (uint16_t adapter_id)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_free\fP (struct rte_event_timer_adapter *adapter)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_service_id_get\fP (struct rte_event_timer_adapter *adapter, uint32_t *service_id)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_stats_get\fP (struct rte_event_timer_adapter *adapter, struct \fBrte_event_timer_adapter_stats\fP *stats)"
.br
.ti -1c
.RI "int \fBrte_event_timer_adapter_stats_reset\fP (struct rte_event_timer_adapter *adapter)"
.br
.ti -1c
.RI "static uint16_t \fBrte_event_timer_arm_burst\fP (const struct rte_event_timer_adapter *adapter, struct \fBrte_event_timer\fP **evtims, uint16_t nb_evtims)"
.br
.ti -1c
.RI "static uint16_t \fBrte_event_timer_arm_tmo_tick_burst\fP (const struct rte_event_timer_adapter *adapter, struct \fBrte_event_timer\fP **evtims, const uint64_t timeout_ticks, const uint16_t nb_evtims)"
.br
.ti -1c
.RI "static uint16_t \fBrte_event_timer_cancel_burst\fP (const struct rte_event_timer_adapter *adapter, struct \fBrte_event_timer\fP **evtims, uint16_t nb_evtims)"
.br
.ti -1c
.RI "__rte_experimental int \fBrte_event_timer_remaining_ticks_get\fP (const struct rte_event_timer_adapter *adapter, const struct \fBrte_event_timer\fP *evtim, uint64_t *ticks_remaining)"
.br
.in -1c
.SH "Detailed Description"
.PP 
RTE Event Timer Adapter

.PP
An event timer adapter has the following abstract working model: 
.PP
.nf
                          timer_tick_ns
                              +
                 +-------+    |
                 |       |    |
         +-------+ bkt 0 +----v---+
         |       |       |        |
         |       +-------+        |
     +---+---+                +---+---+  +---+---+---+---+
     |       |                |       |  |   |   |   |   |
     | bkt n |                | bkt 1 |<-> t0| t1| t2| tn|
     |       |                |       |  |   |   |   |   |
     +---+---+                +---+---+  +---+---+---+---+
         |     Timer adapter      |
     +---+---+                +---+---+
     |       |                |       |
     | bkt 4 |                | bkt 2 |<--- Current bucket
     |       |                |       |
     +---+---+                +---+---+
          |      +-------+       |
          |      |       |       |
          +------+ bkt 3 +-------+
                 |       |
                 +-------+

.fi
.PP

.PP
.IP "\(bu" 2
It has a virtual monotonically increasing 64-bit timer adapter clock based on \fIenum \fBrte_event_timer_adapter_clk_src\fP\fP clock source\&. The clock source could be a CPU clock, or a platform dependent external clock\&.
.IP "\(bu" 2
The application creates a timer adapter instance with given the clock source, the total number of event timers, and a resolution(expressed in ns) to traverse between the buckets\&.
.IP "\(bu" 2
Each timer adapter may have 0 to n buckets based on the configured max timeout(max_tmo_ns) and resolution(timer_tick_ns)\&. Upon starting the timer adapter, the adapter starts ticking at \fItimer_tick_ns\fP resolution\&.
.IP "\(bu" 2
The application arms an event timer that will expire \fItimer_tick_ns\fP from now\&.
.IP "\(bu" 2
The application can cancel an armed timer and no timer expiry event will be generated\&.
.IP "\(bu" 2
If a timer expires then the library injects the timer expiry event in the designated event queue\&.
.IP "\(bu" 2
The timer expiry event will be received through \fIrte_event_dequeue_burst\fP\&.
.IP "\(bu" 2
The application frees the timer adapter instance\&.
.PP

.PP
Multiple timer adapters can be created with a varying level of resolution for various expiry use cases that run in parallel\&.

.PP
Before using the timer adapter, the application has to create and configure an event device along with the event port\&. Based on the event device capability it might require creating an additional event port to be used by the timer adapter\&.

.PP
The application creates the event timer adapter using the \fR\fBrte_event_timer_adapter_create()\fP\fP\&. The event device id is passed to this function, inside this function the event device capability is checked, and if an in-built port is absent the application uses the default function to create a new producer port\&.

.PP
The application may also use the function \fR\fBrte_event_timer_adapter_create_ext()\fP\fP to have granular control over producer port creation in a case where the in-built port is absent\&.

.PP
After creating the timer adapter, the application has to start it using \fR\fBrte_event_timer_adapter_start()\fP\fP\&. The buckets are traversed from 0 to n; when the adapter ticks, the next bucket is visited\&. Each time, the list per bucket is processed, and timer expiry events are sent to the designated event queue\&.

.PP
The application can arm one or more event timers using the \fR\fBrte_event_timer_arm_burst()\fP\fP\&. The \fItimeout_ticks\fP represents the number of \fItimer_tick_ns\fP after which the timer has to expire\&. The timeout at which the timers expire can be grouped or be independent of each event timer instance\&. \fR\fBrte_event_timer_arm_tmo_tick_burst()\fP\fP addresses the former case and \fR\fBrte_event_timer_arm_burst()\fP\fP addresses the latter case\&.

.PP
The application can cancel the timers from expiring using the \fR\fBrte_event_timer_cancel_burst()\fP\fP\&.

.PP
On the secondary process, \fR\fBrte_event_timer_adapter_lookup()\fP\fP can be used to get the timer adapter pointer from its id and use it to invoke fastpath operations such as arm and cancel\&.

.PP
Some of the use cases of event timer adapter are Beacon Timers, Generic SW Timeout, Wireless MAC Scheduling, 3G Frame Protocols, Packet Scheduling, Protocol Retransmission Timers, Supervision Timers\&. All these use cases require high resolution and low time drift\&. 
.PP
Definition in file \fBrte_event_timer_adapter\&.h\fP\&.
.SH "Macro Definition Documentation"
.PP 
.SS "#define RTE_EVENT_TIMER_ADAPTER_F_ADJUST_RES   (1ULL << 0)"
The event timer adapter implementation may have constraints on the resolution (timer_tick_ns) and maximum timer expiry timeout(max_tmo_ns) based on the given timer adapter or system\&. If this flag is set, the implementation adjusts the resolution and maximum timeout to the best possible configuration\&. On successful timer adapter creation, the application can get the configured resolution and max timeout with \fR\fBrte_event_timer_adapter_get_info()\fP\fP\&.

.PP
\fBSee also\fP
.RS 4
struct \fBrte_event_timer_adapter_info::min_resolution_ns\fP 

.PP
struct \fBrte_event_timer_adapter_info::max_tmo_ns\fP 
.RE
.PP

.PP
Definition at line \fB134\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SS "#define RTE_EVENT_TIMER_ADAPTER_F_SP_PUT   (1ULL << 1)"
\fR\fBrte_event_timer_arm_burst()\fP\fP API to be used in single producer mode\&.

.PP
\fBSee also\fP
.RS 4
struct \fBrte_event_timer_adapter_conf::flags\fP 
.RE
.PP

.PP
Definition at line \fB146\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SS "#define RTE_EVENT_TIMER_ADAPTER_F_PERIODIC   (1ULL << 2)"
Flag to configure an event timer adapter in periodic mode; non-periodic mode is the default\&. A timer will fire once or periodically until the timer is cancelled based on the adapter mode\&.

.PP
\fBSee also\fP
.RS 4
struct \fBrte_event_timer_adapter_conf::flags\fP 
.RE
.PP

.PP
Definition at line \fB152\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SH "Typedef Documentation"
.PP 
.SS "\fBtypedef\fP int(* rte_event_timer_adapter_port_conf_cb_t) (uint16_t id, uint8_t event_dev_id, uint8_t *event_port_id, void *conf_arg)"
Callback function type for producer port creation\&. 
.PP
Definition at line \fB205\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SH "Enumeration Type Documentation"
.PP 
.SS "enum \fBrte_event_timer_adapter_clk_src\fP"
Timer adapter clock source 
.PP
\fBEnumerator\fP
.in +1c
.TP
\f(BIRTE_EVENT_TIMER_ADAPTER_CPU_CLK \fP
Use CPU clock as the clock source\&. 
.TP
\f(BIRTE_EVENT_TIMER_ADAPTER_EXT_CLK0 \fP
Platform dependent external clock source 0\&. 
.TP
\f(BIRTE_EVENT_TIMER_ADAPTER_EXT_CLK1 \fP
Platform dependent external clock source 1\&. 
.TP
\f(BIRTE_EVENT_TIMER_ADAPTER_EXT_CLK2 \fP
Platform dependent external clock source 2\&. 
.TP
\f(BIRTE_EVENT_TIMER_ADAPTER_EXT_CLK3 \fP
Platform dependent external clock source 3\&. 
.PP
Definition at line \fB121\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SS "enum \fBrte_event_timer_state\fP"
Event timer state\&. 
.PP
\fBEnumerator\fP
.in +1c
.TP
\f(BIRTE_EVENT_TIMER_NOT_ARMED \fP
Event timer not armed\&. 
.TP
\f(BIRTE_EVENT_TIMER_ARMED \fP
Event timer successfully armed\&. 
.TP
\f(BIRTE_EVENT_TIMER_CANCELED \fP
Event timer successfully canceled\&. 
.TP
\f(BIRTE_EVENT_TIMER_ERROR \fP
Generic event timer error\&. 
.TP
\f(BIRTE_EVENT_TIMER_ERROR_TOOEARLY \fP
Event timer timeout tick value is too small for the adapter to handle, given its configured resolution\&. 
.TP
\f(BIRTE_EVENT_TIMER_ERROR_TOOLATE \fP
Event timer timeout tick is greater than the maximum timeout\&. 
.PP
Definition at line \fB455\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SH "Function Documentation"
.PP 
.SS "struct rte_event_timer_adapter * rte_event_timer_adapter_create (const struct \fBrte_event_timer_adapter_conf\fP * conf)"
Create an event timer adapter\&.

.PP
This function must be invoked first before any other function in the API\&.

.PP
When this API is used for creating adapter instance, \fR\fBrte_event_dev_config::nb_event_ports\fP\fP is automatically incremented, and the event device is reconfigured with additional event port during service initialization\&. This event device reconfigure logic also increments the \fR\fBrte_event_dev_config::nb_single_link_event_port_queues\fP\fP parameter if the adapter event port config is of type \fR\fBRTE_EVENT_PORT_CFG_SINGLE_LINK\fP\fP\&.

.PP
Application no longer needs to account for \fR\fBrte_event_dev_config::nb_event_ports\fP\fP and \fR\fBrte_event_dev_config::nb_single_link_event_port_queues\fP\fP parameters required for Timer adapter in event device configuration when the adapter is created with this API\&.

.PP
\fBParameters\fP
.RS 4
\fIconf\fP The event timer adapter configuration structure\&.
.RE
.PP
\fBReturns\fP
.RS 4
A pointer to the new allocated event timer adapter on success\&. NULL on error with rte_errno set appropriately\&. Possible rte_errno values include:
.IP "\(bu" 2
ERANGE: timer_tick_ns is not in supported range\&.
.IP "\(bu" 2
ENOMEM: unable to allocate sufficient memory for adapter instances
.IP "\(bu" 2
EINVAL: invalid event device identifier specified in config
.IP "\(bu" 2
ENOSPC: maximum number of adapters already created
.IP "\(bu" 2
EIO: event device reconfiguration and restart error\&. The adapter reconfigures the event device with an additional port by default if it is required to use a service to manage timers\&. If the device had been started before this call, this error code indicates an error in restart following an error in reconfiguration, i\&.e\&., a combination of the two error codes\&. 
.PP
.RE
.PP

.SS "struct rte_event_timer_adapter * rte_event_timer_adapter_create_ext (const struct \fBrte_event_timer_adapter_conf\fP * conf, \fBrte_event_timer_adapter_port_conf_cb_t\fP conf_cb, void * conf_arg)"
Create a timer adapter with the supplied callback\&.

.PP
This function can be used to have a more granular control over the timer adapter creation\&. If a built-in port is absent, then the function uses the callback provided to create and get the port id to be used as a producer port\&.

.PP
\fBParameters\fP
.RS 4
\fIconf\fP The timer adapter configuration structure 
.br
\fIconf_cb\fP The port config callback function\&. 
.br
\fIconf_arg\fP Opaque pointer to the argument for the callback function
.RE
.PP
\fBReturns\fP
.RS 4
A pointer to the new allocated event timer adapter on success\&. NULL on error with rte_errno set appropriately\&. Possible rte_errno values include:
.IP "\(bu" 2
ERANGE: timer_tick_ns is not in supported range\&.
.IP "\(bu" 2
ENOMEM: unable to allocate sufficient memory for adapter instances
.IP "\(bu" 2
EINVAL: invalid event device identifier specified in config
.IP "\(bu" 2
ENOSPC: maximum number of adapters already created 
.PP
.RE
.PP

.SS "int rte_event_timer_adapter_get_info (const struct rte_event_timer_adapter * adapter, struct \fBrte_event_timer_adapter_info\fP * adapter_info)"
Retrieve the contextual information of an event timer adapter\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to the event timer adapter structure\&.
.br
\fIadapter_info\fP A pointer to a structure of type \fI\fBrte_event_timer_adapter_info\fP\fP to be filled with the contextual information of the adapter\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Success, driver updates the contextual information of the timer adapter
.IP "\(bu" 2
<0: Error code returned by the driver info get function\&.
.IP "\(bu" 2
-EINVAL: adapter identifier invalid
.PP
.RE
.PP
\fBSee also\fP
.RS 4
\fBRTE_EVENT_TIMER_ADAPTER_F_ADJUST_RES\fP, struct \fBrte_event_timer_adapter_info\fP 
.RE
.PP

.SS "int rte_event_timer_adapter_start (const struct rte_event_timer_adapter * adapter)"
Start a timer adapter\&.

.PP
The adapter start step is the last one and consists of setting the timer adapter to start accepting the timers and schedules to event queues\&.

.PP
On success, all basic functions exported by the API (timer arm, timer cancel and so on) can be invoked\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to the event timer adapter structure\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Success, adapter started\&.
.IP "\(bu" 2
<0: Error code returned by the driver start function\&.
.IP "\(bu" 2
-EINVAL if adapter identifier invalid
.IP "\(bu" 2
-ENOENT if software adapter but no service core mapped
.IP "\(bu" 2
-ENOTSUP if software adapter and more than one service core mapped
.IP "\(bu" 2
-EALREADY if adapter has already been started
.PP
.RE
.PP
\fBNote\fP
.RS 4
The eventdev to which the event_timer_adapter is connected needs to be started before calling \fBrte_event_timer_adapter_start()\fP\&. 
.RE
.PP

.SS "int rte_event_timer_adapter_stop (const struct rte_event_timer_adapter * adapter)"
Stop an event timer adapter\&.

.PP
The adapter can be restarted with a call to \fR\fBrte_event_timer_adapter_start()\fP\fP\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to the event timer adapter structure\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Success, adapter stopped\&.
.IP "\(bu" 2
<0: Error code returned by the driver stop function\&.
.IP "\(bu" 2
-EINVAL if adapter identifier invalid 
.PP
.RE
.PP

.SS "struct rte_event_timer_adapter * rte_event_timer_adapter_lookup (uint16_t adapter_id)"
Lookup an event timer adapter using its identifier\&.

.PP
If an event timer adapter was created in another process with the same identifier, this function will locate its state and set up access to it so that it can be used in this process\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter_id\fP The event timer adapter identifier\&.
.RE
.PP
\fBReturns\fP
.RS 4
A pointer to the event timer adapter matching the identifier on success\&. NULL on error with rte_errno set appropriately\&. Possible rte_errno values include:
.IP "\(bu" 2
ENOENT - requested entry not available to return\&. 
.PP
.RE
.PP

.SS "int rte_event_timer_adapter_free (struct rte_event_timer_adapter * adapter)"
Free an event timer adapter\&.

.PP
Destroy an event timer adapter, freeing all resources\&.

.PP
Before invoking this function, the application must wait for all the armed timers to expire or cancel the outstanding armed timers\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Successfully freed the event timer adapter resources\&.
.IP "\(bu" 2
<0: Failed to free the event timer adapter resources\&.
.IP "\(bu" 2
-EAGAIN: adapter is busy; timers outstanding
.IP "\(bu" 2
-EBUSY: stop hasn't been called for this adapter yet
.IP "\(bu" 2
-EINVAL: adapter id invalid, or adapter invalid 
.PP
.RE
.PP

.SS "int rte_event_timer_adapter_service_id_get (struct rte_event_timer_adapter * adapter, uint32_t * service_id)"
Retrieve the service ID of the event timer adapter\&. If the adapter doesn't use an rte_service function, this function returns -ESRCH\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter\&.
.br
\fIservice_id\fP A pointer to a uint32_t, to be filled in with the service id\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Success
.IP "\(bu" 2
<0: Error code on failure
.IP "\(bu" 2
-ESRCH: the adapter does not require a service to operate 
.PP
.RE
.PP

.SS "int rte_event_timer_adapter_stats_get (struct rte_event_timer_adapter * adapter, struct \fBrte_event_timer_adapter_stats\fP * stats)"
Retrieve statistics for an event timer adapter instance\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure\&. 
.br
\fIstats\fP A pointer to a structure to fill with statistics\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Successfully retrieved\&.
.IP "\(bu" 2
<0: Failure; error code returned\&. 
.PP
.RE
.PP

.SS "int rte_event_timer_adapter_stats_reset (struct rte_event_timer_adapter * adapter)"
Reset statistics for an event timer adapter instance\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure\&.
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Successfully reset;
.IP "\(bu" 2
<0: Failure; error code returned\&. 
.PP
.RE
.PP

.SS "uint16_t rte_event_timer_arm_burst (const struct rte_event_timer_adapter * adapter, struct \fBrte_event_timer\fP ** evtims, uint16_t nb_evtims)\fR [inline]\fP, \fR [static]\fP"
Arm a burst of event timers with separate expiration timeout tick for each event timer\&.

.PP
Before calling this function, the application allocates \fRstruct \fBrte_event_timer\fP\fP objects from mempool or huge page backed application buffers of desired size\&. On successful allocation, application updates the \fRstruct \fBrte_event_timer\fP\fP attributes such as expiry event attributes, timeout ticks from now\&. This function submits the event timer arm requests to the event timer adapter and on expiry, the events will be injected to designated event queue\&. Timer expiry events will be generated once or periodically until cancellation based on the adapter mode\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure\&. 
.br
\fIevtims\fP Pointer to an array of objects of type \fI\fBrte_event_timer\fP\fP structure\&. 
.br
\fInb_evtims\fP Number of event timers in the supplied array\&.
.RE
.PP
\fBReturns\fP
.RS 4
The number of successfully armed event timers\&. The return value can be less than the value of the \fInb_evtims\fP parameter\&. If the return value is less than \fInb_evtims\fP, the remaining event timers at the end of \fIevtims\fP are not consumed, and the caller has to take care of them, and rte_errno is set accordingly\&. Possible errno values include:
.IP "\(bu" 2
EINVAL Invalid timer adapter, expiry event queue ID is invalid, or an expiry event's sched type doesn't match the capabilities of the destination event queue\&.
.IP "\(bu" 2
EAGAIN Specified timer adapter is not running
.IP "\(bu" 2
EALREADY A timer was encountered that was already armed
.PP
.RE
.PP
\fBSee also\fP
.RS 4
\fBRTE_EVENT_TIMER_ADAPTER_F_PERIODIC\fP 
.RE
.PP

.PP
Definition at line \fB598\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SS "uint16_t rte_event_timer_arm_tmo_tick_burst (const struct rte_event_timer_adapter * adapter, struct \fBrte_event_timer\fP ** evtims, const uint64_t timeout_ticks, const uint16_t nb_evtims)\fR [inline]\fP, \fR [static]\fP"
Arm a burst of event timers with same expiration timeout tick\&.

.PP
Provides the same functionality as \fR\fBrte_event_timer_arm_burst()\fP\fP, except that application can use this API when all the event timers have the same timeout expiration tick\&. This specialized function can provide the additional hint to the adapter implementation and optimize if possible\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure\&. 
.br
\fIevtims\fP Points to an array of objects of type \fI\fBrte_event_timer\fP\fP structure\&. 
.br
\fItimeout_ticks\fP The number of ticks in which the timers should expire\&. 
.br
\fInb_evtims\fP Number of event timers in the supplied array\&.
.RE
.PP
\fBReturns\fP
.RS 4
The number of successfully armed event timers\&. The return value can be less than the value of the \fInb_evtims\fP parameter\&. If the return value is less than \fInb_evtims\fP, the remaining event timers at the end of \fIevtims\fP are not consumed, and the caller has to take care of them, and rte_errno is set accordingly\&. Possible errno values include:
.IP "\(bu" 2
EINVAL Invalid timer adapter, expiry event queue ID is invalid, or an expiry event's sched type doesn't match the capabilities of the destination event queue\&.
.IP "\(bu" 2
EAGAIN Specified event timer adapter is not running
.IP "\(bu" 2
EALREADY A timer was encountered that was already armed 
.PP
.RE
.PP

.PP
Definition at line \fB641\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SS "uint16_t rte_event_timer_cancel_burst (const struct rte_event_timer_adapter * adapter, struct \fBrte_event_timer\fP ** evtims, uint16_t nb_evtims)\fR [inline]\fP, \fR [static]\fP"
Cancel a burst of event timers from being scheduled to the event device\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure\&. 
.br
\fIevtims\fP Points to an array of objects of type \fI\fBrte_event_timer\fP\fP structure 
.br
\fInb_evtims\fP Number of event timer instances in the supplied array\&.
.RE
.PP
\fBReturns\fP
.RS 4
The number of successfully canceled event timers\&. The return value can be less than the value of the \fInb_evtims\fP parameter\&. If the return value is less than \fInb_evtims\fP, the remaining event timers at the end of \fIevtims\fP are not consumed, and the caller has to take care of them, and rte_errno is set accordingly\&. Possible errno values include:
.IP "\(bu" 2
EINVAL Invalid timer adapter identifier
.IP "\(bu" 2
EAGAIN Specified timer adapter is not running
.IP "\(bu" 2
EALREADY A timer was encountered that was already canceled 
.PP
.RE
.PP

.PP
Definition at line \fB678\fP of file \fBrte_event_timer_adapter\&.h\fP\&.
.SS "__rte_experimental int rte_event_timer_remaining_ticks_get (const struct rte_event_timer_adapter * adapter, const struct \fBrte_event_timer\fP * evtim, uint64_t * ticks_remaining)"
Get the number of ticks remaining until event timer expiry\&.

.PP
\fBParameters\fP
.RS 4
\fIadapter\fP A pointer to an event timer adapter structure 
.br
\fIevtim\fP A pointer to an \fBrte_event_timer\fP structure 
.br
\fIticks_remaining\fP Pointer to variable into which to write the number of ticks remaining until event timer expiry
.RE
.PP
\fBReturns\fP
.RS 4
.IP "\(bu" 2
0: Success
.IP "\(bu" 2
-EINVAL Invalid timer adapter identifier or the event timer is not in the armed state or ticks_remaining is NULL
.IP "\(bu" 2
-ENOTSUP The timer adapter implementation does not support this API\&. 
.PP
.RE
.PP

.SH "Author"
.PP 
Generated automatically by Doxygen for DPDK from the source code\&.
