aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mlx4/qp.c
diff options
context:
space:
mode:
authorLeon Romanovsky <leonro@nvidia.com>2020-09-26 13:24:48 +0300
committerJason Gunthorpe <jgg@nvidia.com>2020-09-29 13:11:06 -0300
commitb925c555a15de8443ecb2e147b54b1bbe9b71fe3 (patch)
tree9fccc1de16f5ab65c0da03ca721a871183a8d3b1 /drivers/infiniband/hw/mlx4/qp.c
parentRDMA/core: Align write and ioctl checks of QP types (diff)
downloadlinux-dev-b925c555a15de8443ecb2e147b54b1bbe9b71fe3.tar.xz
linux-dev-b925c555a15de8443ecb2e147b54b1bbe9b71fe3.zip
RDMA/drivers: Remove udata check from special QP
GSI QP can't be created from the user space, hence the udata check is always false (udata == NULL). Remove that check and simplify the flow. Link: https://lore.kernel.org/r/20200926102450.2966017-9-leon@kernel.org Reviewed-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@nvidia.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/infiniband/hw/mlx4/qp.c')
-rw-r--r--drivers/infiniband/hw/mlx4/qp.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/infiniband/hw/mlx4/qp.c b/drivers/infiniband/hw/mlx4/qp.c
index f810e4df3fbf..5cb8e602294c 100644
--- a/drivers/infiniband/hw/mlx4/qp.c
+++ b/drivers/infiniband/hw/mlx4/qp.c
@@ -1544,9 +1544,6 @@ static int _mlx4_ib_create_qp(struct ib_pd *pd, struct mlx4_ib_qp *qp,
{
int sqpn;
- /* Userspace is not allowed to create special QPs: */
- if (udata)
- return -EINVAL;
if (init_attr->create_flags & MLX4_IB_QP_CREATE_ROCE_V2_GSI) {
int res = mlx4_qp_reserve_range(to_mdev(pd->device)->dev,
1, 1, &sqpn, 0,