summaryrefslogtreecommitdiffstats
path: root/net/rds/ib_mr.h
diff options
context:
space:
mode:
authorsantosh.shilimkar@oracle.com <santosh.shilimkar@oracle.com>2016-03-02 00:20:47 +0100
committerDavid S. Miller <davem@davemloft.net>2016-03-02 20:13:18 +0100
commita69365a39cd35d0ad11be7d4a896b2f76a8fde44 (patch)
treeaaa8cf406bd5e21c6fc1cbba9a4efd63e3b146df /net/rds/ib_mr.h
parentRDS: IB: Re-organise ibmr code (diff)
downloadlinux-a69365a39cd35d0ad11be7d4a896b2f76a8fde44.tar.xz
linux-a69365a39cd35d0ad11be7d4a896b2f76a8fde44.zip
RDS: IB: create struct rds_ib_fmr
Keep fmr related filed in its own struct. Fastreg MR structure will be added to the union. Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org> Signed-off-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/rds/ib_mr.h')
-rw-r--r--net/rds/ib_mr.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/net/rds/ib_mr.h b/net/rds/ib_mr.h
index d88724fe9a0b..309ad59bf218 100644
--- a/net/rds/ib_mr.h
+++ b/net/rds/ib_mr.h
@@ -43,11 +43,15 @@
#define RDS_MR_8K_SCALE (256 / (RDS_MR_8K_MSG_SIZE + 1))
#define RDS_MR_8K_POOL_SIZE (RDS_MR_8K_SCALE * (8192 / 2))
+struct rds_ib_fmr {
+ struct ib_fmr *fmr;
+ u64 *dma;
+};
+
/* This is stored as mr->r_trans_private. */
struct rds_ib_mr {
struct rds_ib_device *device;
struct rds_ib_mr_pool *pool;
- struct ib_fmr *fmr;
struct llist_node llnode;
@@ -57,8 +61,11 @@ struct rds_ib_mr {
struct scatterlist *sg;
unsigned int sg_len;
- u64 *dma;
int sg_dma_len;
+
+ union {
+ struct rds_ib_fmr fmr;
+ } u;
};
/* Our own little MR pool */