29 #include <ucs/type/cpu_set.h>
105 #define DOCA_CPU_ZERO(_cpusetp) UCS_CPU_ZERO(_cpusetp)
112 #define DOCA_CPU_SET(_cpu, _cpusetp) UCS_CPU_SET(_cpu, _cpusetp)
119 #define doca_cpu_is_set(_cpu, _cpusetp) ucs_cpu_is_set(_cpu, _cpusetp)
134 struct doca_urom_service;
141 struct doca_urom_service_get_workers_by_gid_task;
149 struct doca_urom_service_get_workers_by_gid_task *task,
302 size_t *plugins_count);
338 struct doca_urom_service_get_workers_by_gid_task **task);
361 struct doca_urom_service *service_ctx,
364 struct doca_urom_service_get_workers_by_gid_task **task);
420 struct doca_urom_service_get_workers_by_gid_task *task);
435 struct doca_urom_service_get_workers_by_gid_task *task);
450 struct doca_urom_service_get_workers_by_gid_task *task);
471 struct doca_urom_worker;
478 struct doca_urom_worker_cmd_task;
556 #define DOCA_UROM_WORKER_ID_ANY -1ULL
786 struct doca_urom_worker_cmd_task **task);
808 struct doca_urom_worker_cmd_task **task);
932 struct doca_urom_domain;
1128 uint64_t *domain_worker_ids,
1129 struct doca_urom_worker **workers,
1130 size_t workers_cnt);
#define DOCA_EXPERIMENTAL
To set a Symbol (or specifically a function) as experimental.
enum doca_error doca_error_t
DOCA API return codes.
DOCA_EXPERIMENTAL struct doca_ctx * doca_urom_domain_as_ctx(struct doca_urom_domain *domain_ctx)
DOCA_EXPERIMENTAL doca_error_t doca_urom_domain_destroy(struct doca_urom_domain *domain_ctx)
doca_error_t(* doca_urom_domain_allgather_cb_t)(void *sbuf, void *rbuf, size_t msglen, void *coll_info, void **req)
Callback for a non-blocking allgather operation.
doca_error_t(* doca_urom_domain_req_free_cb_t)(void *req)
Callback to free a non-blocking allgather request.
DOCA_EXPERIMENTAL doca_error_t doca_urom_domain_set_oob(struct doca_urom_domain *domain_ctx, struct doca_urom_domain_oob_coll *oob)
Set OOB communication info to be used for Domain initialization.
DOCA_EXPERIMENTAL doca_error_t doca_urom_domain_create(struct doca_urom_domain **domain_ctx)
This method creates a UROM Domain context.
doca_error_t(* doca_urom_domain_req_test_cb_t)(void *req)
Callback to test the status of a non-blocking allgather request.
DOCA_EXPERIMENTAL doca_error_t doca_urom_domain_add_buffer(struct doca_urom_domain *domain_ctx, void *buffer, size_t buf_len, void *memh, size_t memh_len, void *mkey, size_t mkey_len)
This method attaches local buffer attributes to the Domain. Should be called after calling doca_urom_...
DOCA_EXPERIMENTAL doca_error_t doca_urom_domain_set_workers(struct doca_urom_domain *domain_ctx, uint64_t *domain_worker_ids, struct doca_urom_worker **workers, size_t workers_cnt)
Set the list of Workers in the domain.
DOCA_EXPERIMENTAL doca_error_t doca_urom_domain_set_buffers_count(struct doca_urom_domain *domain_ctx, size_t buffers_cnt)
This method attaches the number of local buffers that will be added to the Domain.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_set_dev(struct doca_urom_service *service_ctx, struct doca_dev *dev)
This method attaches a DOCA Device to the UROM Service context.
ucs_cpu_set_t doca_cpu_set_t
DOCA CPU set structure.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_get_plugins_list(struct doca_urom_service *service_ctx, const struct doca_urom_service_plugin_info **plugins, size_t *plugins_count)
This method gets the list of supported plugins on service's DPU side.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_get_cpuset(struct doca_urom_service *service_ctx, doca_cpu_set_t *cpuset)
Get the allowed CPU set for the service.
void(* doca_urom_service_get_workers_by_gid_task_completion_cb_t)(struct doca_urom_service_get_workers_by_gid_task *task, union doca_data task_user_data, union doca_data ctx_user_data)
Service get workers task completion callback type.
DOCA_EXPERIMENTAL struct doca_ctx * doca_urom_service_as_ctx(struct doca_urom_service *service_ctx)
Convert service_ctx instance into a generalized context for use with DOCA core objects.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_destroy(struct doca_urom_service *service_ctx)
This method destroys a UROM Service context.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_set_max_comm_msg_size(struct doca_urom_service *service_ctx, size_t msg_size)
Set the maximum message size for the UROM communication channel.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_set_max_workers(struct doca_urom_service *service_ctx, uint32_t max_workers)
Set maximum number of UROM workers.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_create(struct doca_urom_service **service_ctx)
This method creates a UROM Service context.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_cmd_task_release(struct doca_urom_worker_cmd_task *task)
Release Worker Command task.
DOCA_EXPERIMENTAL void doca_urom_worker_cmd_task_set_cb(struct doca_urom_worker_cmd_task *task, doca_urom_worker_cmd_task_completion_cb_t cb)
Set Worker Command task callback.
DOCA_EXPERIMENTAL struct doca_buf * doca_urom_worker_cmd_task_get_response(struct doca_urom_worker_cmd_task *task)
Get Worker Command task response.
DOCA_EXPERIMENTAL void * doca_urom_worker_cmd_task_get_user_data(struct doca_urom_worker_cmd_task *task)
Get Worker Command user data to populate.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_cmd_task_allocate_init(struct doca_urom_worker *worker_ctx, uint64_t plugin, struct doca_urom_worker_cmd_task **task)
Allocate and initialize Worker Command task.
DOCA_EXPERIMENTAL void doca_urom_worker_cmd_task_set_plugin(struct doca_urom_worker_cmd_task *task, uint64_t plugin)
Set Worker Command task plugin.
DOCA_EXPERIMENTAL struct doca_buf * doca_urom_worker_cmd_task_get_payload(struct doca_urom_worker_cmd_task *task)
Get Worker Command task payload.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_cmd_task_allocate(struct doca_urom_worker *worker_ctx, struct doca_urom_worker_cmd_task **task)
Allocate Worker Command task.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_service(struct doca_urom_worker *worker_ctx, struct doca_urom_service *service_ctx)
This method attaches a UROM Service to the Worker context.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_cpuset(struct doca_urom_worker *worker_ctx, doca_cpu_set_t cpuset)
Set the allowed CPUs for the Worker. The cpuset must be a subset of the service's allowed CPUs.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_destroy(struct doca_urom_worker *worker_ctx)
This method destroys a UROM Worker context.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_env(struct doca_urom_worker *worker_ctx, char *const env[], size_t count)
Set worker env variables when spawning worker on DPU side.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_get_gid(struct doca_urom_worker *worker_ctx, uint32_t *worker_gid)
This method gets the Worker context group ID to be used to identify the Worker group that belongs to.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_create(struct doca_urom_worker **worker_ctx)
This method creates a UROM Worker context.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_gid(struct doca_urom_worker *worker_ctx, uint32_t gid)
Set worker group ID, must be set before starting the worker context.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_max_inflight_tasks(struct doca_urom_worker *worker_ctx, uint32_t max_tasks)
Set Worker maximum in-flight tasks.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_id(struct doca_urom_worker *worker_ctx, uint64_t worker_id)
This method sets the Worker context ID to be used to identify the Worker. Worker IDs enable an applic...
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_set_plugins(struct doca_urom_worker *worker_ctx, uint64_t plugins)
This method adds plugins mask for the supported plugins by the UROM Worker on the DPU.
void(* doca_urom_worker_cmd_task_completion_cb_t)(struct doca_urom_worker_cmd_task *task, union doca_data task_user_data, union doca_data ctx_user_data)
Worker Command task completion callback type.
DOCA_EXPERIMENTAL doca_error_t doca_urom_worker_get_id(struct doca_urom_worker *worker_ctx, uint64_t *worker_id)
This method gets the Worker context ID to be used to identify the Worker. Worker IDs enable an applic...
DOCA_EXPERIMENTAL struct doca_ctx * doca_urom_worker_as_ctx(struct doca_urom_worker *worker_ctx)
DOCA_EXPERIMENTAL void doca_urom_service_get_workers_by_gid_task_set_gid(struct doca_urom_service_get_workers_by_gid_task *task, uint32_t gid)
Set Service get workers task group id.
DOCA_EXPERIMENTAL struct doca_task * doca_urom_service_get_workers_by_gid_task_as_task(struct doca_urom_service_get_workers_by_gid_task *task)
This method converts a service get workers task to doca_task.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_get_workers_by_gid_task_allocate_init(struct doca_urom_service *service_ctx, uint32_t gid, doca_urom_service_get_workers_by_gid_task_completion_cb_t cb, struct doca_urom_service_get_workers_by_gid_task **task)
Allocate Service get workers by gid task and set task attributes.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_get_workers_by_gid_task_release(struct doca_urom_service_get_workers_by_gid_task *task)
Release Service get workers by gid task.
DOCA_EXPERIMENTAL doca_error_t doca_urom_service_get_workers_by_gid_task_allocate(struct doca_urom_service *service_ctx, struct doca_urom_service_get_workers_by_gid_task **task)
Allocate Service get workers by gid task.
DOCA_EXPERIMENTAL const uint64_t * doca_urom_service_get_workers_by_gid_task_get_worker_ids(struct doca_urom_service_get_workers_by_gid_task *task)
Get Service get workers task ids array.
DOCA_EXPERIMENTAL size_t doca_urom_service_get_workers_by_gid_task_get_workers_count(struct doca_urom_service_get_workers_by_gid_task *task)
Get the number of workers returned for the requested gid.
DOCA_EXPERIMENTAL struct doca_task * doca_urom_worker_cmd_task_as_task(struct doca_urom_worker_cmd_task *task)
This method converts a worker cmd task to doca_task.
DOCA_EXPERIMENTAL void doca_urom_service_get_workers_by_gid_task_set_cb(struct doca_urom_service_get_workers_by_gid_task *task, doca_urom_service_get_workers_by_gid_task_completion_cb_t cb)
Set Service get workers task completion callback.
Out-of-band communication descriptor for Domain creation.
doca_urom_domain_req_free_cb_t req_free
doca_urom_domain_allgather_cb_t allgather
doca_urom_domain_req_test_cb_t req_test
Convenience type for representing opaque data.