aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mlx5/main.c
diff options
context:
space:
mode:
authorYishai Hadas <yishaih@mellanox.com>2018-09-20 21:39:29 +0300
committerJason Gunthorpe <jgg@mellanox.com>2018-09-25 14:06:04 -0600
commit58895f0d18df09a6be82e6e4141e4609dd12f84f (patch)
tree9a15c98a4d261c9a12bb331bc3b14f1ca1df489a /drivers/infiniband/hw/mlx5/main.c
parentIB/mlx5: Set uid as part of RQT commands (diff)
downloadlinux-dev-58895f0d18df09a6be82e6e4141e4609dd12f84f.tar.xz
linux-dev-58895f0d18df09a6be82e6e4141e4609dd12f84f.zip
IB/mlx5: Set uid upon PD allocation
Set uid as part of PD allocation, this uid is used for other mlx5 objects upon calling the firmware. Signed-off-by: Yishai Hadas <yishaih@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to '')
-rw-r--r--drivers/infiniband/hw/mlx5/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/mlx5/main.c b/drivers/infiniband/hw/mlx5/main.c
index 2ed30e181a8b..0df397fee94f 100644
--- a/drivers/infiniband/hw/mlx5/main.c
+++ b/drivers/infiniband/hw/mlx5/main.c
@@ -2262,6 +2262,7 @@ static struct ib_pd *mlx5_ib_alloc_pd(struct ib_device *ibdev,
if (!pd)
return ERR_PTR(-ENOMEM);
+ uid = context ? to_mucontext(context)->devx_uid : 0;
MLX5_SET(alloc_pd_in, in, opcode, MLX5_CMD_OP_ALLOC_PD);
MLX5_SET(alloc_pd_in, in, uid, uid);
err = mlx5_cmd_exec(to_mdev(ibdev)->mdev, in, sizeof(in),