} sock;
struct {
struct smb_direct_rdma_context context;
- struct rdma_cm_id *cm_id;
struct rdma_event_channel *cm_channel;
+ struct rdma_cm_id *cm_id;
struct tevent_fd *fde_channel;
enum rdma_cm_event_type expected_event;
struct rdma_cm_event *cm_event;
c->rdma.context.c = c;
+ c->ibv.init_attr.cap.max_send_wr = c->state.send_credit_target; // more for RDMA READ/WRITE??
+ c->ibv.init_attr.cap.max_recv_wr = c->state.receive_credit_max; // more for RDMA READ/WRITE??
+ c->ibv.init_attr.cap.max_recv_sge = 2;
+ c->ibv.init_attr.cap.max_send_sge = 2;
+ c->ibv.init_attr.qp_type = IBV_QPT_RC;
+ c->ibv.init_attr.sq_sig_all = 1;
+
//DEBUG(0,("%s:%s: here...\n", __location__, __func__));
return c;
}
int ret;
uint16_t i;
-//DEBUG(0,("%s:%s: here...\n", __location__, __func__));
- c->ibv.pd = ibv_alloc_pd(c->rdma.cm_id->verbs);
- if (c->ibv.pd == NULL) {
-DEBUG(0,("%s:%s: here...\n", __location__, __func__));
- return NT_STATUS_NO_MEMORY;
- }
-
c->ibv.comp_channel = ibv_create_comp_channel(c->rdma.cm_id->verbs);
if (c->ibv.comp_channel == NULL) {
DEBUG(0,("%s:%s: here...\n", __location__, __func__));
smb_set_close_on_exec(c->ibv.comp_channel->fd);
set_blocking(c->ibv.comp_channel->fd, false);
- c->ibv.init_attr.cap.max_send_wr = c->state.send_credit_target; // more for RDMA READ/WRITE??
- c->ibv.init_attr.cap.max_recv_wr = c->state.receive_credit_max; // more for RDMA READ/WRITE??
- c->ibv.init_attr.cap.max_recv_sge = 2;
- c->ibv.init_attr.cap.max_send_sge = 2;
- c->ibv.init_attr.qp_type = IBV_QPT_RC;
- c->ibv.init_attr.sq_sig_all = 1;
+//DEBUG(0,("%s:%s: here...\n", __location__, __func__));
+ c->ibv.pd = ibv_alloc_pd(c->rdma.cm_id->verbs);
+ if (c->ibv.pd == NULL) {
+DEBUG(0,("%s:%s: here...\n", __location__, __func__));
+ return NT_STATUS_NO_MEMORY;
+ }
c->ibv.send_cq = ibv_create_cq(c->rdma.cm_id->verbs,
c->ibv.init_attr.cap.max_send_wr,
int ret;
errno = 0;
-
ret = rdma_get_cm_event(c->rdma.cm_channel,
&c->rdma.cm_event);
if (ret != 0) {
int ret;
errno = 0;
-
ret = rdma_get_cm_event(c->rdma.cm_channel,
&c->rdma.cm_event);
if (ret != 0) {