| NVIDIA DOCA SDK | Data Center on a Chip Framework Documentation |
Typedefs | |
| typedef void(* | doca_ec_task_galois_mul_completion_cb_t) (struct doca_ec_task_galois_mul *task, union doca_data task_user_data, union doca_data ctx_user_data) |
| Function to execute on completion of a Galois multiplication task. More... | |
| typedef void(* | doca_ec_task_create_completion_cb_t) (struct doca_ec_task_create *task, union doca_data task_user_data, union doca_data ctx_user_data) |
| Function to execute on completion of a create task. More... | |
| typedef void(* | doca_ec_task_update_completion_cb_t) (struct doca_ec_task_update *task, union doca_data task_user_data, union doca_data ctx_user_data) |
| Function to execute on completion of an update task. More... | |
| typedef void(* | doca_ec_task_recover_completion_cb_t) (struct doca_ec_task_recover *task, union doca_data task_user_data, union doca_data ctx_user_data) |
| Function to execute on completion of a recover task. More... | |
Enumerations | |
| enum | doca_ec_matrix_type { DOCA_EC_MATRIX_TYPE_CAUCHY = 1 , DOCA_EC_MATRIX_TYPE_VANDERMONDE = 2 } |
| Types of coding matrix used for erasure codes. More... | |
Functions | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_cap_task_galois_mul_is_supported (const struct doca_devinfo *devinfo) |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_galois_mul_set_conf (struct doca_ec *ec, doca_ec_task_galois_mul_completion_cb_t successful_task_completion_cb, doca_ec_task_galois_mul_completion_cb_t error_task_completion_cb, uint32_t num_tasks) |
| This method sets the Galois multiplication tasks configuration. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_galois_mul_allocate_init (struct doca_ec *ec, const struct doca_ec_matrix *coding_matrix, const struct doca_buf *src_buf, struct doca_buf *dst_buf, union doca_data user_data, struct doca_ec_task_galois_mul **task) |
| This method allocates and initializes a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL struct doca_task * | doca_ec_task_galois_mul_as_task (struct doca_ec_task_galois_mul *task) |
| This method converts an EC Galois multiplication task to a doca_task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_galois_mul_set_coding_matrix (struct doca_ec_task_galois_mul *task, const struct doca_ec_matrix *coding_matrix) |
| This method sets the coding_matrix of a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix * | doca_ec_task_galois_mul_get_coding_matrix (const struct doca_ec_task_galois_mul *task) |
| This method gets the coding matrix of a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_galois_mul_set_src_buf (struct doca_ec_task_galois_mul *task, const struct doca_buf *src_buf) |
| This method sets the source buffer of a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL const struct doca_buf * | doca_ec_task_galois_mul_get_src_buf (const struct doca_ec_task_galois_mul *task) |
| This method gets the source buffer of a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_galois_mul_set_dst_buf (struct doca_ec_task_galois_mul *task, struct doca_buf *dst_buf) |
| This method sets the destination buffer of a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL struct doca_buf * | doca_ec_task_galois_mul_get_dst_buf (const struct doca_ec_task_galois_mul *task) |
| This method gets the destination buffer of a Galois multiplication task. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_cap_task_create_is_supported (const struct doca_devinfo *devinfo) |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_create_set_conf (struct doca_ec *ec, doca_ec_task_create_completion_cb_t successful_task_completion_cb, doca_ec_task_create_completion_cb_t error_task_completion_cb, uint32_t num_tasks) |
| This method sets the create tasks configuration. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_create_allocate_init (struct doca_ec *ec, const struct doca_ec_matrix *coding_matrix, const struct doca_buf *original_data_blocks, struct doca_buf *rdnc_blocks, union doca_data user_data, struct doca_ec_task_create **task) |
| This method allocates and initializes a create task. More... | |
| DOCA_EXPERIMENTAL struct doca_task * | doca_ec_task_create_as_task (struct doca_ec_task_create *task) |
| This method converts an EC create task to a doca_task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_create_set_coding_matrix (struct doca_ec_task_create *task, const struct doca_ec_matrix *coding_matrix) |
| This method sets the coding_matrix of a create task. More... | |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix * | doca_ec_task_create_get_coding_matrix (const struct doca_ec_task_create *task) |
| This method gets the coding matrix of a create task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_create_set_original_data_blocks (struct doca_ec_task_create *task, const struct doca_buf *original_data_blocks) |
| This method sets the original_data_blocks buffer of a create task. More... | |
| DOCA_EXPERIMENTAL const struct doca_buf * | doca_ec_task_create_get_original_data_blocks (const struct doca_ec_task_create *task) |
| This method gets the original_data_blocks buffer of a create task. The original_data_blocks buffer is a source buffer with data - A sequence containing all original data blocks - block_1, block_2 ,... More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_create_set_rdnc_blocks (struct doca_ec_task_create *task, struct doca_buf *rdnc_blocks) |
| This method sets the rdnc_blocks buffer of a create task. More... | |
| DOCA_EXPERIMENTAL struct doca_buf * | doca_ec_task_create_get_rdnc_blocks (const struct doca_ec_task_create *task) |
| This method gets the rdnc_blocks buffer of a create task. The rdnc_blocks buffer is a destination buffer for the redundancy blocks. On successful completion of this task, will hold a sequence containing all redundancy blocks - rdnc_block_1, rdnc_block_2 ,... More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_cap_task_update_is_supported (const struct doca_devinfo *devinfo) |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_update_set_conf (struct doca_ec *ec, doca_ec_task_update_completion_cb_t successful_task_completion_cb, doca_ec_task_update_completion_cb_t error_task_completion_cb, uint32_t num_tasks) |
| This method sets the update tasks configuration. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_update_allocate_init (struct doca_ec *ec, const struct doca_ec_matrix *update_matrix, const struct doca_buf *original_updated_and_rdnc_blocks, struct doca_buf *updated_rdnc_blocks, union doca_data user_data, struct doca_ec_task_update **task) |
| This method allocates and initializes an update task. More... | |
| DOCA_EXPERIMENTAL struct doca_task * | doca_ec_task_update_as_task (struct doca_ec_task_update *task) |
| This method converts an EC update task to a doca_task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_update_set_update_matrix (struct doca_ec_task_update *task, const struct doca_ec_matrix *update_matrix) |
| This method sets the update_matrix of an update task. More... | |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix * | doca_ec_task_update_get_update_matrix (const struct doca_ec_task_update *task) |
| This method gets the update_matrix of an update task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_update_set_original_updated_and_rdnc_blocks (struct doca_ec_task_update *task, const struct doca_buf *original_updated_and_rdnc_blocks) |
| This method sets the original_updated_and_rdnc_blocks buffer of an update task. More... | |
| DOCA_EXPERIMENTAL const struct doca_buf * | doca_ec_task_update_get_original_updated_and_rdnc_blocks (const struct doca_ec_task_update *task) |
| This method gets the original_updated_and_rdnc_blocks buffer of an update task. The original_data_blocks buffer is a source buffer with data - A sequence containing the original data block and it's updated data block, for each block that was updated, followed by the old redundancy blocks - old_data_block_i, updated_data_block_i, old_data_block_j, updated_data_block_j ,... ,rdnc_block_1, rdnc_block_2 ,... More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_update_set_updated_rdnc_blocks (struct doca_ec_task_update *task, struct doca_buf *updated_rdnc_blocks) |
| This method sets the updated_rdnc_blocks buffer of an update task. More... | |
| DOCA_EXPERIMENTAL struct doca_buf * | doca_ec_task_update_get_updated_rdnc_blocks (const struct doca_ec_task_update *task) |
| This method gets the updated_rdnc_blocks buffer of an update task. The rdnc_blocks buffer is a destination buffer for the redundancy blocks. On successful completion of this task, will hold a sequence containing all redundancy blocks - rdnc_block_1, rdnc_block_2 ,... More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_cap_task_recover_is_supported (const struct doca_devinfo *devinfo) |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_recover_set_conf (struct doca_ec *ec, doca_ec_task_recover_completion_cb_t successful_task_completion_cb, doca_ec_task_recover_completion_cb_t error_task_completion_cb, uint32_t num_tasks) |
| This method sets the recover tasks configuration. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_task_recover_allocate_init (struct doca_ec *ec, const struct doca_ec_matrix *recover_matrix, const struct doca_buf *available_blocks, struct doca_buf *recovered_data_blocks, union doca_data user_data, struct doca_ec_task_recover **task) |
| This method allocates and initializes a recover task. More... | |
| DOCA_EXPERIMENTAL struct doca_task * | doca_ec_task_recover_as_task (struct doca_ec_task_recover *task) |
| This method converts an EC recover task to a doca_task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_recover_set_recover_matrix (struct doca_ec_task_recover *task, const struct doca_ec_matrix *recover_matrix) |
| This method sets the recover_matrix of a recover task. More... | |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix * | doca_ec_task_recover_get_recover_matrix (const struct doca_ec_task_recover *task) |
| This method gets the recover_matrix of a recover task. More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_recover_set_available_blocks (struct doca_ec_task_recover *task, const struct doca_buf *available_blocks) |
| This method sets the available_blocks buffer of a recover task. More... | |
| DOCA_EXPERIMENTAL const struct doca_buf * | doca_ec_task_recover_get_available_blocks (const struct doca_ec_task_recover *task) |
| This method gets the available_blocks buffer of a recover task. The available_blocks buffer is a source buffer with data - A sequence containing all available data blocks and redundancy blocks - data_block_a, data_block_b, data_block_c ,... ,rdnc_block_x, rdnc_block_y ,... More... | |
| DOCA_EXPERIMENTAL void | doca_ec_task_recover_set_recovered_data_blocks (struct doca_ec_task_recover *task, struct doca_buf *recovered_data_blocks) |
| This method sets the recovered_data_blocks buffer of a recover task. More... | |
| DOCA_EXPERIMENTAL struct doca_buf * | doca_ec_task_recover_get_recovered_data (const struct doca_ec_task_recover *task) |
| This method gets the recovered_data buffer of a recover task. The recovered_data buffer is a destination buffer for the recovered data blocks. On successful completion of this task, will hold a sequence containing all the recovered data blocks - data_block_i, data_block_j ,... More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_create (struct doca_dev *dev, struct doca_ec **ec) |
| Create a DOCA EC instance. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_destroy (struct doca_ec *ec) |
| Destroy a DOCA EC instance. More... | |
| DOCA_EXPERIMENTAL struct doca_ctx * | doca_ec_as_ctx (struct doca_ec *ec) |
| Convert EC instance into context. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_cap_get_max_block_size (const struct doca_devinfo *devinfo, uint64_t *max_block_size) |
| Get maximum block size supported for DOCA EC tasks. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_cap_get_max_buf_list_len (const struct doca_devinfo *devinfo, uint32_t *max_buf_list_len) |
| Get the maximum supported number of elements in DOCA linked-list buffer used for EC tasks. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_matrix_create (struct doca_ec *ec, enum doca_ec_matrix_type type, size_t data_block_count, size_t rdnc_block_count, struct doca_ec_matrix **matrix) |
| Generate coding matrix for Erasure Code encode i.e. most basic encode matrix. This is necessary for executing create tasks. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_matrix_create_from_raw (struct doca_ec *ec, uint8_t *data, size_t data_block_count, size_t rdnc_block_count, struct doca_ec_matrix **matrix) |
| Create coding matrix for Erasure Code encode i.e. most basic encode matrix from char array. This is substitute for doca_ec_matrix_create which converts a char array to an DOCA EC matrix that can be used to execute different EC tasks. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_matrix_create_update (struct doca_ec *ec, const struct doca_ec_matrix *coding_matrix, uint32_t update_indices[], size_t n_updates, struct doca_ec_matrix **matrix) |
| Generate coding matrix for Erasure Code update. To use this function must call doca_ec_matrix_create() or doca_ec_matrix_create_from_raw() before. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_matrix_create_recover (struct doca_ec *ec, const struct doca_ec_matrix *coding_matrix, uint32_t missing_indices[], size_t n_missing, struct doca_ec_matrix **matrix) |
| Generate coding matrix for Erasure Code recovery from failure. To use this function must call doca_ec_matrix_create() or doca_ec_matrix_create_from_raw() before. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_ec_matrix_destroy (struct doca_ec_matrix *matrix) |
| Destroy coding matrix. More... | |
DOCA Erasure Coding library. For more details please refer to the user guide on DOCA devzone.
| typedef void(* doca_ec_task_create_completion_cb_t) (struct doca_ec_task_create *task, union doca_data task_user_data, union doca_data ctx_user_data) |
Function to execute on completion of a create task.
This function is called by doca_pe_progress() when a create task is successfully identified as completed. When this function is called the ownership of the task object passes from DOCA back to user. Inside this callback the user may decide on the task object:
Any failure/error inside this function should be handled internally or deferred; Since this function is nested in the execution of doca_pe_progress(), this callback doesn't return an error.
| [in] | task | The completed create task. |
| [in] | task_user_data | The doca_data supplied to the task by the application (during task allocation or by a setter). |
| [in] | ctx_user_data | The doca_data supplied to the doca_ctx by the application (using a setter). |
Definition at line 311 of file doca_erasure_coding.h.
| typedef void(* doca_ec_task_galois_mul_completion_cb_t) (struct doca_ec_task_galois_mul *task, union doca_data task_user_data, union doca_data ctx_user_data) |
Function to execute on completion of a Galois multiplication task.
This function is called by doca_pe_progress() when a Galois multiplication task is successfully identified as completed. When this function is called the ownership of the task object passes from DOCA back to user. Inside this callback the user may decide on the task object:
Any failure/error inside this function should be handled internally or deferred; Since this function is nested in the execution of doca_pe_progress(), this callback doesn't return an error.
| [in] | task | The completed Galois multiplication task. |
| [in] | task_user_data | The doca_data supplied to the task by the application (during task allocation or by a setter). |
| [in] | ctx_user_data | The doca_data supplied to the doca_ctx by the application (using a setter). |
Definition at line 92 of file doca_erasure_coding.h.
| typedef void(* doca_ec_task_recover_completion_cb_t) (struct doca_ec_task_recover *task, union doca_data task_user_data, union doca_data ctx_user_data) |
Function to execute on completion of a recover task.
This function is called by doca_pe_progress() when a recover task is successfully identified as completed. When this function is called the ownership of the task object passes from DOCA back to user. Inside this callback the user may decide on the task object:
Any failure/error inside this function should be handled internally or deferred; Since this function is nested in the execution of doca_pe_progress(), this callback doesn't return an error.
| [in] | task | The completed recover task. |
| [in] | task_user_data | The doca_data supplied to the task by the application (during task allocation or by a setter). |
| [in] | ctx_user_data | The doca_data supplied to the doca_ctx by the application (using a setter). |
Definition at line 772 of file doca_erasure_coding.h.
| typedef void(* doca_ec_task_update_completion_cb_t) (struct doca_ec_task_update *task, union doca_data task_user_data, union doca_data ctx_user_data) |
Function to execute on completion of an update task.
This function is called by doca_pe_progress() when an update task is successfully identified as completed. When this function is called the ownership of the task object passes from DOCA back to user. Inside this callback the user may decide on the task object:
Any failure/error inside this function should be handled internally or deferred; Since this function is nested in the execution of doca_pe_progress(), this callback doesn't return an error.
| [in] | task | The completed update task. |
| [in] | task_user_data | The doca_data supplied to the task by the application (during task allocation or by a setter). |
| [in] | ctx_user_data | The doca_data supplied to the doca_ctx by the application (using a setter). |
Definition at line 538 of file doca_erasure_coding.h.
| enum doca_ec_matrix_type |
Types of coding matrix used for erasure codes.
Definition at line 1067 of file doca_erasure_coding.h.
| DOCA_EXPERIMENTAL struct doca_ctx* doca_ec_as_ctx | ( | struct doca_ec * | ec | ) |
Convert EC instance into context.
| [in] | ec | EC instance. This must remain valid until after the context is no longer required. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_cap_get_max_block_size | ( | const struct doca_devinfo * | devinfo, |
| uint64_t * | max_block_size | ||
| ) |
Get maximum block size supported for DOCA EC tasks.
| [in] | devinfo | The DOCA device information that should be queried. |
| [out] | max_block_size | The max block size for DOCA EC operation in bytes. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_cap_get_max_buf_list_len | ( | const struct doca_devinfo * | devinfo, |
| uint32_t * | max_buf_list_len | ||
| ) |
Get the maximum supported number of elements in DOCA linked-list buffer used for EC tasks.
| [in] | devinfo | The DOCA device information that should be queried. |
| [out] | max_buf_list_len | The maximum supported number of elements in DOCA linked-list buffer. The value 1 indicates that only a single element is supported. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_cap_task_create_is_supported | ( | const struct doca_devinfo * | devinfo | ) |
Check if a given device supports executing a create task.
| [in] | devinfo | The DOCA device information that should be queried. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_cap_task_galois_mul_is_supported | ( | const struct doca_devinfo * | devinfo | ) |
Check if a given device supports executing a Galois multiplication task.
| [in] | devinfo | The DOCA device information that should be queried. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_cap_task_recover_is_supported | ( | const struct doca_devinfo * | devinfo | ) |
Check if a given device supports executing a recover task.
| [in] | devinfo | The DOCA device information that should be queried. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_cap_task_update_is_supported | ( | const struct doca_devinfo * | devinfo | ) |
Check if a given device supports executing an update task.
| [in] | devinfo | The DOCA device information that should be queried. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_create | ( | struct doca_dev * | dev, |
| struct doca_ec ** | ec | ||
| ) |
Create a DOCA EC instance.
| [in] | dev | The device to attach to the EC instance. |
| [out] | ec | Pointer to pointer to be set to point to the created doca_ec instance. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_destroy | ( | struct doca_ec * | ec | ) |
Destroy a DOCA EC instance.
| [in] | ec | Pointer to instance to be destroyed. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_matrix_create | ( | struct doca_ec * | ec, |
| enum doca_ec_matrix_type | type, | ||
| size_t | data_block_count, | ||
| size_t | rdnc_block_count, | ||
| struct doca_ec_matrix ** | matrix | ||
| ) |
Generate coding matrix for Erasure Code encode i.e. most basic encode matrix. This is necessary for executing create tasks.
| [in] | ec | EC instance. |
| [in] | type | Provided in enum doca_ec_matrix_type, the type will be consistent in recovery/update process. |
| [in] | data_block_count | The number of original data blocks. |
| [in] | rdnc_block_count | The number of redundancy blocks. |
| [out] | matrix | The coding matrix. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_matrix_create_from_raw | ( | struct doca_ec * | ec, |
| uint8_t * | data, | ||
| size_t | data_block_count, | ||
| size_t | rdnc_block_count, | ||
| struct doca_ec_matrix ** | matrix | ||
| ) |
Create coding matrix for Erasure Code encode i.e. most basic encode matrix from char array. This is substitute for doca_ec_matrix_create which converts a char array to an DOCA EC matrix that can be used to execute different EC tasks.
| [in] | ec | EC instance. |
| [in] | data | The data of a coding matrix with size data_block_count * rdnc_block_count. |
| [in] | data_block_count | The number of original data blocks. |
| [in] | rdnc_block_count | The number of redundancy blocks. |
| [out] | matrix | The coding matrix. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_matrix_create_recover | ( | struct doca_ec * | ec, |
| const struct doca_ec_matrix * | coding_matrix, | ||
| uint32_t | missing_indices[], | ||
| size_t | n_missing, | ||
| struct doca_ec_matrix ** | matrix | ||
| ) |
Generate coding matrix for Erasure Code recovery from failure. To use this function must call doca_ec_matrix_create() or doca_ec_matrix_create_from_raw() before.
| [in] | ec | EC instance. |
| [in] | coding_matrix | A coding matrix as it was created by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| [in] | missing_indices | An array specifying the indices of the missing data blocks. |
| [in] | n_missing | missing_indices count. |
| [out] | matrix | The recover coding matrix. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_matrix_create_update | ( | struct doca_ec * | ec, |
| const struct doca_ec_matrix * | coding_matrix, | ||
| uint32_t | update_indices[], | ||
| size_t | n_updates, | ||
| struct doca_ec_matrix ** | matrix | ||
| ) |
Generate coding matrix for Erasure Code update. To use this function must call doca_ec_matrix_create() or doca_ec_matrix_create_from_raw() before.
| [in] | ec | EC instance. |
| [in] | coding_matrix | A coding matrix as it was created by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| [in] | update_indices | An array specifying the indices of the updated data blocks. |
| [in] | n_updates | update_indices count. |
| [out] | matrix | The update coding matrix. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_matrix_destroy | ( | struct doca_ec_matrix * | matrix | ) |
Destroy coding matrix.
| [in] | matrix | A coding matrix as it was created by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_create_allocate_init | ( | struct doca_ec * | ec, |
| const struct doca_ec_matrix * | coding_matrix, | ||
| const struct doca_buf * | original_data_blocks, | ||
| struct doca_buf * | rdnc_blocks, | ||
| union doca_data | user_data, | ||
| struct doca_ec_task_create ** | task | ||
| ) |
This method allocates and initializes a create task.
| [in] | ec | The EC instance to allocate the task for. |
| [in] | coding_matrix | A coding matrix as it was create by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| [in] | original_data_blocks | A source buffer with data - A sequence containing all original data blocks - block_1, block_2 ,... |
| [in] | rdnc_blocks | A destination buffer for the redundancy blocks. On successful completion of this task, will hold a sequence containing all redundancy blocks - rdnc_block_1, rdnc_block_2 ,... |
| [in] | user_data | doca_data to attach to the task. |
| [out] | task | On success, an allocated and initialized create task. |
They also should be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL struct doca_task* doca_ec_task_create_as_task | ( | struct doca_ec_task_create * | task | ) |
This method converts an EC create task to a doca_task.
| [in] | task | The task that should be converted. |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix* doca_ec_task_create_get_coding_matrix | ( | const struct doca_ec_task_create * | task | ) |
This method gets the coding matrix of a create task.
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL const struct doca_buf* doca_ec_task_create_get_original_data_blocks | ( | const struct doca_ec_task_create * | task | ) |
This method gets the original_data_blocks buffer of a create task. The original_data_blocks buffer is a source buffer with data - A sequence containing all original data blocks - block_1, block_2 ,...
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL struct doca_buf* doca_ec_task_create_get_rdnc_blocks | ( | const struct doca_ec_task_create * | task | ) |
This method gets the rdnc_blocks buffer of a create task. The rdnc_blocks buffer is a destination buffer for the redundancy blocks. On successful completion of this task, will hold a sequence containing all redundancy blocks - rdnc_block_1, rdnc_block_2 ,...
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL void doca_ec_task_create_set_coding_matrix | ( | struct doca_ec_task_create * | task, |
| const struct doca_ec_matrix * | coding_matrix | ||
| ) |
This method sets the coding_matrix of a create task.
| [in] | task | The task to set. |
| [in] | coding_matrix | A coding matrix as it was create by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_create_set_conf | ( | struct doca_ec * | ec, |
| doca_ec_task_create_completion_cb_t | successful_task_completion_cb, | ||
| doca_ec_task_create_completion_cb_t | error_task_completion_cb, | ||
| uint32_t | num_tasks | ||
| ) |
This method sets the create tasks configuration.
| [in] | ec | The EC instance to config. |
| [in] | successful_task_completion_cb | A callback function for create tasks that were completed successfully. |
| [in] | error_task_completion_cb | A callback function for create tasks that were completed with an error. |
| [in] | num_tasks | Number of create tasks. |
| DOCA_EXPERIMENTAL void doca_ec_task_create_set_original_data_blocks | ( | struct doca_ec_task_create * | task, |
| const struct doca_buf * | original_data_blocks | ||
| ) |
This method sets the original_data_blocks buffer of a create task.
| [in] | task | The task to set. |
| [in] | original_data_blocks | A source buffer with data - A sequence containing all original data blocks - block_1, block_2 ,... |
The data length should also be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL void doca_ec_task_create_set_rdnc_blocks | ( | struct doca_ec_task_create * | task, |
| struct doca_buf * | rdnc_blocks | ||
| ) |
This method sets the rdnc_blocks buffer of a create task.
| [in] | task | The task to set. |
| [in] | rdnc_blocks | A destination buffer for the redundancy blocks. On successful completion of this task, will hold a sequence containing all redundancy blocks - rdnc_block_1, rdnc_block_2 ,... |
The minimal available memory should also be aligned to 64B and at least 64B. For example: 500B size should be padded to be 512B at the least.
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_galois_mul_allocate_init | ( | struct doca_ec * | ec, |
| const struct doca_ec_matrix * | coding_matrix, | ||
| const struct doca_buf * | src_buf, | ||
| struct doca_buf * | dst_buf, | ||
| union doca_data | user_data, | ||
| struct doca_ec_task_galois_mul ** | task | ||
| ) |
This method allocates and initializes a Galois multiplication task.
| [in] | ec | The EC instance to allocate the task for. |
| [in] | coding_matrix | A coding matrix as it was create by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| [in] | src_buf | A source buffer with data - A sequence containing data blocks - block_1, block_2 ,... |
| [in] | dst_buf | Destination data buffer. On successful completion of this task, will hold a sequence containing all multiplication outcome blocks - dst_block_1, dst_block_2 ,... |
| [in] | user_data | doca_data to attach to the task. |
| [out] | task | On success, an allocated and initialized Galois multiplication task. |
They also should be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL struct doca_task* doca_ec_task_galois_mul_as_task | ( | struct doca_ec_task_galois_mul * | task | ) |
This method converts an EC Galois multiplication task to a doca_task.
| [in] | task | The task that should be converted. |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix* doca_ec_task_galois_mul_get_coding_matrix | ( | const struct doca_ec_task_galois_mul * | task | ) |
This method gets the coding matrix of a Galois multiplication task.
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL struct doca_buf* doca_ec_task_galois_mul_get_dst_buf | ( | const struct doca_ec_task_galois_mul * | task | ) |
This method gets the destination buffer of a Galois multiplication task.
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL const struct doca_buf* doca_ec_task_galois_mul_get_src_buf | ( | const struct doca_ec_task_galois_mul * | task | ) |
This method gets the source buffer of a Galois multiplication task.
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL void doca_ec_task_galois_mul_set_coding_matrix | ( | struct doca_ec_task_galois_mul * | task, |
| const struct doca_ec_matrix * | coding_matrix | ||
| ) |
This method sets the coding_matrix of a Galois multiplication task.
| [in] | task | The task to set. |
| [in] | coding_matrix | A coding matrix as it was create by doca_ec_matrix_create() or doca_ec_matrix_create_from_raw(). |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_galois_mul_set_conf | ( | struct doca_ec * | ec, |
| doca_ec_task_galois_mul_completion_cb_t | successful_task_completion_cb, | ||
| doca_ec_task_galois_mul_completion_cb_t | error_task_completion_cb, | ||
| uint32_t | num_tasks | ||
| ) |
This method sets the Galois multiplication tasks configuration.
| [in] | ec | The EC instance to config. |
| [in] | successful_task_completion_cb | A callback function for Galois multiplication tasks that were completed successfully. |
| [in] | error_task_completion_cb | A callback function for Galois multiplication tasks that were completed with an error. |
| [in] | num_tasks | Number of Galois multiplication tasks. |
| DOCA_EXPERIMENTAL void doca_ec_task_galois_mul_set_dst_buf | ( | struct doca_ec_task_galois_mul * | task, |
| struct doca_buf * | dst_buf | ||
| ) |
This method sets the destination buffer of a Galois multiplication task.
| [in] | task | The task to set. |
| [in] | dst_buf | Destination data buffer. On successful completion of this task, will hold a sequence containing all multiplication outcome blocks - dst_block_1, dst_block_2 ,... |
The minimal available memory should also be aligned to 64B and at least 64B. For example: 500B size should be padded to be 512B at the least.
| DOCA_EXPERIMENTAL void doca_ec_task_galois_mul_set_src_buf | ( | struct doca_ec_task_galois_mul * | task, |
| const struct doca_buf * | src_buf | ||
| ) |
This method sets the source buffer of a Galois multiplication task.
| [in] | task | The task to set. |
| [in] | src_buf | A source buffer with data - A sequence containing all original data blocks - block_1, block_2 ,... |
The data length should also be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_recover_allocate_init | ( | struct doca_ec * | ec, |
| const struct doca_ec_matrix * | recover_matrix, | ||
| const struct doca_buf * | available_blocks, | ||
| struct doca_buf * | recovered_data_blocks, | ||
| union doca_data | user_data, | ||
| struct doca_ec_task_recover ** | task | ||
| ) |
This method allocates and initializes a recover task.
| [in] | ec | The EC instance to allocate the task for. |
| [in] | recover_matrix | The recover coding matrix as it was created by doca_ec_matrix_create_recover() or doca_ec_matrix_create_from_raw(). |
| [in] | available_blocks | A source buffer with data - A sequence containing available data blocks and redundancy blocks - data_block_a, data_block_b, data_block_c ,... ,rdnc_block_x, rdnc_block_y ,... The total number of blocks given in this buffer should be equal to the original number data blocks. |
| [in] | recovered_data_blocks | A destination buffer for the recovered data blocks. On successful completion of this task, will hold a sequence containing all the recovered data blocks - data_block_i, data_block_j ,... |
| [in] | user_data | doca_data to attach to the task. |
| [out] | task | On success, an allocated and initialized recover task. |
They also should be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL struct doca_task* doca_ec_task_recover_as_task | ( | struct doca_ec_task_recover * | task | ) |
This method converts an EC recover task to a doca_task.
| [in] | task | The task that should be converted. |
| DOCA_EXPERIMENTAL const struct doca_buf* doca_ec_task_recover_get_available_blocks | ( | const struct doca_ec_task_recover * | task | ) |
This method gets the available_blocks buffer of a recover task. The available_blocks buffer is a source buffer with data - A sequence containing all available data blocks and redundancy blocks - data_block_a, data_block_b, data_block_c ,... ,rdnc_block_x, rdnc_block_y ,...
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix* doca_ec_task_recover_get_recover_matrix | ( | const struct doca_ec_task_recover * | task | ) |
This method gets the recover_matrix of a recover task.
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL struct doca_buf* doca_ec_task_recover_get_recovered_data | ( | const struct doca_ec_task_recover * | task | ) |
This method gets the recovered_data buffer of a recover task. The recovered_data buffer is a destination buffer for the recovered data blocks. On successful completion of this task, will hold a sequence containing all the recovered data blocks - data_block_i, data_block_j ,...
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL void doca_ec_task_recover_set_available_blocks | ( | struct doca_ec_task_recover * | task, |
| const struct doca_buf * | available_blocks | ||
| ) |
This method sets the available_blocks buffer of a recover task.
| [in] | task | The task to set. |
| [in] | available_blocks | A source buffer with data - A sequence containing available data blocks and redundancy blocks - data_block_a, data_block_b, data_block_c ,... ,rdnc_block_x, rdnc_block_y ,... The total number of blocks given in this buffer should be equal to the original number data blocks. |
The data length should also be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_recover_set_conf | ( | struct doca_ec * | ec, |
| doca_ec_task_recover_completion_cb_t | successful_task_completion_cb, | ||
| doca_ec_task_recover_completion_cb_t | error_task_completion_cb, | ||
| uint32_t | num_tasks | ||
| ) |
This method sets the recover tasks configuration.
| [in] | ec | The EC instance to config. |
| [in] | successful_task_completion_cb | A callback function for recover tasks that were completed successfully. |
| [in] | error_task_completion_cb | A callback function for recover tasks that were completed with an error. |
| [in] | num_tasks | Number of recover tasks. |
| DOCA_EXPERIMENTAL void doca_ec_task_recover_set_recover_matrix | ( | struct doca_ec_task_recover * | task, |
| const struct doca_ec_matrix * | recover_matrix | ||
| ) |
This method sets the recover_matrix of a recover task.
| [in] | task | The task to set. |
| [in] | recover_matrix | The recover coding matrix as it was created by doca_ec_matrix_create_recover() or doca_ec_matrix_create_from_raw(). |
| DOCA_EXPERIMENTAL void doca_ec_task_recover_set_recovered_data_blocks | ( | struct doca_ec_task_recover * | task, |
| struct doca_buf * | recovered_data_blocks | ||
| ) |
This method sets the recovered_data_blocks buffer of a recover task.
| [in] | task | The task to set. |
| [in] | recovered_data_blocks | A destination buffer for the recovered data blocks. On successful completion of this task, will hold a sequence containing all the recovered data blocks - data_block_i, data_block_j ,... |
The minimal available memory should also be aligned to 64B and at least 64B. For example: 500B size should be padded to be 512B at the least.
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_update_allocate_init | ( | struct doca_ec * | ec, |
| const struct doca_ec_matrix * | update_matrix, | ||
| const struct doca_buf * | original_updated_and_rdnc_blocks, | ||
| struct doca_buf * | updated_rdnc_blocks, | ||
| union doca_data | user_data, | ||
| struct doca_ec_task_update ** | task | ||
| ) |
This method allocates and initializes an update task.
| [in] | ec | The EC instance to allocate the task for. |
| [in] | update_matrix | The update coding matrix as it was created by doca_ec_matrix_create_update() or doca_ec_matrix_create_from_raw(). |
| [in] | original_updated_and_rdnc_blocks | A source buffer with data - A sequence containing the original data block and it's updated data block, for each block that was updated, followed by the old redundancy blocks - old_data_block_i, updated_data_block_i, old_data_block_j, updated_data_block_j ,... ,rdnc_block_1, rdnc_block_2 ,... |
| [in] | updated_rdnc_blocks | A destination buffer for the updated redundancy blocks. On successful completion of this task, will hold a sequence containing all updated redundancy blocks - rdnc_block_1, rdnc_block_2 ,... |
| [in] | user_data | doca_data to attach to the task. |
| [out] | task | On success, an allocated and initialized update task. |
They also should be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL struct doca_task* doca_ec_task_update_as_task | ( | struct doca_ec_task_update * | task | ) |
This method converts an EC update task to a doca_task.
| [in] | task | The task that should be converted. |
| DOCA_EXPERIMENTAL const struct doca_buf* doca_ec_task_update_get_original_updated_and_rdnc_blocks | ( | const struct doca_ec_task_update * | task | ) |
This method gets the original_updated_and_rdnc_blocks buffer of an update task. The original_data_blocks buffer is a source buffer with data - A sequence containing the original data block and it's updated data block, for each block that was updated, followed by the old redundancy blocks - old_data_block_i, updated_data_block_i, old_data_block_j, updated_data_block_j ,... ,rdnc_block_1, rdnc_block_2 ,...
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL const struct doca_ec_matrix* doca_ec_task_update_get_update_matrix | ( | const struct doca_ec_task_update * | task | ) |
This method gets the update_matrix of an update task.
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL struct doca_buf* doca_ec_task_update_get_updated_rdnc_blocks | ( | const struct doca_ec_task_update * | task | ) |
This method gets the updated_rdnc_blocks buffer of an update task. The rdnc_blocks buffer is a destination buffer for the redundancy blocks. On successful completion of this task, will hold a sequence containing all redundancy blocks - rdnc_block_1, rdnc_block_2 ,...
| [in] | task | The task that should be queried. |
| DOCA_EXPERIMENTAL doca_error_t doca_ec_task_update_set_conf | ( | struct doca_ec * | ec, |
| doca_ec_task_update_completion_cb_t | successful_task_completion_cb, | ||
| doca_ec_task_update_completion_cb_t | error_task_completion_cb, | ||
| uint32_t | num_tasks | ||
| ) |
This method sets the update tasks configuration.
| [in] | ec | The EC instance to config. |
| [in] | successful_task_completion_cb | A callback function for update tasks that were completed successfully. |
| [in] | error_task_completion_cb | A callback function for update tasks that were completed with an error. |
| [in] | num_tasks | Number of update tasks. |
| DOCA_EXPERIMENTAL void doca_ec_task_update_set_original_updated_and_rdnc_blocks | ( | struct doca_ec_task_update * | task, |
| const struct doca_buf * | original_updated_and_rdnc_blocks | ||
| ) |
This method sets the original_updated_and_rdnc_blocks buffer of an update task.
| [in] | task | The task to set. |
| [in] | original_updated_and_rdnc_blocks | A source buffer with data - A sequence containing the original data block and it's updated data block, for each block that was updated, followed by the old redundancy blocks - old_data_block_i, updated_data_block_i, old_data_block_j, updated_data_block_j ,... ,rdnc_block_1, rdnc_block_2 ,... |
The data length should also be aligned to 64B and with a minimum size of 64B. For example: 500B size should be padded to be 512B.
| DOCA_EXPERIMENTAL void doca_ec_task_update_set_update_matrix | ( | struct doca_ec_task_update * | task, |
| const struct doca_ec_matrix * | update_matrix | ||
| ) |
This method sets the update_matrix of an update task.
| [in] | task | The task to set. |
| [in] | update_matrix | The update coding matrix as it was created by doca_ec_matrix_create_update() or doca_ec_matrix_create_from_raw(). |
| DOCA_EXPERIMENTAL void doca_ec_task_update_set_updated_rdnc_blocks | ( | struct doca_ec_task_update * | task, |
| struct doca_buf * | updated_rdnc_blocks | ||
| ) |
This method sets the updated_rdnc_blocks buffer of an update task.
| [in] | task | The task to set. |
| [in] | updated_rdnc_blocks | A destination buffer for the updated redundancy blocks. On successful completion of this task, will hold a sequence containing all updated redundancy blocks - rdnc_block_1, rdnc_block_2 ,... |
The minimal available memory should also be aligned to 64B and at least 64B. For example: 500B size should be padded to be 512B at the least.