linux-rdma.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel.org>
To: Doug Ledford <dledford@redhat.com>, Jason Gunthorpe <jgg@nvidia.com>
Cc: Leon Romanovsky <leonro@nvidia.com>,
	linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org,
	Mark Zhang <markz@mellanox.com>
Subject: [PATCH rdma-next v2 1/7] RDMA/mlx5: Delete not-available udata check
Date: Tue,  3 Aug 2021 21:20:32 +0300	[thread overview]
Message-ID: <b68228597e730675020aa5162745390a2d39d3a2.1628014762.git.leonro@nvidia.com> (raw)
In-Reply-To: <cover.1628014762.git.leonro@nvidia.com>

From: Leon Romanovsky <leonro@nvidia.com>

XRC_TGT QPs are created through kernel verbs and don't have udata at all.

Fixes: 6eefa839c4dd ("RDMA/mlx5: Protect from kernel crash if XRC_TGT doesn't have udata")
Fixes: e383085c2425 ("RDMA/mlx5: Set ECE options during QP create")
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
---
 drivers/infiniband/hw/mlx5/qp.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/infiniband/hw/mlx5/qp.c b/drivers/infiniband/hw/mlx5/qp.c
index 9d20c838974f..556b5e7acd46 100644
--- a/drivers/infiniband/hw/mlx5/qp.c
+++ b/drivers/infiniband/hw/mlx5/qp.c
@@ -1906,7 +1906,6 @@ static int get_atomic_mode(struct mlx5_ib_dev *dev,
 static int create_xrc_tgt_qp(struct mlx5_ib_dev *dev, struct mlx5_ib_qp *qp,
 			     struct mlx5_create_qp_params *params)
 {
-	struct mlx5_ib_create_qp *ucmd = params->ucmd;
 	struct ib_qp_init_attr *attr = params->attr;
 	u32 uidx = params->uidx;
 	struct mlx5_ib_resources *devr = &dev->devr;
@@ -1926,8 +1925,6 @@ static int create_xrc_tgt_qp(struct mlx5_ib_dev *dev, struct mlx5_ib_qp *qp,
 	if (!in)
 		return -ENOMEM;
 
-	if (MLX5_CAP_GEN(mdev, ece_support) && ucmd)
-		MLX5_SET(create_qp_in, in, ece, ucmd->ece_options);
 	qpc = MLX5_ADDR_OF(create_qp_in, in, qpc);
 
 	MLX5_SET(qpc, qpc, st, MLX5_QP_ST_XRC);
-- 
2.31.1


  reply	other threads:[~2021-08-03 18:20 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-03 18:20 [PATCH rdma-next v2 0/7] Separate user/kernel QP creation logic Leon Romanovsky
2021-08-03 18:20 ` Leon Romanovsky [this message]
2021-08-03 18:20 ` [PATCH rdma-next v2 2/7] RDMA/core: Delete duplicated and unreachable code Leon Romanovsky
2021-08-03 18:20 ` [PATCH rdma-next v2 3/7] RDMA/core: Remove protection from wrong in-kernel API usage Leon Romanovsky
2021-08-03 18:20 ` [PATCH rdma-next v2 4/7] RDMA/core: Reorganize create QP low-level functions Leon Romanovsky
2021-08-03 18:20 ` [PATCH rdma-next v2 5/7] RDMA/core: Configure selinux QP during creation Leon Romanovsky
2021-08-03 18:20 ` [PATCH rdma-next v2 6/7] RDMA/core: Properly increment and decrement QP usecnts Leon Romanovsky
2021-08-03 18:20 ` [PATCH rdma-next v2 7/7] RDMA/core: Create clean QP creations interface for uverbs Leon Romanovsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b68228597e730675020aa5162745390a2d39d3a2.1628014762.git.leonro@nvidia.com \
    --to=leon@kernel.org \
    --cc=dledford@redhat.com \
    --cc=jgg@nvidia.com \
    --cc=leonro@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=markz@mellanox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).