NVIDIA DOCA SDK Data Center on a Chip Framework Documentation
doca_sta.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_H_
15 #define DOCA_STA_H_
16 
17 #include <stdint.h>
18 
19 #include <doca_compat.h>
20 #include <doca_error.h>
21 #include <doca_dpa.h>
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 
27 struct doca_devinfo;
28 struct doca_dev;
29 struct doca_pe;
30 struct doca_sta;
31 
43 doca_error_t doca_sta_cap_is_supported(const struct doca_devinfo *devinfo);
44 
63 doca_error_t doca_sta_create(struct doca_dev *dev, struct doca_sta **sta);
64 
79 doca_error_t doca_sta_destroy(struct doca_sta *sta);
80 
97 doca_error_t doca_sta_add_dev(struct doca_sta *sta, struct doca_dev *dev);
98 
100 doca_error_t doca_sta_set_max_sta_io(struct doca_sta *sta, uint16_t max_io_num);
101 
103 doca_error_t doca_sta_get_max_sta_io(const struct doca_sta *sta, uint16_t *max_io_num);
104 
114 struct doca_ctx *doca_sta_as_ctx(struct doca_sta *sta);
115 
127 
138 doca_error_t doca_sta_get_max_num_eus_available(const struct doca_sta *sta, uint32_t *max_eus);
139 
150 doca_error_t doca_sta_get_max_num_connected_qp_per_eu(const struct doca_sta *sta, uint32_t *max_connected_qps);
151 
153 doca_error_t doca_sta_get_max_subsys(uint32_t *max_subsys);
154 
156 doca_error_t doca_sta_get_max_ns_per_subs(uint32_t *max_ns_per_subsys);
157 
160 
162 doca_error_t doca_sta_get_max_io_threads(uint32_t *max_io_threads);
163 
165 doca_error_t doca_sta_get_max_io_size(uint32_t *max_io_size);
166 
168 doca_error_t doca_sta_get_max_io_num_per_dev(const struct doca_sta *sta, uint32_t *max_ios);
169 
171 doca_error_t doca_sta_get_max_io_queue_size(const struct doca_sta *sta, uint32_t *max_io_queue_size);
172 
175 
178 
181 
184 
187 
190 
192 doca_error_t doca_sta_get_max_qs_per_be(uint32_t *max_qs_per_be);
193 
196 
197 #ifdef __cplusplus
198 }
199 #endif
200 
201 #endif /* DOCA_STA_H_ */
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_min_iorcsz(uint32_t *iorcsz)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_devs(uint32_t *max_devs)
Get the max number of the supported devices by the STA engine.
DOCA_EXPERIMENTAL doca_error_t doca_sta_add_dev(struct doca_sta *sta, struct doca_dev *dev)
Support STA functionality on a given device.
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_io_queue_size(const struct doca_sta *sta, uint32_t *max_io_queue_size)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_ioccsz(uint32_t *ioccsz)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_io_num_per_dev(const struct doca_sta *sta, uint32_t *max_ios)
DOCA_EXPERIMENTAL bool doca_sta_is_logical_block_size_supported(uint32_t size)
DOCA_EXPERIMENTAL doca_error_t doca_sta_cap_is_supported(const struct doca_devinfo *devinfo)
Get whether the DOCA device supports storage target acceleration ('STA')
DOCA_EXPERIMENTAL doca_error_t doca_sta_create(struct doca_dev *dev, struct doca_sta **sta)
Create a DOCA STA Context.
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_qps(uint32_t *max_qps)
DOCA_EXPERIMENTAL doca_error_t doca_sta_set_max_sta_io(struct doca_sta *sta, uint16_t max_io_num)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_be(uint32_t *max_be)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_min_ioccsz(uint32_t *ioccsz)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_iorcsz(uint32_t *iorcsz)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_num_connected_qp_per_eu(const struct doca_sta *sta, uint32_t *max_connected_qps)
Retrieve the maximum number of connected QPs per EU.
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_ns_per_subs(uint32_t *max_ns_per_subsys)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_qs_per_be(uint32_t *max_qs_per_be)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_icdoff(uint32_t *icdoff)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_io_size(uint32_t *max_io_size)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_io_threads(uint32_t *max_io_threads)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_subsys(uint32_t *max_subsys)
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_sta_io(const struct doca_sta *sta, uint16_t *max_io_num)
DOCA_EXPERIMENTAL struct doca_ctx * doca_sta_as_ctx(struct doca_sta *sta)
Convert doca_sta instance into a generalized context for use with doca core objects.
DOCA_EXPERIMENTAL doca_error_t doca_sta_destroy(struct doca_sta *sta)
Destroy a DOCA STA context.
DOCA_EXPERIMENTAL doca_error_t doca_sta_get_max_num_eus_available(const struct doca_sta *sta, uint32_t *max_eus)
Retrieve the total number of EUs available to the application.
#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.