aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorHans Petter Selasky <hselasky@FreeBSD.org>2019-10-02 10:25:47 +0000
committerHans Petter Selasky <hselasky@FreeBSD.org>2019-10-02 10:25:47 +0000
commita2d65bfd8f80771a008e3a1a6176656d1e237c13 (patch)
tree2ea6a4adb1b839677a602185fde3f6260c09a3df /sys
parent3e40712eb06c347951a62ce89f1abc01c38e32a0 (diff)
downloadsrc-a2d65bfd8f80771a008e3a1a6176656d1e237c13.tar.gz
src-a2d65bfd8f80771a008e3a1a6176656d1e237c13.zip
Remove mkey_be from channel structure in mlx5en(4).
Use value from priv structure instead. This saves some space in the channel structure. MFC after: 3 days Sponsored by: Mellanox Technologies
Notes
Notes: svn path=/head/; revision=352987
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/mlx5/mlx5_en/en.h1
-rw-r--r--sys/dev/mlx5/mlx5_en/mlx5_en_main.c5
2 files changed, 2 insertions, 4 deletions
diff --git a/sys/dev/mlx5/mlx5_en/en.h b/sys/dev/mlx5/mlx5_en/en.h
index 67485407866d..6ed9cc33a5f3 100644
--- a/sys/dev/mlx5/mlx5_en/en.h
+++ b/sys/dev/mlx5/mlx5_en/en.h
@@ -863,7 +863,6 @@ struct mlx5e_channel {
struct mlx5e_rq rq;
struct mlx5e_snd_tag tag;
struct mlx5e_sq sq[MLX5E_MAX_TX_NUM_TC];
- u32 mkey_be;
u8 num_tc;
/* control */
diff --git a/sys/dev/mlx5/mlx5_en/mlx5_en_main.c b/sys/dev/mlx5/mlx5_en/mlx5_en_main.c
index 0d41eef2e6e4..82dec1cff477 100644
--- a/sys/dev/mlx5/mlx5_en/mlx5_en_main.c
+++ b/sys/dev/mlx5/mlx5_en/mlx5_en_main.c
@@ -1273,7 +1273,7 @@ mlx5e_create_rq(struct mlx5e_channel *c,
/* set value for constant fields */
for (j = 0; j < rq->nsegs; j++)
- wqe->data[j].lkey = c->mkey_be;
+ wqe->data[j].lkey = cpu_to_be32(priv->mr.key);
}
INIT_WORK(&rq->dim.work, mlx5e_dim_work);
@@ -1629,7 +1629,7 @@ mlx5e_create_sq(struct mlx5e_channel *c,
if (err)
goto err_sq_wq_destroy;
- sq->mkey_be = c->mkey_be;
+ sq->mkey_be = cpu_to_be32(priv->mr.key);
sq->ifp = priv->ifp;
sq->priv = priv;
sq->tc = tc;
@@ -2158,7 +2158,6 @@ mlx5e_open_channel(struct mlx5e_priv *priv, int ix,
c->ix = ix;
/* setup send tag */
c->tag.type = IF_SND_TAG_TYPE_UNLIMITED;
- c->mkey_be = cpu_to_be32(priv->mr.key);
c->num_tc = priv->num_tc;
/* init mutexes */