DPDK  22.11.0-rc0
rte_eventdev.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: BSD-3-Clause
2  * Copyright(c) 2016 Cavium, Inc.
3  * Copyright(c) 2016-2018 Intel Corporation.
4  * Copyright 2016 NXP
5  * All rights reserved.
6  */
7 
8 #ifndef _RTE_EVENTDEV_H_
9 #define _RTE_EVENTDEV_H_
10 
209 #ifdef __cplusplus
210 extern "C" {
211 #endif
212 
213 #include <rte_common.h>
214 #include <rte_errno.h>
215 #include <rte_mbuf_pool_ops.h>
216 #include <rte_mempool.h>
217 
218 #include "rte_eventdev_trace_fp.h"
219 
220 struct rte_mbuf; /* we just use mbuf pointers; no need to include rte_mbuf.h */
221 struct rte_event;
222 
223 /* Event device capability bitmap flags */
224 #define RTE_EVENT_DEV_CAP_QUEUE_QOS (1ULL << 0)
225 
236 #define RTE_EVENT_DEV_CAP_EVENT_QOS (1ULL << 1)
237 
243 #define RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED (1ULL << 2)
244 
252 #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3)
253 
259 #define RTE_EVENT_DEV_CAP_BURST_MODE (1ULL << 4)
260 
267 #define RTE_EVENT_DEV_CAP_IMPLICIT_RELEASE_DISABLE (1ULL << 5)
268 
278 #define RTE_EVENT_DEV_CAP_NONSEQ_MODE (1ULL << 6)
279 
288 #define RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK (1ULL << 7)
289 
294 #define RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT (1ULL << 8)
295 
300 #define RTE_EVENT_DEV_CAP_CARRY_FLOW_ID (1ULL << 9)
301 
306 #define RTE_EVENT_DEV_CAP_MAINTENANCE_FREE (1ULL << 10)
307 
316 #define RTE_EVENT_DEV_CAP_RUNTIME_QUEUE_ATTR (1ULL << 11)
317 
323 /* Event device priority levels */
324 #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0
325 
329 #define RTE_EVENT_DEV_PRIORITY_NORMAL 128
330 
334 #define RTE_EVENT_DEV_PRIORITY_LOWEST 255
335 
340 /* Event queue scheduling weights */
341 #define RTE_EVENT_QUEUE_WEIGHT_HIGHEST 255
342 
345 #define RTE_EVENT_QUEUE_WEIGHT_LOWEST 0
346 
350 /* Event queue scheduling affinity */
351 #define RTE_EVENT_QUEUE_AFFINITY_HIGHEST 255
352 
355 #define RTE_EVENT_QUEUE_AFFINITY_LOWEST 0
356 
367 uint8_t
368 rte_event_dev_count(void);
369 
380 int
381 rte_event_dev_get_dev_id(const char *name);
382 
393 int
394 rte_event_dev_socket_id(uint8_t dev_id);
395 
400  const char *driver_name;
401  struct rte_device *dev;
436  int32_t max_num_events;
441  uint32_t event_dev_cap;
449 };
450 
466 int
467 rte_event_dev_info_get(uint8_t dev_id, struct rte_event_dev_info *dev_info);
468 
472 #define RTE_EVENT_DEV_ATTR_PORT_COUNT 0
473 
476 #define RTE_EVENT_DEV_ATTR_QUEUE_COUNT 1
477 
480 #define RTE_EVENT_DEV_ATTR_STARTED 2
481 
494 int
495 rte_event_dev_attr_get(uint8_t dev_id, uint32_t attr_id,
496  uint32_t *attr_value);
497 
498 
499 /* Event device configuration bitmap flags */
500 #define RTE_EVENT_DEV_CFG_PER_DEQUEUE_TIMEOUT (1ULL << 0)
501 
528  uint8_t nb_event_ports;
554  uint32_t event_dev_cfg;
564 };
565 
585 int
586 rte_event_dev_configure(uint8_t dev_id,
587  const struct rte_event_dev_config *dev_conf);
588 
589 /* Event queue specific APIs */
590 
591 /* Event queue configuration bitmap flags */
592 #define RTE_EVENT_QUEUE_CFG_ALL_TYPES (1ULL << 0)
593 
598 #define RTE_EVENT_QUEUE_CFG_SINGLE_LINK (1ULL << 1)
599 
606  uint32_t nb_atomic_flows;
628  uint32_t event_queue_cfg;
630  uint8_t schedule_type;
635  uint8_t priority;
643  uint8_t weight;
651  uint8_t affinity;
659 };
660 
683 int
684 rte_event_queue_default_conf_get(uint8_t dev_id, uint8_t queue_id,
685  struct rte_event_queue_conf *queue_conf);
686 
705 int
706 rte_event_queue_setup(uint8_t dev_id, uint8_t queue_id,
707  const struct rte_event_queue_conf *queue_conf);
708 
712 #define RTE_EVENT_QUEUE_ATTR_PRIORITY 0
713 
716 #define RTE_EVENT_QUEUE_ATTR_NB_ATOMIC_FLOWS 1
717 
720 #define RTE_EVENT_QUEUE_ATTR_NB_ATOMIC_ORDER_SEQUENCES 2
721 
724 #define RTE_EVENT_QUEUE_ATTR_EVENT_QUEUE_CFG 3
725 
728 #define RTE_EVENT_QUEUE_ATTR_SCHEDULE_TYPE 4
729 
732 #define RTE_EVENT_QUEUE_ATTR_WEIGHT 5
733 
736 #define RTE_EVENT_QUEUE_ATTR_AFFINITY 6
737 
758 int
759 rte_event_queue_attr_get(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id,
760  uint32_t *attr_value);
761 
780 __rte_experimental
781 int
782 rte_event_queue_attr_set(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id,
783  uint64_t attr_value);
784 
785 /* Event port specific APIs */
786 
787 /* Event port configuration bitmap flags */
788 #define RTE_EVENT_PORT_CFG_DISABLE_IMPL_REL (1ULL << 0)
789 
795 #define RTE_EVENT_PORT_CFG_SINGLE_LINK (1ULL << 1)
796 
800 #define RTE_EVENT_PORT_CFG_HINT_PRODUCER (1ULL << 2)
801 
810 #define RTE_EVENT_PORT_CFG_HINT_CONSUMER (1ULL << 3)
811 
821 #define RTE_EVENT_PORT_CFG_HINT_WORKER (1ULL << 4)
822 
848  uint16_t dequeue_depth;
854  uint16_t enqueue_depth;
860  uint32_t event_port_cfg;
861 };
862 
885 int
886 rte_event_port_default_conf_get(uint8_t dev_id, uint8_t port_id,
887  struct rte_event_port_conf *port_conf);
888 
909 int
910 rte_event_port_setup(uint8_t dev_id, uint8_t port_id,
911  const struct rte_event_port_conf *port_conf);
912 
913 typedef void (*rte_eventdev_port_flush_t)(uint8_t dev_id,
914  struct rte_event event, void *arg);
944 __rte_experimental
945 void
946 rte_event_port_quiesce(uint8_t dev_id, uint8_t port_id,
947  rte_eventdev_port_flush_t release_cb, void *args);
948 
952 #define RTE_EVENT_PORT_ATTR_ENQ_DEPTH 0
953 
956 #define RTE_EVENT_PORT_ATTR_DEQ_DEPTH 1
957 
960 #define RTE_EVENT_PORT_ATTR_NEW_EVENT_THRESHOLD 2
961 
964 #define RTE_EVENT_PORT_ATTR_IMPLICIT_RELEASE_DISABLE 3
965 
982 int
983 rte_event_port_attr_get(uint8_t dev_id, uint8_t port_id, uint32_t attr_id,
984  uint32_t *attr_value);
985 
1002 int
1003 rte_event_dev_start(uint8_t dev_id);
1004 
1023 void
1024 rte_event_dev_stop(uint8_t dev_id);
1025 
1026 typedef void (*rte_eventdev_stop_flush_t)(uint8_t dev_id,
1027  struct rte_event event, void *arg);
1057  rte_eventdev_stop_flush_t callback, void *userdata);
1058 
1070 int
1071 rte_event_dev_close(uint8_t dev_id);
1077  uint16_t nb_elem;
1079  uint16_t elem_offset : 12;
1081  uint16_t rsvd : 3;
1083  uint16_t attr_valid : 1;
1086  union {
1087  /* Used by Rx/Tx adapter.
1088  * Indicates that all the elements in this vector belong to the
1089  * same port and queue pair when originating from Rx adapter,
1090  * valid only when event type is ETHDEV_VECTOR or
1091  * ETH_RX_ADAPTER_VECTOR.
1092  * Can also be used to indicate the Tx adapter the destination
1093  * port and queue of the mbufs in the vector
1094  */
1095  struct {
1096  uint16_t port;
1097  /* Ethernet device port id. */
1098  uint16_t queue;
1099  /* Ethernet device queue id. */
1100  };
1101  };
1103  uint64_t impl_opaque;
1104 
1105 /* empty structures do not have zero size in C++ leading to compilation errors
1106  * with clang about structure having different sizes in C and C++.
1107  * Since these are all zero-sized arrays, we can omit the "union" wrapper for
1108  * C++ builds, removing the warning.
1109  */
1110 #ifndef __cplusplus
1111 
1116  union {
1117 #endif
1118  struct rte_mbuf *mbufs[0];
1119  void *ptrs[0];
1120  uint64_t u64s[0];
1121 #ifndef __cplusplus
1122  } __rte_aligned(16);
1123 #endif
1124 
1128 } __rte_aligned(16);
1129 
1130 /* Scheduler type definitions */
1131 #define RTE_SCHED_TYPE_ORDERED 0
1132 
1158 #define RTE_SCHED_TYPE_ATOMIC 1
1159 
1177 #define RTE_SCHED_TYPE_PARALLEL 2
1178 
1190 /* Event types to classify the event source */
1191 #define RTE_EVENT_TYPE_ETHDEV 0x0
1192 
1193 #define RTE_EVENT_TYPE_CRYPTODEV 0x1
1194 
1195 #define RTE_EVENT_TYPE_TIMER 0x2
1196 
1197 #define RTE_EVENT_TYPE_CPU 0x3
1198 
1201 #define RTE_EVENT_TYPE_ETH_RX_ADAPTER 0x4
1202 
1203 #define RTE_EVENT_TYPE_VECTOR 0x8
1204 
1215 #define RTE_EVENT_TYPE_ETHDEV_VECTOR \
1216  (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_ETHDEV)
1217 
1218 #define RTE_EVENT_TYPE_CPU_VECTOR (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_CPU)
1219 
1220 #define RTE_EVENT_TYPE_ETH_RX_ADAPTER_VECTOR \
1221  (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_ETH_RX_ADAPTER)
1222 
1223 #define RTE_EVENT_TYPE_CRYPTODEV_VECTOR \
1224  (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_CRYPTODEV)
1225 
1227 #define RTE_EVENT_TYPE_MAX 0x10
1228 
1230 /* Event enqueue operations */
1231 #define RTE_EVENT_OP_NEW 0
1232 
1235 #define RTE_EVENT_OP_FORWARD 1
1236 
1243 #define RTE_EVENT_OP_RELEASE 2
1244 
1281 struct rte_event {
1283  union {
1284  uint64_t event;
1286  struct {
1287  uint32_t flow_id:20;
1294  uint32_t sub_event_type:8;
1298  uint32_t event_type:4;
1302  uint8_t op:2;
1308  uint8_t rsvd:4;
1310  uint8_t sched_type:2;
1315  uint8_t queue_id;
1322  uint8_t priority;
1332  uint8_t impl_opaque;
1339  };
1340  };
1342  union {
1343  uint64_t u64;
1345  void *event_ptr;
1347  struct rte_mbuf *mbuf;
1351  };
1352 };
1353 
1354 /* Ethdev Rx adapter capability bitmap flags */
1355 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_INTERNAL_PORT 0x1
1356 
1359 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_MULTI_EVENTQ 0x2
1360 
1363 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_OVERRIDE_FLOW_ID 0x4
1364 
1370 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_EVENT_VECTOR 0x8
1371 
1392 int
1393 rte_event_eth_rx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id,
1394  uint32_t *caps);
1395 
1396 #define RTE_EVENT_TIMER_ADAPTER_CAP_INTERNAL_PORT (1ULL << 0)
1397 
1399 #define RTE_EVENT_TIMER_ADAPTER_CAP_PERIODIC (1ULL << 1)
1400 
1415 int
1416 rte_event_timer_adapter_caps_get(uint8_t dev_id, uint32_t *caps);
1417 
1418 /* Crypto adapter capability bitmap flag */
1419 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_NEW 0x1
1420 
1426 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD 0x2
1427 
1433 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_QP_EV_BIND 0x4
1434 
1438 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_SESSION_PRIVATE_DATA 0x8
1439 
1443 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_EVENT_VECTOR 0x10
1444 
1468 int
1469 rte_event_crypto_adapter_caps_get(uint8_t dev_id, uint8_t cdev_id,
1470  uint32_t *caps);
1471 
1472 /* Ethdev Tx adapter capability bitmap flags */
1473 #define RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT 0x1
1474 
1476 #define RTE_EVENT_ETH_TX_ADAPTER_CAP_EVENT_VECTOR 0x2
1477 
1498 int
1499 rte_event_eth_tx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id,
1500  uint32_t *caps);
1501 
1527 int
1528 rte_event_dequeue_timeout_ticks(uint8_t dev_id, uint64_t ns,
1529  uint64_t *timeout_ticks);
1530 
1591 int
1592 rte_event_port_link(uint8_t dev_id, uint8_t port_id,
1593  const uint8_t queues[], const uint8_t priorities[],
1594  uint16_t nb_links);
1595 
1635 int
1636 rte_event_port_unlink(uint8_t dev_id, uint8_t port_id,
1637  uint8_t queues[], uint16_t nb_unlinks);
1638 
1660 int
1661 rte_event_port_unlinks_in_progress(uint8_t dev_id, uint8_t port_id);
1662 
1690 int
1691 rte_event_port_links_get(uint8_t dev_id, uint8_t port_id,
1692  uint8_t queues[], uint8_t priorities[]);
1693 
1709 int
1710 rte_event_dev_service_id_get(uint8_t dev_id, uint32_t *service_id);
1711 
1725 int
1726 rte_event_dev_dump(uint8_t dev_id, FILE *f);
1727 
1729 #define RTE_EVENT_DEV_XSTATS_NAME_SIZE 64
1730 
1735  RTE_EVENT_DEV_XSTATS_DEVICE,
1736  RTE_EVENT_DEV_XSTATS_PORT,
1737  RTE_EVENT_DEV_XSTATS_QUEUE,
1738 };
1739 
1747  char name[RTE_EVENT_DEV_XSTATS_NAME_SIZE];
1748 };
1749 
1782 int
1783 rte_event_dev_xstats_names_get(uint8_t dev_id,
1784  enum rte_event_dev_xstats_mode mode,
1785  uint8_t queue_port_id,
1786  struct rte_event_dev_xstats_name *xstats_names,
1787  unsigned int *ids,
1788  unsigned int size);
1789 
1816 int
1817 rte_event_dev_xstats_get(uint8_t dev_id,
1818  enum rte_event_dev_xstats_mode mode,
1819  uint8_t queue_port_id,
1820  const unsigned int ids[],
1821  uint64_t values[], unsigned int n);
1822 
1839 uint64_t
1840 rte_event_dev_xstats_by_name_get(uint8_t dev_id, const char *name,
1841  unsigned int *id);
1842 
1863 int
1864 rte_event_dev_xstats_reset(uint8_t dev_id,
1865  enum rte_event_dev_xstats_mode mode,
1866  int16_t queue_port_id,
1867  const uint32_t ids[],
1868  uint32_t nb_ids);
1869 
1880 int rte_event_dev_selftest(uint8_t dev_id);
1881 
1912 struct rte_mempool *
1913 rte_event_vector_pool_create(const char *name, unsigned int n,
1914  unsigned int cache_size, uint16_t nb_elem,
1915  int socket_id);
1916 
1917 #include <rte_eventdev_core.h>
1918 
1919 static __rte_always_inline uint16_t
1920 __rte_event_enqueue_burst(uint8_t dev_id, uint8_t port_id,
1921  const struct rte_event ev[], uint16_t nb_events,
1922  const event_enqueue_burst_t fn)
1923 {
1924  const struct rte_event_fp_ops *fp_ops;
1925  void *port;
1926 
1927  fp_ops = &rte_event_fp_ops[dev_id];
1928  port = fp_ops->data[port_id];
1929 #ifdef RTE_LIBRTE_EVENTDEV_DEBUG
1930  if (dev_id >= RTE_EVENT_MAX_DEVS ||
1931  port_id >= RTE_EVENT_MAX_PORTS_PER_DEV) {
1932  rte_errno = EINVAL;
1933  return 0;
1934  }
1935 
1936  if (port == NULL) {
1937  rte_errno = EINVAL;
1938  return 0;
1939  }
1940 #endif
1941  rte_eventdev_trace_enq_burst(dev_id, port_id, ev, nb_events, (void *)fn);
1942  /*
1943  * Allow zero cost non burst mode routine invocation if application
1944  * requests nb_events as const one
1945  */
1946  if (nb_events == 1)
1947  return (fp_ops->enqueue)(port, ev);
1948  else
1949  return fn(port, ev, nb_events);
1950 }
1951 
1995 static inline uint16_t
1996 rte_event_enqueue_burst(uint8_t dev_id, uint8_t port_id,
1997  const struct rte_event ev[], uint16_t nb_events)
1998 {
1999  const struct rte_event_fp_ops *fp_ops;
2000 
2001  fp_ops = &rte_event_fp_ops[dev_id];
2002  return __rte_event_enqueue_burst(dev_id, port_id, ev, nb_events,
2003  fp_ops->enqueue_burst);
2004 }
2005 
2047 static inline uint16_t
2048 rte_event_enqueue_new_burst(uint8_t dev_id, uint8_t port_id,
2049  const struct rte_event ev[], uint16_t nb_events)
2050 {
2051  const struct rte_event_fp_ops *fp_ops;
2052 
2053  fp_ops = &rte_event_fp_ops[dev_id];
2054  return __rte_event_enqueue_burst(dev_id, port_id, ev, nb_events,
2055  fp_ops->enqueue_new_burst);
2056 }
2057 
2099 static inline uint16_t
2100 rte_event_enqueue_forward_burst(uint8_t dev_id, uint8_t port_id,
2101  const struct rte_event ev[], uint16_t nb_events)
2102 {
2103  const struct rte_event_fp_ops *fp_ops;
2104 
2105  fp_ops = &rte_event_fp_ops[dev_id];
2106  return __rte_event_enqueue_burst(dev_id, port_id, ev, nb_events,
2107  fp_ops->enqueue_forward_burst);
2108 }
2109 
2176 static inline uint16_t
2177 rte_event_dequeue_burst(uint8_t dev_id, uint8_t port_id, struct rte_event ev[],
2178  uint16_t nb_events, uint64_t timeout_ticks)
2179 {
2180  const struct rte_event_fp_ops *fp_ops;
2181  void *port;
2182 
2183  fp_ops = &rte_event_fp_ops[dev_id];
2184  port = fp_ops->data[port_id];
2185 #ifdef RTE_LIBRTE_EVENTDEV_DEBUG
2186  if (dev_id >= RTE_EVENT_MAX_DEVS ||
2187  port_id >= RTE_EVENT_MAX_PORTS_PER_DEV) {
2188  rte_errno = EINVAL;
2189  return 0;
2190  }
2191 
2192  if (port == NULL) {
2193  rte_errno = EINVAL;
2194  return 0;
2195  }
2196 #endif
2197  rte_eventdev_trace_deq_burst(dev_id, port_id, ev, nb_events);
2198  /*
2199  * Allow zero cost non burst mode routine invocation if application
2200  * requests nb_events as const one
2201  */
2202  if (nb_events == 1)
2203  return (fp_ops->dequeue)(port, ev, timeout_ticks);
2204  else
2205  return (fp_ops->dequeue_burst)(port, ev, nb_events,
2206  timeout_ticks);
2207 }
2208 
2209 #define RTE_EVENT_DEV_MAINT_OP_FLUSH (1 << 0)
2210 
2251 __rte_experimental
2252 static inline int
2253 rte_event_maintain(uint8_t dev_id, uint8_t port_id, int op)
2254 {
2255  const struct rte_event_fp_ops *fp_ops;
2256  void *port;
2257 
2258  fp_ops = &rte_event_fp_ops[dev_id];
2259  port = fp_ops->data[port_id];
2260 #ifdef RTE_LIBRTE_EVENTDEV_DEBUG
2261  if (dev_id >= RTE_EVENT_MAX_DEVS ||
2262  port_id >= RTE_EVENT_MAX_PORTS_PER_DEV)
2263  return -EINVAL;
2264 
2265  if (port == NULL)
2266  return -EINVAL;
2267 
2268  if (op & (~RTE_EVENT_DEV_MAINT_OP_FLUSH))
2269  return -EINVAL;
2270 #endif
2271  rte_eventdev_trace_maintain(dev_id, port_id, op);
2272 
2273  if (fp_ops->maintain != NULL)
2274  fp_ops->maintain(port, op);
2275 
2276  return 0;
2277 }
2278 
2279 #ifdef __cplusplus
2280 }
2281 #endif
2282 
2283 #endif /* _RTE_EVENTDEV_H_ */
void rte_event_dev_stop(uint8_t dev_id)
uint32_t min_dequeue_timeout_ns
Definition: rte_eventdev.h:402
int rte_event_dequeue_timeout_ticks(uint8_t dev_id, uint64_t ns, uint64_t *timeout_ticks)
static uint16_t rte_event_enqueue_new_burst(uint8_t dev_id, uint8_t port_id, const struct rte_event ev[], uint16_t nb_events)
#define __rte_always_inline
Definition: rte_common.h:255
#define RTE_EVENT_DEV_XSTATS_NAME_SIZE
uint64_t u64
int rte_event_dev_attr_get(uint8_t dev_id, uint32_t attr_id, uint32_t *attr_value)
uint16_t elem_offset
uint32_t flow_id
int rte_event_eth_tx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id, uint32_t *caps)
uint16_t nb_elem
uint8_t priority
struct rte_device * dev
Definition: rte_eventdev.h:401
int rte_event_queue_setup(uint8_t dev_id, uint8_t queue_id, const struct rte_event_queue_conf *queue_conf)
uint8_t max_event_port_links
Definition: rte_eventdev.h:432
int rte_event_queue_default_conf_get(uint8_t dev_id, uint8_t queue_id, struct rte_event_queue_conf *queue_conf)
int rte_event_port_default_conf_get(uint8_t dev_id, uint8_t port_id, struct rte_event_port_conf *port_conf)
uint32_t dequeue_timeout_ns
Definition: rte_eventdev.h:406
#define rte_errno
Definition: rte_errno.h:29
uint32_t event_type
uint32_t event_dev_cap
Definition: rte_eventdev.h:441
int rte_event_dev_socket_id(uint8_t dev_id)
static __rte_experimental int rte_event_maintain(uint8_t dev_id, uint8_t port_id, int op)
uint32_t max_event_port_enqueue_depth
Definition: rte_eventdev.h:427
uint64_t rte_event_dev_xstats_by_name_get(uint8_t dev_id, const char *name, unsigned int *id)
int rte_event_timer_adapter_caps_get(uint8_t dev_id, uint32_t *caps)
int rte_event_dev_info_get(uint8_t dev_id, struct rte_event_dev_info *dev_info)
uint32_t cache_size
Definition: rte_mempool.h:214
uint32_t nb_atomic_order_sequences
Definition: rte_eventdev.h:614
uint32_t nb_event_port_dequeue_depth
Definition: rte_eventdev.h:538
int rte_event_port_unlinks_in_progress(uint8_t dev_id, uint8_t port_id)
void * event_ptr
int rte_event_port_link(uint8_t dev_id, uint8_t port_id, const uint8_t queues[], const uint8_t priorities[], uint16_t nb_links)
int rte_event_queue_attr_get(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id, uint32_t *attr_value)
struct rte_event_vector * vec
uint8_t max_single_link_event_port_queue_pairs
Definition: rte_eventdev.h:443
rte_event_dev_xstats_mode
int rte_event_port_links_get(uint8_t dev_id, uint8_t port_id, uint8_t queues[], uint8_t priorities[])
int rte_event_dev_stop_flush_callback_register(uint8_t dev_id, rte_eventdev_stop_flush_t callback, void *userdata)
int rte_event_dev_selftest(uint8_t dev_id)
static uint16_t rte_event_enqueue_burst(uint8_t dev_id, uint8_t port_id, const struct rte_event ev[], uint16_t nb_events)
int rte_event_dev_start(uint8_t dev_id)
int rte_event_port_setup(uint8_t dev_id, uint8_t port_id, const struct rte_event_port_conf *port_conf)
uint8_t max_event_port_dequeue_depth
Definition: rte_eventdev.h:422
int rte_event_port_attr_get(uint8_t dev_id, uint8_t port_id, uint32_t attr_id, uint32_t *attr_value)
uint32_t nb_event_port_enqueue_depth
Definition: rte_eventdev.h:546
const char * driver_name
Definition: rte_eventdev.h:400
__rte_experimental void rte_event_port_quiesce(uint8_t dev_id, uint8_t port_id, rte_eventdev_port_flush_t release_cb, void *args)
uint8_t impl_opaque
uint8_t queue_id
static uint16_t rte_event_dequeue_burst(uint8_t dev_id, uint8_t port_id, struct rte_event ev[], uint16_t nb_events, uint64_t timeout_ticks)
int rte_event_dev_get_dev_id(const char *name)
uint8_t rte_event_dev_count(void)
int rte_event_dev_close(uint8_t dev_id)
int rte_event_dev_xstats_get(uint8_t dev_id, enum rte_event_dev_xstats_mode mode, uint8_t queue_port_id, const unsigned int ids[], uint64_t values[], unsigned int n)
int rte_event_dev_xstats_reset(uint8_t dev_id, enum rte_event_dev_xstats_mode mode, int16_t queue_port_id, const uint32_t ids[], uint32_t nb_ids)
#define RTE_STD_C11
Definition: rte_common.h:39
int rte_event_crypto_adapter_caps_get(uint8_t dev_id, uint8_t cdev_id, uint32_t *caps)
uint32_t dequeue_timeout_ns
Definition: rte_eventdev.h:507
int rte_event_dev_service_id_get(uint8_t dev_id, uint32_t *service_id)
static uint16_t rte_event_enqueue_forward_burst(uint8_t dev_id, uint8_t port_id, const struct rte_event ev[], uint16_t nb_events)
#define RTE_EVENT_DEV_MAINT_OP_FLUSH
struct rte_mempool * rte_event_vector_pool_create(const char *name, unsigned int n, unsigned int cache_size, uint16_t nb_elem, int socket_id)
int rte_event_dev_dump(uint8_t dev_id, FILE *f)
uint8_t nb_single_link_event_port_queues
Definition: rte_eventdev.h:556
uint8_t rsvd
void(* rte_eventdev_port_flush_t)(uint8_t dev_id, struct rte_event event, void *arg)
Definition: rte_eventdev.h:913
uint8_t op
void(* rte_eventdev_stop_flush_t)(uint8_t dev_id, struct rte_event event, void *arg)
int32_t new_event_threshold
Definition: rte_eventdev.h:835
uint8_t max_event_priority_levels
Definition: rte_eventdev.h:416
struct rte_mbuf * mbuf
uint32_t max_dequeue_timeout_ns
Definition: rte_eventdev.h:404
uint32_t max_event_queue_flows
Definition: rte_eventdev.h:410
int rte_event_dev_configure(uint8_t dev_id, const struct rte_event_dev_config *dev_conf)
uint32_t sub_event_type
uint8_t sched_type
uint8_t max_event_queues
Definition: rte_eventdev.h:408
struct rte_event_vector __rte_aligned(16)
uint8_t max_event_queue_priority_levels
Definition: rte_eventdev.h:412
int rte_event_port_unlink(uint8_t dev_id, uint8_t port_id, uint8_t queues[], uint16_t nb_unlinks)
int rte_event_eth_rx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id, uint32_t *caps)
int rte_event_dev_xstats_names_get(uint8_t dev_id, enum rte_event_dev_xstats_mode mode, uint8_t queue_port_id, struct rte_event_dev_xstats_name *xstats_names, unsigned int *ids, unsigned int size)
__rte_experimental int rte_event_queue_attr_set(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id, uint64_t attr_value)
uint32_t nb_event_queue_flows
Definition: rte_eventdev.h:533