24 #ifndef DOCA_DPA_DEV_H_
25 #define DOCA_DPA_DEV_H_
32 #define DOCA_DPA_DEVICE
129 #ifndef __forceinline
130 #define __forceinline static inline __attribute__((always_inline))
271 #define DOCA_DPA_DEV_LOG_ERR(...) doca_dpa_dev_log(DOCA_DPA_DEV_LOG_LEVEL_ERROR, __VA_ARGS__)
279 #define DOCA_DPA_DEV_LOG_WARN(...) doca_dpa_dev_log(DOCA_DPA_DEV_LOG_LEVEL_WARNING, __VA_ARGS__)
287 #define DOCA_DPA_DEV_LOG_INFO(...) doca_dpa_dev_log(DOCA_DPA_DEV_LOG_LEVEL_INFO, __VA_ARGS__)
295 #define DOCA_DPA_DEV_LOG_DBG(...) doca_dpa_dev_log(DOCA_DPA_DEV_LOG_LEVEL_DEBUG, __VA_ARGS__)
struct dpa_thread_arg __dpa_global__
#define __attribute__(_x_)
To allow compiling functions and structs that are using GCC attributes using attribute() in compilers...
#define DOCA_EXPERIMENTAL
To set a Symbol (or specifically a function) as experimental.
DOCA_EXPERIMENTAL unsigned int doca_dpa_dev_num_threads(void)
Obtains the number of threads running the kernel.
DOCA_EXPERIMENTAL void doca_dpa_dev_completion_request_notification(doca_dpa_dev_completion_t dpa_comp_handle)
Request notification on the DPA completion.
DOCA_EXPERIMENTAL void doca_dpa_dev_thread_reschedule(void)
Reschedule a DPA thread.
DOCA_EXPERIMENTAL int doca_dpa_dev_hash_table_find(doca_dpa_dev_hash_table_t ht_handle, uint32_t key, uint64_t *value)
Returns the value to which the specified key is mapped in the hash table.
DOCA_EXPERIMENTAL void doca_dpa_dev_device_set(doca_dpa_dev_t dpa_handle)
Set a DPA device.
__dpa_global__ enum doca_dpa_dev_log_level doca_dpa_dev_log_level_t
DOCA DPA device log levels, sorted by verbosity from high to low.
DOCA_EXPERIMENTAL void doca_dpa_dev_thread_finish(void)
Finish a DPA thread.
DOCA_EXPERIMENTAL void doca_dpa_dev_log(doca_dpa_dev_log_level_t log_level, const char *format,...) __attribute__((format(printf
Print logs to Host.
DOCA_EXPERIMENTAL void doca_dpa_dev_thread_notify(doca_dpa_dev_notification_completion_t comp_handle)
Notify the completion handle and trigger the attached thread.
DOCA_EXPERIMENTAL void doca_dpa_dev_yield(void)
Yield a DPA thread.
DOCA_EXPERIMENTAL void doca_dpa_dev_hash_table_remove(doca_dpa_dev_hash_table_t ht_handle, uint32_t key)
Remove the key and its corresponding value from the hash table.
DOCA_EXPERIMENTAL unsigned int doca_dpa_dev_thread_rank(void)
Obtains the thread rank.
DOCA_EXPERIMENTAL uint32_t doca_dpa_dev_get_completion_user_data(doca_dpa_dev_completion_element_t comp_element)
Get completion element user data.
DOCA_EXPERIMENTAL void doca_dpa_dev_trace(uint64_t arg1, uint64_t arg2, uint64_t arg3, uint64_t arg4, uint64_t arg5)
Creates trace message entry with arguments.
__dpa_global__ typedef uint64_t doca_dpa_dev_notification_completion_t
DPA notification completion handle type definition.
DOCA_EXPERIMENTAL void doca_dpa_dev_completion_ack(doca_dpa_dev_completion_t dpa_comp_handle, uint64_t num_comp)
Acknowledge that the completions have been read on the completion context.
__dpa_global__ typedef uint64_t doca_dpa_dev_async_ops_t
DPA asynchronous ops handle type definition.
__dpa_global__ typedef uint64_t doca_dpa_dev_completion_element_t
DPA completion element handle type definition.
doca_dpa_dev_submit_flag
DPA submit flag type.
DOCA_EXPERIMENTAL doca_dpa_dev_completion_type_t doca_dpa_dev_get_completion_type(doca_dpa_dev_completion_element_t comp_element)
Get completion element type.
__dpa_global__ typedef uint64_t doca_dpa_dev_uintptr_t
DPA pointer type definition.
DOCA_EXPERIMENTAL int doca_dpa_dev_get_completion(doca_dpa_dev_completion_t dpa_comp_handle, doca_dpa_dev_completion_element_t *comp_element)
Get DPA completion element.
DOCA_EXPERIMENTAL void doca_dpa_dev_trace_flush(void)
Flush the trace message buffer to Host.
DOCA_EXPERIMENTAL void doca_dpa_dev_hash_table_add(doca_dpa_dev_hash_table_t ht_handle, uint32_t key, uint64_t value)
Map a specific key to the specified value in the hash table.
DOCA_EXPERIMENTAL doca_dpa_dev_uintptr_t doca_dpa_dev_thread_get_local_storage(void)
Get DPA thread local storage.
DOCA_EXPERIMENTAL uint32_t doca_dpa_dev_get_completion_immediate(doca_dpa_dev_completion_element_t comp_element)
Get completion element immediate data.
__dpa_global__ typedef uint64_t doca_dpa_dev_hash_table_t
DPA hash table handle type definition.
__dpa_global__ typedef uint64_t doca_dpa_dev_completion_t
DPA completion handle type definition.
__dpa_global__ typedef uint64_t doca_dpa_dev_t
DPA context handle type definition.
doca_dpa_dev_completion_type_t
DPA completion type.
@ DOCA_DPA_DEV_LOG_LEVEL_ERROR
@ DOCA_DPA_DEV_LOG_LEVEL_DISABLE
@ DOCA_DPA_DEV_LOG_LEVEL_DEBUG
@ DOCA_DPA_DEV_LOG_LEVEL_WARNING
@ DOCA_DPA_DEV_LOG_LEVEL_INFO
@ DOCA_DPA_DEV_SUBMIT_FLAG_NONE
@ DOCA_DPA_DEV_SUBMIT_FLAG_OPTIMIZE_REPORTS
@ DOCA_DPA_DEV_SUBMIT_FLAG_FLUSH
@ DOCA_DPA_DEV_COMP_SEND_ERR
@ DOCA_DPA_DEV_COMP_RECV_SEND
@ DOCA_DPA_DEV_COMP_RECV_RDMA_WRITE_IMM
@ DOCA_DPA_DEV_COMP_RECV_ERR
@ DOCA_DPA_DEV_COMP_RECV_SEND_IMM
uint64_t doca_dpa_dev_hash_table_t
DPA hash table handle type definition.
doca_dpa_dev_log_level
DOCA DPA device log levels, sorted by verbosity from high to low.
uint64_t doca_dpa_dev_t
DPA context handle type definition.
enum doca_dpa_dev_log_level doca_dpa_dev_log_level_t
DOCA DPA device log levels, sorted by verbosity from high to low.
uint64_t doca_dpa_dev_completion_t
DPA completion handle type definition.
uint64_t doca_dpa_dev_uintptr_t
DPA pointer type definition.
uint64_t doca_dpa_dev_notification_completion_t
DPA notification completion handle type definition.