[openib-general] [PATCH] defined struct ib_mw_bind
Sean Hefty
mshefty at ichips.intel.com
Tue Aug 10 16:20:36 PDT 2004
Here's a patch that defines ib_mw_bind. Rather than defining yet another set of flags, I combined the MR, QP, and MW memory access flags together. I will submit a second patch to update Roland's tree, to keep mthca in sync with this change.
The change has not been submitted yet.
- Sean
-- Index: ib_verbs.h
===================================================================
--- ib_verbs.h (revision 626)
+++ ib_verbs.h (working copy)
@@ -326,10 +326,23 @@
u8 port_num; /* special QP types only */
};
-enum ib_qp_access_flags {
- IB_QP_REMOTE_WRITE = (1<<1),
- IB_QP_REMOTE_READ = (1<<2),
- IB_QP_REMOTE_ATOMIC = (1<<3)
+/**
+ * ib_access_flags - Memory access flags for memory regions, memory windows,
+ * and queue pairs.
+ * @IB_ACCESS_REMOTE_WRITE - Enabled for remote RDMA writes.
+ * @IB_ACCESS_REMOTE_READ - Enabled for remote RDMA reads.
+ * @IB_ACCESS_REMOTE_ATOMIC - Enabled for remote atomic operations.
+ * @IB_ACCESS_LOCAL_WRITE - Enabled for write access by the local device.
+ * Applies to memory regions only.
+ * @IB_ACCESS_MW_BIND - Enabled for memory window bind operations. Applies
+ * to memory regions only.
+ */
+enum ib_access_flags {
+ IB_ACCESS_REMOTE_WRITE = 1,
+ IB_ACCESS_REMOTE_READ = (1<<1),
+ IB_ACCESS_REMOTE_ATOMIC = (1<<2),
+ IB_ACCESS_LOCAL_WRITE = (1<<3),
+ IB_ACCESS_MW_BIND = (1<<4)
};
enum ib_qp_attr_mask {
@@ -446,14 +459,6 @@
int srq_limit;
};
-enum ib_mr_access_flags {
- IB_MR_LOCAL_WRITE = 1,
- IB_MR_REMOTE_WRITE = (1<<1),
- IB_MR_REMOTE_READ = (1<<2),
- IB_MR_REMOTE_ATOMIC = (1<<3),
- IB_MR_MW_BIND = (1<<4)
-};
-
struct ib_phys_buf {
u64 addr;
u64 size;
@@ -471,7 +476,14 @@
IB_MR_REREG_ACCESS = (1<<2)
};
-struct ib_mw_bind;
+struct ib_mw_bind {
+ struct *ib_mr;
+ u64 wr_id;
+ u64 addr;
+ u32 length;
+ int send_flags;
+ int mw_access_flags;
+};
struct ib_fmr_attr {
int max_pages;
More information about the general
mailing list