diff mbox series

[v3,03/17] ib_user_verbs.h: Added ib_uverbs_wc_opcode

Message ID 20200820224638.3212-4-rpearson@hpe.com (mailing list archive)
State Changes Requested
Delegated to: Jason Gunthorpe
Headers show
Series Memory window support for rdma_rxe | expand

Commit Message

Bob Pearson Aug. 20, 2020, 10:46 p.m. UTC
This enum plays the same role as ib_uverbs_wr_opcode documenting
the opcodes in the user space API. It plays a role for software
drivers like rxe.

Signed-off-by: Bob Pearson <rpearson@hpe.com>
---
 include/uapi/rdma/ib_user_verbs.h | 11 +++++++++++
 1 file changed, 11 insertions(+)

Comments

Jason Gunthorpe Aug. 27, 2020, 12:53 p.m. UTC | #1
On Thu, Aug 20, 2020 at 05:46:24PM -0500, Bob Pearson wrote:
> This enum plays the same role as ib_uverbs_wr_opcode documenting
> the opcodes in the user space API. It plays a role for software
> drivers like rxe.

It should be done like the WR then:

include/rdma/ib_verbs.h:        IB_WR_LOCAL_INV = IB_UVERBS_WR_LOCAL_INV,

One copy of the value only

Jason
diff mbox series

Patch

diff --git a/include/uapi/rdma/ib_user_verbs.h b/include/uapi/rdma/ib_user_verbs.h
index 0474c7400268..456438c18c2c 100644
--- a/include/uapi/rdma/ib_user_verbs.h
+++ b/include/uapi/rdma/ib_user_verbs.h
@@ -457,6 +457,17 @@  struct ib_uverbs_poll_cq {
 	__u32 ne;
 };
 
+enum ib_uverbs_wc_opcode {
+	IB_UVERBS_WC_SEND = 0,
+	IB_UVERBS_WC_RDMA_WRITE = 1,
+	IB_UVERBS_WC_RDMA_READ = 2,
+	IB_UVERBS_WC_COMP_SWAP = 3,
+	IB_UVERBS_WC_FETCH_ADD = 4,
+	IB_UVERBS_WC_BIND_MW = 5,
+	IB_UVERBS_WC_LOCAL_INV = 6,
+	IB_UVERBS_WC_TSO = 7,
+};
+
 struct ib_uverbs_wc {
 	__aligned_u64 wr_id;
 	__u32 status;