linux-stable/drivers/infiniband
Jason Gunthorpe e6fb246cca RDMA/mlx5: Consolidate MR destruction to mlx5_ib_dereg_mr()
Now that the SRCU stuff has been removed the entire MR destroy logic can
be made a lot simpler. Currently there are many different ways to destroy a
MR and it makes it really hard to do this task correctly. Route all
destruction through mlx5_ib_dereg_mr() and make it work for all
situations.

Since it turns out all the different MR types do basically the same thing
this removes a lot of knowledge of MR internals from ODP and leaves ODP
just exporting an operation to clean up children.

This fixes a few weird corner cases bugs and firmly uses the correct
ordering of the MR destruction:
 - Stop parallel access to the mkey via the ODP xarray
 - Stop DMA
 - Release the umem
 - Clean up ODP children
 - Free/Recycle the MR

Link: https://lore.kernel.org/r/20210304120745.1090751-4-leon@kernel.org
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
2021-03-11 20:03:25 -04:00
..
core RDMA/mlx5: Consolidate MR destruction to mlx5_ib_dereg_mr() 2021-03-11 20:03:25 -04:00
hw RDMA/mlx5: Consolidate MR destruction to mlx5_ib_dereg_mr() 2021-03-11 20:03:25 -04:00
sw RDMA/iwcm: Allow AFONLY binding for IPv6 addresses 2021-03-10 15:30:45 -04:00
ulp RDMA/rtrs-clt: Use rdma_event_msg in log 2021-03-11 14:50:41 -04:00
Kconfig RDMA/umem: Support importing dma-buf as user memory region 2021-01-20 16:07:52 -04:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00