alf_wb_dtl_entry_add

NAME

alf_wb_dtl_entry_add - Adds an entry to the input or output data transfer lists of a single use work block.

SYNOPSIS

int alf_wb_dtl_entry_add (alf_wb_handle_t wb_handle, void* host_addr, unsigned int size, ALF_DATA_TYPE_T data_type);

Parameters  
wb_handle [IN] The work block handle
host_address [IN] The pointer (EA) to the data in remote memory
size [IN] The size of the data in units of the data type
data_type [IN] The type of data, this value is required if data endianess conversion is necessary when doing the data movement

DESCRIPTION

This function adds an entry to the input or output data transfer lists of a single use work block. The entry describes a single piece of data transferred from and to the remote memory. For a specific work block, further calls to this API return errors after the work block is put to work queue by calling alf_wb_enqueue.

For a specific work block, further calls to this API return error after the work block is put to work queue by calling alf_wb_enqueue. If the work block's task is associated with a dataset, the specified buffer with host_addr and size must be contained within the dataset. Adding a dtl entry describing a buffer that is outside the associated dataset returns a ALF_ERR_PERM error.

This function can only be called if the task descriptor associated with the work block’s task is created with the task descriptor attribute ALF_TASK_DESC_PARTITION_ON_ACCEL set to false.

RETURN VALUE

0 Success.
less than 0 Errors occurred:
  • ALF_ERR_INVAL: Invalid input argument.
  • ALF_ERR_PERM: Operation not allowed.
  • ALF_ERR_BADF: Invalid work block handle.
  • ALF_ERR_2BIG: Trying to add too many lists.
  • ALF_ERR_NOBUFS: The amount of data to move exceeds the maximum buffer size.
  • ALF_ERR_FAULT: Invalid host address (if it can be detected).
  • ALF_ERR_GENERIC: Generic internal errors.
Related concepts
Data structures
Related reference
alf_wb_create
alf_wb_enqueue
alf_wb_parm_add
alf_wb_dtl_begin
alf_wb_dtl_end