From: Tziporet Koren Date: Mon, 15 May 2006 08:02:39 +0000 (+0000) Subject: r7164: OFED RC5 userspace mods X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=0480a387e46ccaa445c90ea45a77e28ff9490b85;p=~shefty%2Flibibcm.git r7164: OFED RC5 userspace mods --- diff --git a/examples/cmpost.c b/examples/cmpost.c index 5fa3f89..f5f1109 100644 --- a/examples/cmpost.c +++ b/examples/cmpost.c @@ -62,7 +62,7 @@ struct cmtest { struct ibv_pd *pd; /* cm info */ - struct ib_sa_path_rec path_rec; + struct ibv_sa_path_rec path_rec; struct cmtest_node *nodes; int conn_index; diff --git a/include/infiniband/cm.h b/include/infiniband/cm.h index c57e145..6948965 100644 --- a/include/infiniband/cm.h +++ b/include/infiniband/cm.h @@ -93,8 +93,8 @@ struct ib_cm_req_event_param { struct ib_cm_id *listen_id; uint8_t port; - struct ib_sa_path_rec *primary_path; - struct ib_sa_path_rec *alternate_path; + struct ibv_sa_path_rec *primary_path; + struct ibv_sa_path_rec *alternate_path; uint64_t remote_ca_guid; uint32_t remote_qkey; @@ -173,7 +173,7 @@ struct ib_cm_mra_event_param { }; struct ib_cm_lap_event_param { - struct ib_sa_path_rec *alternate_path; + struct ibv_sa_path_rec *alternate_path; }; enum ib_cm_apr_status { @@ -332,8 +332,8 @@ int ib_cm_listen(struct ib_cm_id *cm_id, uint64_t service_mask); struct ib_cm_req_param { - struct ib_sa_path_rec *primary_path; - struct ib_sa_path_rec *alternate_path; + struct ibv_sa_path_rec *primary_path; + struct ibv_sa_path_rec *alternate_path; uint64_t service_id; uint32_t qp_num; enum ibv_qp_type qp_type; @@ -478,7 +478,7 @@ int ib_cm_send_mra(struct ib_cm_id *cm_id, * @private_data_len: Size of the private data buffer, in bytes. */ int ib_cm_send_lap(struct ib_cm_id *cm_id, - struct ib_sa_path_rec *alternate_path, + struct ibv_sa_path_rec *alternate_path, void *private_data, uint8_t private_data_len); @@ -522,7 +522,7 @@ int ib_cm_send_apr(struct ib_cm_id *cm_id, uint8_t private_data_len); struct ib_cm_sidr_req_param { - struct ib_sa_path_rec *path; + struct ibv_sa_path_rec *path; uint64_t service_id; int timeout_ms; void *private_data; diff --git a/include/infiniband/cm_abi.h b/include/infiniband/cm_abi.h index a3c698c..f3653ea 100644 --- a/include/infiniband/cm_abi.h +++ b/include/infiniband/cm_abi.h @@ -237,8 +237,8 @@ struct cm_abi_event_get { }; struct cm_abi_req_event_resp { - struct ib_kern_path_rec primary_path; - struct ib_kern_path_rec alternate_path; + struct ibv_kern_path_rec primary_path; + struct ibv_kern_path_rec alternate_path; __u64 remote_ca_guid; __u32 remote_qkey; __u32 remote_qpn; @@ -282,7 +282,7 @@ struct cm_abi_mra_event_resp { }; struct cm_abi_lap_event_resp { - struct ib_kern_path_rec path; + struct ibv_kern_path_rec path; }; struct cm_abi_apr_event_resp { diff --git a/src/cm.c b/src/cm.c index a9420e3..f6105db 100644 --- a/src/cm.c +++ b/src/cm.c @@ -403,7 +403,7 @@ int ib_cm_init_qp_attr(struct ib_cm_id *cm_id, return (result > 0) ? -ENODATA : result; *qp_attr_mask = resp->qp_attr_mask; - ib_copy_qp_attr_from_kern(qp_attr, resp); + ibv_copy_qp_attr_from_kern(qp_attr, resp); return 0; } @@ -431,8 +431,8 @@ int ib_cm_listen(struct ib_cm_id *cm_id, int ib_cm_send_req(struct ib_cm_id *cm_id, struct ib_cm_req_param *param) { - struct ib_kern_path_rec *p_path; - struct ib_kern_path_rec *a_path; + struct ibv_kern_path_rec *p_path; + struct ibv_kern_path_rec *a_path; struct cm_abi_req *cmd; void *msg; int result; @@ -463,7 +463,7 @@ int ib_cm_send_req(struct ib_cm_id *cm_id, struct ib_cm_req_param *param) if (!p_path) return -ENOMEM; - ib_copy_path_rec_to_kern(p_path, param->primary_path); + ibv_copy_path_rec_to_kern(p_path, param->primary_path); cmd->primary_path = (uintptr_t) p_path; } @@ -472,7 +472,7 @@ int ib_cm_send_req(struct ib_cm_id *cm_id, struct ib_cm_req_param *param) if (!a_path) return -ENOMEM; - ib_copy_path_rec_to_kern(a_path, param->alternate_path); + ibv_copy_path_rec_to_kern(a_path, param->alternate_path); cmd->alternate_path = (uintptr_t) a_path; } @@ -674,11 +674,11 @@ int ib_cm_send_mra(struct ib_cm_id *cm_id, } int ib_cm_send_lap(struct ib_cm_id *cm_id, - struct ib_sa_path_rec *alternate_path, + struct ibv_sa_path_rec *alternate_path, void *private_data, uint8_t private_data_len) { - struct ib_kern_path_rec *abi_path; + struct ibv_kern_path_rec *abi_path; struct cm_abi_lap *cmd; void *msg; int result; @@ -692,7 +692,7 @@ int ib_cm_send_lap(struct ib_cm_id *cm_id, if (!abi_path) return -ENOMEM; - ib_copy_path_rec_to_kern(abi_path, alternate_path); + ibv_copy_path_rec_to_kern(abi_path, alternate_path); cmd->path = (uintptr_t) abi_path; } @@ -711,7 +711,7 @@ int ib_cm_send_lap(struct ib_cm_id *cm_id, int ib_cm_send_sidr_req(struct ib_cm_id *cm_id, struct ib_cm_sidr_req_param *param) { - struct ib_kern_path_rec *abi_path; + struct ibv_kern_path_rec *abi_path; struct cm_abi_sidr_req *cmd; void *msg; int result; @@ -732,7 +732,7 @@ int ib_cm_send_sidr_req(struct ib_cm_id *cm_id, if (!abi_path) return -ENOMEM; - ib_copy_path_rec_to_kern(abi_path, param->path); + ibv_copy_path_rec_to_kern(abi_path, param->path); cmd->path = (uintptr_t) abi_path; } @@ -800,10 +800,10 @@ static void cm_event_req_get(struct ib_cm_req_event_param *ureq, ureq->srq = kreq->srq; ureq->port = kreq->port; - ib_copy_path_rec_from_kern(ureq->primary_path, &kreq->primary_path); + ibv_copy_path_rec_from_kern(ureq->primary_path, &kreq->primary_path); if (ureq->alternate_path) - ib_copy_path_rec_from_kern(ureq->alternate_path, - &kreq->alternate_path); + ibv_copy_path_rec_from_kern(ureq->alternate_path, + &kreq->alternate_path); } static void cm_event_rep_get(struct ib_cm_rep_event_param *urep, @@ -837,8 +837,8 @@ int ib_cm_get_event(struct ib_cm_device *device, struct ib_cm_event **event) struct cm_abi_event_get *cmd; struct cm_abi_event_resp *resp; struct ib_cm_event *evt = NULL; - struct ib_sa_path_rec *path_a = NULL; - struct ib_sa_path_rec *path_b = NULL; + struct ibv_sa_path_rec *path_a = NULL; + struct ibv_sa_path_rec *path_b = NULL; void *data = NULL; void *info = NULL; void *msg; @@ -947,8 +947,8 @@ int ib_cm_get_event(struct ib_cm_device *device, struct ib_cm_event **event) case IB_CM_LAP_RECEIVED: evt->param.lap_rcvd.alternate_path = path_b; path_b = NULL; - ib_copy_path_rec_from_kern(evt->param.lap_rcvd.alternate_path, - &resp->u.lap_resp.path); + ibv_copy_path_rec_from_kern(evt->param.lap_rcvd.alternate_path, + &resp->u.lap_resp.path); break; case IB_CM_APR_RECEIVED: evt->param.apr_rcvd.ap_status = resp->u.apr_resp.status;