DPDK  22.07.0
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 };
644 
667 int
668 rte_event_queue_default_conf_get(uint8_t dev_id, uint8_t queue_id,
669  struct rte_event_queue_conf *queue_conf);
670 
689 int
690 rte_event_queue_setup(uint8_t dev_id, uint8_t queue_id,
691  const struct rte_event_queue_conf *queue_conf);
692 
696 #define RTE_EVENT_QUEUE_ATTR_PRIORITY 0
697 
700 #define RTE_EVENT_QUEUE_ATTR_NB_ATOMIC_FLOWS 1
701 
704 #define RTE_EVENT_QUEUE_ATTR_NB_ATOMIC_ORDER_SEQUENCES 2
705 
708 #define RTE_EVENT_QUEUE_ATTR_EVENT_QUEUE_CFG 3
709 
712 #define RTE_EVENT_QUEUE_ATTR_SCHEDULE_TYPE 4
713 
716 #define RTE_EVENT_QUEUE_ATTR_WEIGHT 5
717 
720 #define RTE_EVENT_QUEUE_ATTR_AFFINITY 6
721 
742 int
743 rte_event_queue_attr_get(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id,
744  uint32_t *attr_value);
745 
764 __rte_experimental
765 int
766 rte_event_queue_attr_set(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id,
767  uint64_t attr_value);
768 
769 /* Event port specific APIs */
770 
771 /* Event port configuration bitmap flags */
772 #define RTE_EVENT_PORT_CFG_DISABLE_IMPL_REL (1ULL << 0)
773 
779 #define RTE_EVENT_PORT_CFG_SINGLE_LINK (1ULL << 1)
780 
784 #define RTE_EVENT_PORT_CFG_HINT_PRODUCER (1ULL << 2)
785 
794 #define RTE_EVENT_PORT_CFG_HINT_CONSUMER (1ULL << 3)
795 
805 #define RTE_EVENT_PORT_CFG_HINT_WORKER (1ULL << 4)
806 
832  uint16_t dequeue_depth;
838  uint16_t enqueue_depth;
844  uint32_t event_port_cfg;
845 };
846 
869 int
870 rte_event_port_default_conf_get(uint8_t dev_id, uint8_t port_id,
871  struct rte_event_port_conf *port_conf);
872 
893 int
894 rte_event_port_setup(uint8_t dev_id, uint8_t port_id,
895  const struct rte_event_port_conf *port_conf);
896 
897 typedef void (*rte_eventdev_port_flush_t)(uint8_t dev_id,
898  struct rte_event event, void *arg);
928 __rte_experimental
929 void
930 rte_event_port_quiesce(uint8_t dev_id, uint8_t port_id,
931  rte_eventdev_port_flush_t release_cb, void *args);
932 
936 #define RTE_EVENT_PORT_ATTR_ENQ_DEPTH 0
937 
940 #define RTE_EVENT_PORT_ATTR_DEQ_DEPTH 1
941 
944 #define RTE_EVENT_PORT_ATTR_NEW_EVENT_THRESHOLD 2
945 
948 #define RTE_EVENT_PORT_ATTR_IMPLICIT_RELEASE_DISABLE 3
949 
966 int
967 rte_event_port_attr_get(uint8_t dev_id, uint8_t port_id, uint32_t attr_id,
968  uint32_t *attr_value);
969 
986 int
987 rte_event_dev_start(uint8_t dev_id);
988 
1007 void
1008 rte_event_dev_stop(uint8_t dev_id);
1009 
1010 typedef void (*eventdev_stop_flush_t)(uint8_t dev_id, struct rte_event event,
1011  void *arg);
1040 int
1042  eventdev_stop_flush_t callback, void *userdata);
1043 
1055 int
1056 rte_event_dev_close(uint8_t dev_id);
1062  uint16_t nb_elem;
1064  uint16_t rsvd : 15;
1066  uint16_t attr_valid : 1;
1069  union {
1070  /* Used by Rx/Tx adapter.
1071  * Indicates that all the elements in this vector belong to the
1072  * same port and queue pair when originating from Rx adapter,
1073  * valid only when event type is ETHDEV_VECTOR or
1074  * ETH_RX_ADAPTER_VECTOR.
1075  * Can also be used to indicate the Tx adapter the destination
1076  * port and queue of the mbufs in the vector
1077  */
1078  struct {
1079  uint16_t port;
1080  /* Ethernet device port id. */
1081  uint16_t queue;
1082  /* Ethernet device queue id. */
1083  };
1084  };
1086  uint64_t impl_opaque;
1087 
1088 /* empty structures do not have zero size in C++ leading to compilation errors
1089  * with clang about structure having different sizes in C and C++.
1090  * Since these are all zero-sized arrays, we can omit the "union" wrapper for
1091  * C++ builds, removing the warning.
1092  */
1093 #ifndef __cplusplus
1094 
1099  union {
1100 #endif
1101  struct rte_mbuf *mbufs[0];
1102  void *ptrs[0];
1103  uint64_t *u64s[0];
1104 #ifndef __cplusplus
1105  } __rte_aligned(16);
1106 #endif
1107 
1111 } __rte_aligned(16);
1112 
1113 /* Scheduler type definitions */
1114 #define RTE_SCHED_TYPE_ORDERED 0
1115 
1141 #define RTE_SCHED_TYPE_ATOMIC 1
1142 
1160 #define RTE_SCHED_TYPE_PARALLEL 2
1161 
1173 /* Event types to classify the event source */
1174 #define RTE_EVENT_TYPE_ETHDEV 0x0
1175 
1176 #define RTE_EVENT_TYPE_CRYPTODEV 0x1
1177 
1178 #define RTE_EVENT_TYPE_TIMER 0x2
1179 
1180 #define RTE_EVENT_TYPE_CPU 0x3
1181 
1184 #define RTE_EVENT_TYPE_ETH_RX_ADAPTER 0x4
1185 
1186 #define RTE_EVENT_TYPE_VECTOR 0x8
1187 
1198 #define RTE_EVENT_TYPE_ETHDEV_VECTOR \
1199  (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_ETHDEV)
1200 
1201 #define RTE_EVENT_TYPE_CPU_VECTOR (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_CPU)
1202 
1203 #define RTE_EVENT_TYPE_ETH_RX_ADAPTER_VECTOR \
1204  (RTE_EVENT_TYPE_VECTOR | RTE_EVENT_TYPE_ETH_RX_ADAPTER)
1205 
1207 #define RTE_EVENT_TYPE_MAX 0x10
1208 
1210 /* Event enqueue operations */
1211 #define RTE_EVENT_OP_NEW 0
1212 
1215 #define RTE_EVENT_OP_FORWARD 1
1216 
1223 #define RTE_EVENT_OP_RELEASE 2
1224 
1261 struct rte_event {
1263  union {
1264  uint64_t event;
1266  struct {
1267  uint32_t flow_id:20;
1274  uint32_t sub_event_type:8;
1278  uint32_t event_type:4;
1282  uint8_t op:2;
1288  uint8_t rsvd:4;
1290  uint8_t sched_type:2;
1295  uint8_t queue_id;
1302  uint8_t priority;
1312  uint8_t impl_opaque;
1319  };
1320  };
1322  union {
1323  uint64_t u64;
1325  void *event_ptr;
1327  struct rte_mbuf *mbuf;
1331  };
1332 };
1333 
1334 /* Ethdev Rx adapter capability bitmap flags */
1335 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_INTERNAL_PORT 0x1
1336 
1339 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_MULTI_EVENTQ 0x2
1340 
1343 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_OVERRIDE_FLOW_ID 0x4
1344 
1350 #define RTE_EVENT_ETH_RX_ADAPTER_CAP_EVENT_VECTOR 0x8
1351 
1372 int
1373 rte_event_eth_rx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id,
1374  uint32_t *caps);
1375 
1376 #define RTE_EVENT_TIMER_ADAPTER_CAP_INTERNAL_PORT (1ULL << 0)
1377 
1379 #define RTE_EVENT_TIMER_ADAPTER_CAP_PERIODIC (1ULL << 1)
1380 
1395 int
1396 rte_event_timer_adapter_caps_get(uint8_t dev_id, uint32_t *caps);
1397 
1398 /* Crypto adapter capability bitmap flag */
1399 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_NEW 0x1
1400 
1406 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD 0x2
1407 
1413 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_QP_EV_BIND 0x4
1414 
1418 #define RTE_EVENT_CRYPTO_ADAPTER_CAP_SESSION_PRIVATE_DATA 0x8
1419 
1443 int
1444 rte_event_crypto_adapter_caps_get(uint8_t dev_id, uint8_t cdev_id,
1445  uint32_t *caps);
1446 
1447 /* Ethdev Tx adapter capability bitmap flags */
1448 #define RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT 0x1
1449 
1451 #define RTE_EVENT_ETH_TX_ADAPTER_CAP_EVENT_VECTOR 0x2
1452 
1473 int
1474 rte_event_eth_tx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id,
1475  uint32_t *caps);
1476 
1502 int
1503 rte_event_dequeue_timeout_ticks(uint8_t dev_id, uint64_t ns,
1504  uint64_t *timeout_ticks);
1505 
1566 int
1567 rte_event_port_link(uint8_t dev_id, uint8_t port_id,
1568  const uint8_t queues[], const uint8_t priorities[],
1569  uint16_t nb_links);
1570 
1610 int
1611 rte_event_port_unlink(uint8_t dev_id, uint8_t port_id,
1612  uint8_t queues[], uint16_t nb_unlinks);
1613 
1635 int
1636 rte_event_port_unlinks_in_progress(uint8_t dev_id, uint8_t port_id);
1637 
1665 int
1666 rte_event_port_links_get(uint8_t dev_id, uint8_t port_id,
1667  uint8_t queues[], uint8_t priorities[]);
1668 
1684 int
1685 rte_event_dev_service_id_get(uint8_t dev_id, uint32_t *service_id);
1686 
1700 int
1701 rte_event_dev_dump(uint8_t dev_id, FILE *f);
1702 
1704 #define RTE_EVENT_DEV_XSTATS_NAME_SIZE 64
1705 
1710  RTE_EVENT_DEV_XSTATS_DEVICE,
1711  RTE_EVENT_DEV_XSTATS_PORT,
1712  RTE_EVENT_DEV_XSTATS_QUEUE,
1713 };
1714 
1722  char name[RTE_EVENT_DEV_XSTATS_NAME_SIZE];
1723 };
1724 
1757 int
1758 rte_event_dev_xstats_names_get(uint8_t dev_id,
1759  enum rte_event_dev_xstats_mode mode,
1760  uint8_t queue_port_id,
1761  struct rte_event_dev_xstats_name *xstats_names,
1762  unsigned int *ids,
1763  unsigned int size);
1764 
1791 int
1792 rte_event_dev_xstats_get(uint8_t dev_id,
1793  enum rte_event_dev_xstats_mode mode,
1794  uint8_t queue_port_id,
1795  const unsigned int ids[],
1796  uint64_t values[], unsigned int n);
1797 
1814 uint64_t
1815 rte_event_dev_xstats_by_name_get(uint8_t dev_id, const char *name,
1816  unsigned int *id);
1817 
1838 int
1839 rte_event_dev_xstats_reset(uint8_t dev_id,
1840  enum rte_event_dev_xstats_mode mode,
1841  int16_t queue_port_id,
1842  const uint32_t ids[],
1843  uint32_t nb_ids);
1844 
1855 int rte_event_dev_selftest(uint8_t dev_id);
1856 
1887 struct rte_mempool *
1888 rte_event_vector_pool_create(const char *name, unsigned int n,
1889  unsigned int cache_size, uint16_t nb_elem,
1890  int socket_id);
1891 
1892 #include <rte_eventdev_core.h>
1893 
1894 static __rte_always_inline uint16_t
1895 __rte_event_enqueue_burst(uint8_t dev_id, uint8_t port_id,
1896  const struct rte_event ev[], uint16_t nb_events,
1897  const event_enqueue_burst_t fn)
1898 {
1899  const struct rte_event_fp_ops *fp_ops;
1900  void *port;
1901 
1902  fp_ops = &rte_event_fp_ops[dev_id];
1903  port = fp_ops->data[port_id];
1904 #ifdef RTE_LIBRTE_EVENTDEV_DEBUG
1905  if (dev_id >= RTE_EVENT_MAX_DEVS ||
1906  port_id >= RTE_EVENT_MAX_PORTS_PER_DEV) {
1907  rte_errno = EINVAL;
1908  return 0;
1909  }
1910 
1911  if (port == NULL) {
1912  rte_errno = EINVAL;
1913  return 0;
1914  }
1915 #endif
1916  rte_eventdev_trace_enq_burst(dev_id, port_id, ev, nb_events, (void *)fn);
1917  /*
1918  * Allow zero cost non burst mode routine invocation if application
1919  * requests nb_events as const one
1920  */
1921  if (nb_events == 1)
1922  return (fp_ops->enqueue)(port, ev);
1923  else
1924  return fn(port, ev, nb_events);
1925 }
1926 
1970 static inline uint16_t
1971 rte_event_enqueue_burst(uint8_t dev_id, uint8_t port_id,
1972  const struct rte_event ev[], uint16_t nb_events)
1973 {
1974  const struct rte_event_fp_ops *fp_ops;
1975 
1976  fp_ops = &rte_event_fp_ops[dev_id];
1977  return __rte_event_enqueue_burst(dev_id, port_id, ev, nb_events,
1978  fp_ops->enqueue_burst);
1979 }
1980 
2022 static inline uint16_t
2023 rte_event_enqueue_new_burst(uint8_t dev_id, uint8_t port_id,
2024  const struct rte_event ev[], uint16_t nb_events)
2025 {
2026  const struct rte_event_fp_ops *fp_ops;
2027 
2028  fp_ops = &rte_event_fp_ops[dev_id];
2029  return __rte_event_enqueue_burst(dev_id, port_id, ev, nb_events,
2030  fp_ops->enqueue_new_burst);
2031 }
2032 
2074 static inline uint16_t
2075 rte_event_enqueue_forward_burst(uint8_t dev_id, uint8_t port_id,
2076  const struct rte_event ev[], uint16_t nb_events)
2077 {
2078  const struct rte_event_fp_ops *fp_ops;
2079 
2080  fp_ops = &rte_event_fp_ops[dev_id];
2081  return __rte_event_enqueue_burst(dev_id, port_id, ev, nb_events,
2082  fp_ops->enqueue_forward_burst);
2083 }
2084 
2151 static inline uint16_t
2152 rte_event_dequeue_burst(uint8_t dev_id, uint8_t port_id, struct rte_event ev[],
2153  uint16_t nb_events, uint64_t timeout_ticks)
2154 {
2155  const struct rte_event_fp_ops *fp_ops;
2156  void *port;
2157 
2158  fp_ops = &rte_event_fp_ops[dev_id];
2159  port = fp_ops->data[port_id];
2160 #ifdef RTE_LIBRTE_EVENTDEV_DEBUG
2161  if (dev_id >= RTE_EVENT_MAX_DEVS ||
2162  port_id >= RTE_EVENT_MAX_PORTS_PER_DEV) {
2163  rte_errno = EINVAL;
2164  return 0;
2165  }
2166 
2167  if (port == NULL) {
2168  rte_errno = EINVAL;
2169  return 0;
2170  }
2171 #endif
2172  rte_eventdev_trace_deq_burst(dev_id, port_id, ev, nb_events);
2173  /*
2174  * Allow zero cost non burst mode routine invocation if application
2175  * requests nb_events as const one
2176  */
2177  if (nb_events == 1)
2178  return (fp_ops->dequeue)(port, ev, timeout_ticks);
2179  else
2180  return (fp_ops->dequeue_burst)(port, ev, nb_events,
2181  timeout_ticks);
2182 }
2183 
2184 #define RTE_EVENT_DEV_MAINT_OP_FLUSH (1 << 0)
2185 
2226 __rte_experimental
2227 static inline int
2228 rte_event_maintain(uint8_t dev_id, uint8_t port_id, int op)
2229 {
2230  const struct rte_event_fp_ops *fp_ops;
2231  void *port;
2232 
2233  fp_ops = &rte_event_fp_ops[dev_id];
2234  port = fp_ops->data[port_id];
2235 #ifdef RTE_LIBRTE_EVENTDEV_DEBUG
2236  if (dev_id >= RTE_EVENT_MAX_DEVS ||
2237  port_id >= RTE_EVENT_MAX_PORTS_PER_DEV)
2238  return -EINVAL;
2239 
2240  if (port == NULL)
2241  return -EINVAL;
2242 
2243  if (op & (~RTE_EVENT_DEV_MAINT_OP_FLUSH))
2244  return -EINVAL;
2245 #endif
2246  rte_eventdev_trace_maintain(dev_id, port_id, op);
2247 
2248  if (fp_ops->maintain != NULL)
2249  fp_ops->maintain(port, op);
2250 
2251  return 0;
2252 }
2253 
2254 #ifdef __cplusplus
2255 }
2256 #endif
2257 
2258 #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:258
#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)
uint32_t flow_id
int rte_event_eth_tx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id, uint32_t *caps)
int rte_event_dev_stop_flush_callback_register(uint8_t dev_id, eventdev_stop_flush_t callback, void *userdata)
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:220
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_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:42
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:897
uint8_t op
int32_t new_event_threshold
Definition: rte_eventdev.h:819
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)
void(* eventdev_stop_flush_t)(uint8_t dev_id, struct rte_event event, void *arg)
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