RDMA/mlx5: Rely on existence of udata to separate kernel/user flows
authorLeon Romanovsky <leonro@mellanox.com>
Mon, 27 Apr 2020 15:46:24 +0000 (18:46 +0300)
committerJason Gunthorpe <jgg@mellanox.com>
Thu, 30 Apr 2020 21:45:43 +0000 (18:45 -0300)
commit03c4077b284056fdb144f84aaa0ac0c80023f597
tree9f2a77d626b6ac6591360dce2e1feaafa92b8625
parent76883a6cc1459b2aa1e96e1eaa19aa37221c2406
RDMA/mlx5: Rely on existence of udata to separate kernel/user flows

Instead of keeping special field to separate kernel/user create/destroy
flows, rely on existence of udata pointer. All allocation flows are
using kzalloc() and leave uninitialized pointers as NULL which makes
MLX5_QP_EMPTY and MLX5_QP_KERNEL flows to be the same.

Link: https://lore.kernel.org/r/20200427154636.381474-25-leon@kernel.org
Reviewed-by: Maor Gottlieb <maorg@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/mlx5/mlx5_ib.h
drivers/infiniband/hw/mlx5/qp.c