NVIDIA DOCA SDK Data Center on a Chip Framework Documentation
doca_sta_be.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2024 NVIDIA CORPORATION & AFFILIATES, ALL RIGHTS RESERVED.
3  *
4  * This software product is a proprietary product of NVIDIA CORPORATION &
5  * AFFILIATES (the "Company") and all right, title, and interest in and to the
6  * software product, including all associated intellectual property rights, are
7  * and shall remain exclusively with the Company.
8  *
9  * This software product is governed by the End User License Agreement
10  * provided with the software product.
11  *
12  */
13 
14 #ifndef DOCA_STA_BE_H_
15 #define DOCA_STA_BE_H_
16 
17 #include <stdint.h>
18 
19 #include <doca_compat.h>
20 #include <doca_error.h>
21 #include <doca_mmap.h>
22 
23 #include <doca_sta_handle.h>
24 #include <doca_sta_task.h>
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
30 struct doca_sta;
31 
33 doca_error_t doca_sta_be_create(struct doca_sta *sta, struct doca_sta_be_handle **be_handle);
34 
36 doca_error_t doca_sta_be_destroy(struct doca_sta_be_handle *be_handle);
37 
39 doca_error_t doca_sta_be_add_queue(struct doca_sta_be_handle *be_handle,
40  struct doca_mmap *sq,
41  struct doca_mmap *sq_db_reg,
42  uint16_t sq_db_offset,
43  struct doca_mmap *cq,
44  struct doca_mmap *cq_db_reg,
45  uint16_t cq_db_offset,
46  struct doca_sta_be_q_handle **be_q_handle);
47 
83 doca_error_t doca_sta_be_destroy_queue_task_alloc_init(struct doca_sta_be_q_handle *be_q_handle,
84  union doca_data user_data,
85  struct doca_sta_producer_task_send **task);
86 
87 #ifdef __cplusplus
88 }
89 #endif
90 
91 #endif /* DOCA_STA_BE_H_ */
static void task_error_cb(struct doca_task *se_task, union doca_data task_user_data, union doca_data ctx_user_data)
Definition: common_common.c:65
static void task_completion_cb(struct doca_task *se_task, union doca_data task_user_data, union doca_data ctx_user_data)
Definition: common_common.c:48
DOCA_EXPERIMENTAL doca_error_t doca_sta_be_destroy_queue_task_alloc_init(struct doca_sta_be_q_handle *be_q_handle, union doca_data user_data, struct doca_sta_producer_task_send **task)
This method allocates and initializes a STA destroy queue task.
DOCA_EXPERIMENTAL doca_error_t doca_sta_be_destroy(struct doca_sta_be_handle *be_handle)
DOCA_EXPERIMENTAL doca_error_t doca_sta_be_add_queue(struct doca_sta_be_handle *be_handle, struct doca_mmap *sq, struct doca_mmap *sq_db_reg, uint16_t sq_db_offset, struct doca_mmap *cq, struct doca_mmap *cq_db_reg, uint16_t cq_db_offset, struct doca_sta_be_q_handle **be_q_handle)
DOCA_EXPERIMENTAL doca_error_t doca_sta_be_task_destroy_queue_set_conf(struct doca_sta *sta, doca_sta_task_completion_cb_t task_completion_cb, doca_sta_task_completion_cb_t task_error_cb)
This method sets the STA destroy queue tasks configuration.
DOCA_EXPERIMENTAL doca_error_t doca_sta_be_create(struct doca_sta *sta, struct doca_sta_be_handle **be_handle)
void(* doca_sta_task_completion_cb_t)(struct doca_sta_producer_task_send *task, union doca_data task_user_data)
Function to execute on STA task completion.
Definition: doca_sta_task.h:53
#define DOCA_EXPERIMENTAL
To set a Symbol (or specifically a function) as experimental.
Definition: doca_compat.h:103
enum doca_error doca_error_t
DOCA API return codes.
Convenience type for representing opaque data.
Definition: doca_types.h:56