#ifndef DEF_RDMA_VT_H
#define DEF_RDMA_VT_H
#include <linux/spinlock.h>
#include <linux/list.h>
#include <linux/hash.h>
#include <rdma/ib_verbs.h>
#include <rdma/ib_mad.h>
#include <rdma/rdmavt_mr.h>
#define RVT_MAX_PKEY_VALUES …
#define RVT_MAX_TRAP_LEN …
#define RVT_MAX_TRAP_LISTS …
#define RVT_TRAP_TIMEOUT …
struct trap_list { … };
struct rvt_qp;
struct rvt_qpn_table;
struct rvt_ibport { … };
#define RVT_CQN_MAX …
#define RVT_SGE_COPY_MEMCPY …
#define RVT_SGE_COPY_CACHELESS …
#define RVT_SGE_COPY_ADAPTIVE …
struct rvt_driver_params { … };
struct rvt_ucontext { … };
struct rvt_pd { … };
struct rvt_ah { … };
struct rvt_mmap_info { … };
struct rvt_wss { … };
struct rvt_dev_info;
struct rvt_swqe;
struct rvt_driver_provided { … };
struct rvt_dev_info { … };
static inline void rvt_set_ibdev_name(struct rvt_dev_info *rdi,
const char *fmt, const char *name,
const int unit)
{ … }
static inline const char *rvt_get_ibdev_name(const struct rvt_dev_info *rdi)
{ … }
static inline struct rvt_pd *ibpd_to_rvtpd(struct ib_pd *ibpd)
{ … }
static inline struct rvt_ah *ibah_to_rvtah(struct ib_ah *ibah)
{ … }
static inline struct rvt_dev_info *ib_to_rvt(struct ib_device *ibdev)
{ … }
static inline unsigned rvt_get_npkeys(struct rvt_dev_info *rdi)
{ … }
static inline unsigned int rvt_max_atomic(struct rvt_dev_info *rdi)
{ … }
static inline unsigned int rvt_size_atomic(struct rvt_dev_info *rdi)
{ … }
static inline u16 rvt_get_pkey(struct rvt_dev_info *rdi,
int port_index,
unsigned index)
{ … }
struct rvt_dev_info *rvt_alloc_device(size_t size, int nports);
void rvt_dealloc_device(struct rvt_dev_info *rdi);
int rvt_register_device(struct rvt_dev_info *rvd);
void rvt_unregister_device(struct rvt_dev_info *rvd);
int rvt_check_ah(struct ib_device *ibdev, struct rdma_ah_attr *ah_attr);
int rvt_init_port(struct rvt_dev_info *rdi, struct rvt_ibport *port,
int port_index, u16 *pkey_table);
int rvt_fast_reg_mr(struct rvt_qp *qp, struct ib_mr *ibmr, u32 key,
int access);
int rvt_invalidate_rkey(struct rvt_qp *qp, u32 rkey);
int rvt_rkey_ok(struct rvt_qp *qp, struct rvt_sge *sge,
u32 len, u64 vaddr, u32 rkey, int acc);
int rvt_lkey_ok(struct rvt_lkey_table *rkt, struct rvt_pd *pd,
struct rvt_sge *isge, struct rvt_sge *last_sge,
struct ib_sge *sge, int acc);
struct rvt_mcast *rvt_mcast_find(struct rvt_ibport *ibp, union ib_gid *mgid,
u16 lid);
#endif