CDI SDK
SDK for transporting chunks of data reliably and with low latency using a polled mode network driver.
Loading...
Searching...
No Matches
adapter_efa.h File Reference

The declarations in this header file correspond to the definitions in adapter_efa.c. More...

#include "adapter_api.h"
#include "adapter_control_interface.h"
#include "adapter_efa_probe.h"
#include "cdi_raw_api.h"
#include "private.h"
#include "rdma/fabric.h"
#include "rdma/fi_cm.h"
#include "rdma/fi_endpoint.h"

Go to the source code of this file.

Data Structures

struct  LibfabricApi
 V-table interface to the libfabric API. This allows multiple versions of libfabric to be used within this SDK. More...
 
struct  EfaTxState
 This defines a structure that contains all of the state information that is specific to the Tx side of a single EFA endpoint. More...
 
struct  EfaRxState
 This defines a structure that contains all of the state information that is specific to the Rx side of a single EFA endpoint. More...
 
struct  EfaEndpointState
 Structure used to hold EFA endpoint state data. More...
 
struct  EfaConnectionState
 Structure used to hold EFA connection state data. More...
 

Functions

CdiReturnStatus EfaAdapterProbeEndpointCreate (EfaEndpointState *endpoint_ptr, ProbeEndpointHandle *ret_probe_handle)
 
CdiReturnStatus EfaAdapterEndpointStart (EfaEndpointState *endpoint_ptr)
 
CdiAdapterHandle EfaAdapterGetAdapterControlInterface (AdapterConnectionState *adapter_con_state_ptr)
 
CdiReturnStatus EfaTxEndpointOpen (EfaEndpointState *endpoint_ptr, const char *remote_address_str, int dest_port)
 
CdiReturnStatus EfaTxEndpointPoll (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaTxEndpointReset (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaTxEndpointClose (EfaEndpointState *endpoint_ptr)
 
EndpointTransmitQueueLevel EfaGetTransmitQueueLevel (const AdapterEndpointHandle handle)
 
CdiReturnStatus EfaTxEndpointSend (const AdapterEndpointHandle handle, const Packet *packet_ptr, bool flush_packets)
 
CdiReturnStatus EfaTxEndpointStart (EfaEndpointState *endpoint_ptr)
 
void EfaTxEndpointStop (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaRxEndpointOpen (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaRxEndpointPoll (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaRxEndpointReset (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaRxEndpointClose (EfaEndpointState *endpoint_ptr)
 
CdiReturnStatus EfaRxEndpointRxBuffersFree (const AdapterEndpointHandle handle, const CdiSgList *sgl_ptr)
 
CdiReturnStatus EfaRxPacketPoolCreate (EfaEndpointState *endpoint_state_ptr)
 
void EfaRxPacketPoolFree (EfaEndpointState *endpoint_ptr)
 
bool EfaAdapterEndpointProtocolVersionSet (EfaEndpointState *endpoint_ptr, const CdiProtocolVersionNumber *remote_version_ptr)
 Set the protocol version for the specified endpoint. The protocol version actually used is negotiated using the specified remote version and the current version of the CDI-SDK.
 

Detailed Description

The declarations in this header file correspond to the definitions in adapter_efa.c.

Function Documentation

◆ EfaAdapterEndpointProtocolVersionSet()

bool EfaAdapterEndpointProtocolVersionSet ( EfaEndpointState * endpoint_ptr,
const CdiProtocolVersionNumber * remote_version_ptr )

Set the protocol version for the specified endpoint. The protocol version actually used is negotiated using the specified remote version and the current version of the CDI-SDK.

Parameters
endpoint_ptrPointer to endpoint.
remote_version_ptrPointer to remote protocol version data.
Returns
True if successful, otherwise false is returned.

◆ EfaAdapterEndpointStart()

CdiReturnStatus EfaAdapterEndpointStart ( EfaEndpointState * endpoint_ptr)

Start the specified endpoint. This only allocates and starts low-level libfabric and EFA device driver resources. Other resources have already been created and started when the connection was created.

Parameters
endpoint_ptrPointer to the EFA endpoint to start.
Returns
kCdiStatusOk if successful, otherwise a value that indicates the nature of the failure is returned.

◆ EfaAdapterGetAdapterControlInterface()

CdiAdapterHandle EfaAdapterGetAdapterControlInterface ( AdapterConnectionState * adapter_con_state_ptr)

Get handle of adapter control inteface related to the specified EFA endpoint.

Parameters
adapter_con_state_ptrPointer to adapter connection state data.
Returns
Handle of control interface adapter.

◆ EfaAdapterProbeEndpointCreate()

CdiReturnStatus EfaAdapterProbeEndpointCreate ( EfaEndpointState * endpoint_ptr,
ProbeEndpointHandle * ret_probe_handle )

Create probe for the specified EFA endpoint.

Parameters
endpoint_ptrPointer to the adapter endpoint to create a probe for.
ret_probe_handlePointer to returned probe handle.
Returns
kCdiStatusOk if successful, otherwise a value that indicates the nature of the failure is returned.

◆ EfaGetTransmitQueueLevel()

EndpointTransmitQueueLevel EfaGetTransmitQueueLevel ( const AdapterEndpointHandle handle)

◆ EfaRxEndpointClose()

CdiReturnStatus EfaRxEndpointClose ( EfaEndpointState * endpoint_ptr)

◆ EfaRxEndpointOpen()

CdiReturnStatus EfaRxEndpointOpen ( EfaEndpointState * endpoint_ptr)

◆ EfaRxEndpointPoll()

CdiReturnStatus EfaRxEndpointPoll ( EfaEndpointState * endpoint_ptr)

◆ EfaRxEndpointReset()

CdiReturnStatus EfaRxEndpointReset ( EfaEndpointState * endpoint_ptr)

◆ EfaRxEndpointRxBuffersFree()

CdiReturnStatus EfaRxEndpointRxBuffersFree ( const AdapterEndpointHandle handle,
const CdiSgList * sgl_ptr )

◆ EfaRxPacketPoolCreate()

CdiReturnStatus EfaRxPacketPoolCreate ( EfaEndpointState * endpoint_state_ptr)

Create pool of Rx packet buffers for the endpoint.

Parameters
endpoint_state_ptrPointer to endpoint.
Returns
kCdiStatusOk if successful, otherwise a value that indicates the nature of the failure is returned.

◆ EfaRxPacketPoolFree()

void EfaRxPacketPoolFree ( EfaEndpointState * endpoint_ptr)

Frees the previously allocated receive packet buffer pool for the endpoint.

Parameters
endpoint_ptrPointer to EFA endpoint state data.

◆ EfaTxEndpointClose()

CdiReturnStatus EfaTxEndpointClose ( EfaEndpointState * endpoint_ptr)

◆ EfaTxEndpointOpen()

CdiReturnStatus EfaTxEndpointOpen ( EfaEndpointState * endpoint_ptr,
const char * remote_address_str,
int dest_port )

◆ EfaTxEndpointPoll()

CdiReturnStatus EfaTxEndpointPoll ( EfaEndpointState * endpoint_ptr)

◆ EfaTxEndpointReset()

CdiReturnStatus EfaTxEndpointReset ( EfaEndpointState * endpoint_ptr)

◆ EfaTxEndpointSend()

CdiReturnStatus EfaTxEndpointSend ( const AdapterEndpointHandle handle,
const Packet * packet_ptr,
bool flush_packets )

◆ EfaTxEndpointStart()

CdiReturnStatus EfaTxEndpointStart ( EfaEndpointState * endpoint_ptr)

◆ EfaTxEndpointStop()

void EfaTxEndpointStop ( EfaEndpointState * endpoint_ptr)