arm_start_transaction() — Mark the start of an ARM transaction

Standards

Standards / Extensions C or C++ Dependencies
  both  

Format

#include <sys/_Elmarm4.h>

arm_error_t arm_start_transaction(
/* [in]     */  arm_appl_id_t     *transaction_id,
/* [in]     */  arm_correlator_t     *parent_correlator_ptr,
/* [in]     */  arm_int32_t      flags,
/* [in]     */  arm_buffer4_t   *buffer4,
/* [out]    */  arm_start_handle_t     *start_handle,
/* [out]    */  arm_correlator_t   *current_correlator_ptr
);

General description

Use arm_start_transaction() to mark the beginning of execution of a transaction. The transaction must be identified as a member of a transaction type that was previously defined by arm_init_transaction_type(). There can be any number of transactions executing simultaneously.
transaction_id
The handle passed to or returned by arm_init_transaction_type() for the transaction type.
parent_correlator_ptr
A pointer to the parent correlator for this transaction. If there is no parent correlator, a null value should be passed.
flags
One flag bit is defined:. ARM_START_FLAG_TRACE_REQUEST requests tracing of the transaction. Currently eWLM has no support to trace transactions and ignores the flag. All other flag bits are reserved and must be zero.
buffer4
A pointer to a buffer that identifies one or more sub-buffers with additional data. A null value can be specified if no additional data is required.
start_handle
A pointer to a 64-bit area where a handle that identifies the transaction is returned. The handle must be passed to other transaction-level interfaces such as arm_stop_transaction(). The handle is valid only within the caller's process.
current_correlator_ptr
A pointer to a buffer into which eWLM will store a correlator for the transaction. The length of the buffer must be at least the length returned from the arm_get_correlator_max_length() function.

Returned value

On success, arm_init_application returns ARM_RC_SUCCESS. On failure, the errno and return code are set to indicate the error. See Return code for the list of all possible return codes. On failure, the application_id is set to a dummy value which can be used for later calls to other interfaces. Those interfaces will recognize that the application_id contains a dummy value and return without performing any action.
Error Code
Description
EFAULT
A parameter of this service contained an address that was not accessible to the caller.
EINVAL
A parameter of this service contained a value that was not valid.
EMVSARMERROR
An ARM error occurred. Refer to the return code for the specific error.
EPERM
The caller does not have the appropriate privileges. The return code is set to ARM_RC_AUTH_ERROR.
EMVSSAF2ERR
An error occurred in the security product.

Related information