[PATCH rdma-core 11/20] cxgb4: Use kernel uapi headers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Jason Gunthorpe <jgg@xxxxxxxxxxxx>

cxgb just had one enum that trivially duplicates, but needed to have
the structs renamed to avoid conflicts

Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxxxx>
---
 providers/cxgb4/cxgb4-abi.h | 15 ++++++---------
 providers/cxgb4/dev.c       |  2 +-
 providers/cxgb4/verbs.c     |  8 ++++----
 3 files changed, 11 insertions(+), 14 deletions(-)

diff --git a/providers/cxgb4/cxgb4-abi.h b/providers/cxgb4/cxgb4-abi.h
index b18d03d25907f9..f69894f73481e6 100644
--- a/providers/cxgb4/cxgb4-abi.h
+++ b/providers/cxgb4/cxgb4-abi.h
@@ -34,20 +34,21 @@
 
 #include <stdint.h>
 #include <infiniband/kern-abi.h>
+#include <rdma/cxgb4-abi.h>
 
-struct c4iw_alloc_ucontext_resp {
+struct uc4iw_alloc_ucontext_resp {
 	struct ib_uverbs_get_context_resp ibv_resp;
 	__u64 status_page_key;
 	__u32 status_page_size;
 	__u32 reserved;
 };
 
-struct c4iw_alloc_pd_resp {
+struct uc4iw_alloc_pd_resp {
 	struct ib_uverbs_alloc_pd_resp ibv_resp;
 	uint32_t pdid;
 };
 
-struct c4iw_create_cq_resp {
+struct uc4iw_create_cq_resp {
 	struct ib_uverbs_create_cq_resp ibv_resp;
 	__u64 key;
 	__u64 gts_key;
@@ -58,11 +59,7 @@ struct c4iw_create_cq_resp {
 	__u32 reserved;
 };
 
-enum {
-	C4IW_QPF_ONCHIP = (1<<0),
-};
-
-struct c4iw_create_qp_resp_v0 {
+struct uc4iw_create_qp_resp_v0 {
 	struct ib_uverbs_create_qp_resp ibv_resp;
 	__u64 sq_key;
 	__u64 rq_key;
@@ -77,7 +74,7 @@ struct c4iw_create_qp_resp_v0 {
 	__u32 qid_mask;
 };
 
-struct c4iw_create_qp_resp {
+struct uc4iw_create_qp_resp {
 	struct ib_uverbs_create_qp_resp ibv_resp;
 	__u64 ma_sync_key;
 	__u64 sq_key;
diff --git a/providers/cxgb4/dev.c b/providers/cxgb4/dev.c
index b1eeb528949efc..b1870219f35f67 100644
--- a/providers/cxgb4/dev.c
+++ b/providers/cxgb4/dev.c
@@ -109,7 +109,7 @@ static struct verbs_context *c4iw_alloc_context(struct ibv_device *ibdev,
 {
 	struct c4iw_context *context;
 	struct ibv_get_context cmd;
-	struct c4iw_alloc_ucontext_resp resp;
+	struct uc4iw_alloc_ucontext_resp resp;
 	struct c4iw_dev *rhp = to_c4iw_dev(ibdev);
 	struct ibv_query_device qcmd;
 	uint64_t raw_fw_ver;
diff --git a/providers/cxgb4/verbs.c b/providers/cxgb4/verbs.c
index 4e6cdbc2d114f6..b50a37b2771090 100644
--- a/providers/cxgb4/verbs.c
+++ b/providers/cxgb4/verbs.c
@@ -79,7 +79,7 @@ int c4iw_query_port(struct ibv_context *context, uint8_t port,
 struct ibv_pd *c4iw_alloc_pd(struct ibv_context *context)
 {
 	struct ibv_alloc_pd cmd;
-	struct c4iw_alloc_pd_resp resp;
+	struct uc4iw_alloc_pd_resp resp;
 	struct c4iw_pd *pd;
 
 	pd = malloc(sizeof *pd);
@@ -168,7 +168,7 @@ int c4iw_dereg_mr(struct ibv_mr *mr)
 struct ibv_cq *c4iw_create_cq(struct ibv_context *context, int cqe,
 			      struct ibv_comp_channel *channel, int comp_vector)
 {
-	struct c4iw_create_cq_resp resp;
+	struct uc4iw_create_cq_resp resp;
 	struct c4iw_cq *chp;
 	struct c4iw_dev *dev = to_c4iw_dev(context->device);
 	int ret;
@@ -303,7 +303,7 @@ static struct ibv_qp *create_qp_v0(struct ibv_pd *pd,
 				   struct ibv_qp_init_attr *attr)
 {
 	struct ibv_create_qp cmd;
-	struct c4iw_create_qp_resp_v0 resp;
+	struct uc4iw_create_qp_resp_v0 resp;
 	struct c4iw_qp *qhp;
 	struct c4iw_dev *dev = to_c4iw_dev(pd->context->device);
 	int ret;
@@ -406,7 +406,7 @@ static struct ibv_qp *create_qp(struct ibv_pd *pd,
 				struct ibv_qp_init_attr *attr)
 {
 	struct ibv_create_qp cmd;
-	struct c4iw_create_qp_resp resp;
+	struct uc4iw_create_qp_resp resp;
 	struct c4iw_qp *qhp;
 	struct c4iw_dev *dev = to_c4iw_dev(pd->context->device);
 	struct c4iw_context *ctx = to_c4iw_context(pd->context);
-- 
2.16.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux