]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/mlx5: Set QP subtype immediately when it is known
authorLeon Romanovsky <leonro@mellanox.com>
Mon, 27 Apr 2020 15:46:06 +0000 (18:46 +0300)
committerJason Gunthorpe <jgg@mellanox.com>
Tue, 28 Apr 2020 23:42:21 +0000 (20:42 -0300)
commit8028abc64b678da615aa419a287a134cde412c1c
treea3b4ff6179dee5ecc736f027337bd0ffa41d692e
parentb2466587f5124fed1d5c8270889012c1460174cc
RDMA/mlx5: Set QP subtype immediately when it is known

There is no need to delay QP subtype assignment to the end of the
create_qp() function and it is better to move it to be immediately
after it is checked so we would be able to rewrite later checks
to be based on it and not on over-written struct ib_qp_init_attr.

Link: https://lore.kernel.org/r/20200427154636.381474-7-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/qp.c