summaryrefslogtreecommitdiff
path: root/drivers/net/mlx5/mlx5_mr.c
diff options
context:
space:
mode:
authorNĂ©lio Laranjeiro <nelio.laranjeiro@6wind.com>2016-06-24 15:17:53 +0200
committerBruce Richardson <bruce.richardson@intel.com>2016-06-27 16:17:52 +0200
commit1d88ba1719429c1e41bd61ab3add65ad9cc43551 (patch)
tree8b008b184b2f2e2d39ff7785d9ac6734c4ab26df /drivers/net/mlx5/mlx5_mr.c
parent6218063b39a605f904213dd70b8624d535c07394 (diff)
downloaddpdk-next-eventdev-1d88ba1719429c1e41bd61ab3add65ad9cc43551.zip
dpdk-next-eventdev-1d88ba1719429c1e41bd61ab3add65ad9cc43551.tar.gz
dpdk-next-eventdev-1d88ba1719429c1e41bd61ab3add65ad9cc43551.tar.xz
net/mlx5: refactor Tx data path
Bypass Verbs to improve Tx performance. Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com> Signed-off-by: Yaacov Hazan <yaacovh@mellanox.com> Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Diffstat (limited to 'drivers/net/mlx5/mlx5_mr.c')
-rw-r--r--drivers/net/mlx5/mlx5_mr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/mlx5/mlx5_mr.c b/drivers/net/mlx5/mlx5_mr.c
index 1d8bf72..67dfefa 100644
--- a/drivers/net/mlx5/mlx5_mr.c
+++ b/drivers/net/mlx5/mlx5_mr.c
@@ -190,7 +190,7 @@ txq_mp2mr_reg(struct txq *txq, struct rte_mempool *mp, unsigned int idx)
/* Add a new entry, register MR first. */
DEBUG("%p: discovered new memory pool \"%s\" (%p)",
(void *)txq_ctrl, mp->name, (void *)mp);
- mr = mlx5_mp2mr(txq_ctrl->txq.priv->pd, mp);
+ mr = mlx5_mp2mr(txq_ctrl->priv->pd, mp);
if (unlikely(mr == NULL)) {
DEBUG("%p: unable to configure MR, ibv_reg_mr() failed.",
(void *)txq_ctrl);
@@ -209,7 +209,7 @@ txq_mp2mr_reg(struct txq *txq, struct rte_mempool *mp, unsigned int idx)
/* Store the new entry. */
txq_ctrl->txq.mp2mr[idx].mp = mp;
txq_ctrl->txq.mp2mr[idx].mr = mr;
- txq_ctrl->txq.mp2mr[idx].lkey = mr->lkey;
+ txq_ctrl->txq.mp2mr[idx].lkey = htonl(mr->lkey);
DEBUG("%p: new MR lkey for MP \"%s\" (%p): 0x%08" PRIu32,
(void *)txq_ctrl, mp->name, (void *)mp,
txq_ctrl->txq.mp2mr[idx].lkey);