XLIO
The NVIDIA® Accelerated IO
xlio_types.h File Reference

XLIO API type definitions and structures. More...

#include <stddef.h>
#include <stdint.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/time.h>

Go to the source code of this file.

Classes

struct  xlio_rate_limit_t
 
struct  xlio_ring_alloc_logic_attr
 
struct  xlio_buf
 Buffer descriptor. More...
 
struct  xlio_init_attr
 XLIO initialization attributes. More...
 
struct  xlio_poll_group_attr
 Polling group attributes. More...
 
struct  xlio_socket_attr
 Socket creation attributes. More...
 
struct  xlio_socket_send_attr
 Send operation attributes. More...
 

Macros

#define SO_XLIO_GET_API   2800
 
#define SO_XLIO_RING_ALLOC_LOGIC   2810
 
#define SO_XLIO_SHUTDOWN_RX   2821
 
#define SO_XLIO_EXT_VLAN_TAG   2824
 
#define XLIO_GROUP_FLAG_SAFE   0x1
 
#define XLIO_GROUP_FLAG_DIRTY   0x2
 
#define XLIO_SOCKET_SEND_FLAG_FLUSH   0x1
 
#define XLIO_SOCKET_SEND_FLAG_INLINE   0x2
 

Typedefs

typedef xlio_recv_callback_retval_t(* xlio_recv_callback_t) (int fd, size_t sz_iov, struct iovec iov[], struct xlio_info_t *xlio_info, void *context)
 
typedef uintptr_t xlio_poll_group_t
 Polling group handle. More...
 
typedef uintptr_t xlio_socket_t
 Socket handle. More...
 
typedef void(* xlio_memory_cb_t) (void *addr, size_t len, size_t hugepage_size)
 Memory allocation callback function. More...
 
typedef void(* xlio_socket_event_cb_t) (xlio_socket_t sock, uintptr_t userdata_sq, int event, int value)
 Socket event callback function. More...
 
typedef void(* xlio_socket_comp_cb_t) (xlio_socket_t sock, uintptr_t userdata_sq, uintptr_t userdata_op)
 Zero-copy completion callback function. More...
 
typedef void(* xlio_socket_rx_cb_t) (xlio_socket_t sock, uintptr_t userdata_sq, void *data, size_t len, struct xlio_buf *buf)
 Receive data callback function. More...
 
typedef void(* xlio_socket_accept_cb_t) (xlio_socket_t sock, xlio_socket_t parent, uintptr_t parent_userdata_sq)
 Accept callback function. More...
 

Enumerations

enum  xlio_recv_callback_retval_t { XLIO_PACKET_DROP , XLIO_PACKET_RECV , XLIO_PACKET_HOLD }
 
enum  ring_logic_t {
  RING_LOGIC_PER_INTERFACE = 0 , RING_LOGIC_PER_IP = 1 , RING_LOGIC_PER_SOCKET = 10 , RING_LOGIC_PER_USER_ID = 11 ,
  RING_LOGIC_PER_THREAD = 20 , RING_LOGIC_PER_CORE = 30 , RING_LOGIC_PER_CORE_ATTACH_THREADS = 31 , RING_LOGIC_PER_OBJECT = 32 ,
  RING_LOGIC_LAST
}
 
enum  xlio_ring_alloc_logic_attr_comp_mask { XLIO_RING_ALLOC_MASK_RING_USER_ID = (1 << 0) , XLIO_RING_ALLOC_MASK_RING_INGRESS = (1 << 1) , XLIO_RING_ALLOC_MASK_RING_ENGRESS = (1 << 2) }
 
enum  { XLIO_SOCKET_EVENT_ESTABLISHED = 1 , XLIO_SOCKET_EVENT_TERMINATED , XLIO_SOCKET_EVENT_CLOSED , XLIO_SOCKET_EVENT_ERROR }
 Socket events. More...
 

Functions

struct __attribute__ ((packed)) xlio_info_t
 

Detailed Description

XLIO API type definitions and structures.

This file contains all type definitions, structures, and constants used by the XLIO API.