Jason Gunthorpe 5eb29f0d13 RDMA/mlx5: Make mkeys always owned by the kernel's PD when not enabled
Any mkey that is not enabled and assigned to userspace should have the PD
set to a kernel owned PD.

When cache entries are created for the first time the PDN is set to 0,
which is probably a kernel PD, but be explicit.

When a MR is registered using the hybrid reg_create with UMR xlt & enable
the disabled mkey is pointing at the user PD, keep it pointing at the
kernel until a UMR enables it and sets the user PD.

Fixes: 9ec4483a3f0f ("IB/mlx5: Move MRs to a kernel PD when freeing them to the MR cache")
Link: https://lore.kernel.org/r/20200914112653.345244-4-leon@kernel.org
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
2020-09-18 13:02:43 -03:00
..
2020-08-28 21:17:56 +02:00
2020-09-04 13:19:19 -07:00
2020-09-13 09:02:59 -07:00
2020-08-02 18:26:51 +03:00
2020-08-15 08:18:22 -07:00
2020-09-12 12:43:58 -07:00
2020-09-04 12:12:39 -07:00
2020-09-13 09:02:59 -07:00
2020-09-11 09:49:23 +10:00
2020-08-26 10:44:15 -07:00
2020-08-29 12:37:00 -07:00
2020-08-05 19:24:27 -07:00
2020-09-03 08:22:16 -07:00
2020-08-28 10:15:33 -07:00
2020-09-13 08:52:21 -07:00
2020-09-04 12:41:55 +02:00
2020-08-14 16:00:09 -07:00
2020-09-11 11:25:55 -07:00
2020-09-08 11:42:58 -07:00
2020-09-11 11:35:55 -07:00
2020-09-08 11:42:58 -07:00
2020-08-26 10:58:20 -07:00
2020-09-08 17:50:58 +02:00
2020-09-06 09:59:27 -07:00