sol_ucma.h revision c39526b769298791ff5b0b6c5e761f49aabaeb4e
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*/
/*
* This is the Solaris uCMA header file. This contains Solaris specific
* data structures and defines for the sol_ucma driver.
*/
#ifdef __cplusplus
extern "C" {
#endif
/*
* MAX Number of PATHS supported. This is the same as
* supported by RDMA CM library API revisit - TBD
*
* MAX Number of Listens supported
*/
#define SOL_UCMA_MAX_PATHS 2
#define SOL_UCMA_MAX_LISTEN 128
/* Defines for file_evt_close_flag */
#define SOL_UCMA_EVT_NONE 0x00
#define SOL_UCMA_EVT_PROGRESS 0x01
#define SOL_UCMA_EVT_DISABLED 0x02
/*
* RDMA-CM Event File structure
*/
typedef struct {
/*
* Events data
* pollhead - for chpoll(9e)
* event_cv - for blocking wait at GET_EVENT
* evt_list - List of Events
* pending_evt_cnt - Pending Events to be pushed
* to userland.
*/
struct pollhead *file_pollhead;
typedef enum {
/*
* Structure for each IDs created using rdma_create_id()
*/
#define SOL_UCMA_CHAN_CONNECT_FLAG 0x01
typedef struct {
/* Channel id and user ID for this Channel */
/* Total events for this channel */
/* rdma_cm_id for this channel */
struct rdma_cm_id *chan_rdma_id;
void *chan_qp_hdl;
/* Flush QP flag for this channel */
int chan_backlog;
typedef struct sol_ucma_mcast_s {
struct sockaddr mcast_addr;
/*
* UCMA Event Structure
*/
typedef struct sol_ucma_event_s {
/*
* Global structure for Solaris UCMA Driver.
*/
#define SOL_UCMA_CLNT_HDL_UNINITIALIZED 0x00
#define SOL_UCMA_CLNT_HDL_INITIALIZING 0x01
#define SOL_UCMA_CLNT_HDL_INITIALIZED 0x02
typedef struct sol_ucma_s {
void *ucma_ib_clnt_hdl;
void *ucma_iw_clnt_hdl;
/* Client Handle flag */
} sol_ucma_t;
#ifdef __cplusplus
}
#endif
#endif /* _SYS_IB_CLIENTS_OF_SOL_UCMA_SOL_UCMA_H */