On Wed, Dec 22, 2021 at 10:51:58AM +0800, Tony Lu wrote: > On Tue, Dec 21, 2021 at 11:46:41AM +0200, Leon Romanovsky wrote: > > From: Maor Gottlieb <maorg@xxxxxxxxxx> > > > > The cited commit moved umem into the union, hence > > umem could be accessed only for user MRs. Add udata check > > before access umem in the dereg flow. > > > > Fixes: f0ae4afe3d35 ("RDMA/mlx5: Fix releasing unallocated memory in dereg MR flow") > > Tested-by: Chuck Lever <chuck.lever@xxxxxxxxxx> > > Signed-off-by: Maor Gottlieb <maorg@xxxxxxxxxx> > > Signed-off-by: Leon Romanovsky <leonro@xxxxxxxxxx> > > --- > > drivers/infiniband/hw/mlx5/mlx5_ib.h | 2 +- > > drivers/infiniband/hw/mlx5/mr.c | 4 ++-- > > drivers/infiniband/hw/mlx5/odp.c | 4 ++-- > > 3 files changed, 5 insertions(+), 5 deletions(-) > > > > diff --git a/drivers/infiniband/hw/mlx5/mlx5_ib.h b/drivers/infiniband/hw/mlx5/mlx5_ib.h > > This patch was tested and works for me in our environment for SMC. It > wouldn't panic when release link and call ib_dereg_mr. > > Tested-by: Tony Lu <tonylu@xxxxxxxxxxxxxxxxx> Thanks, unfortunately, this patch is incomplete. > > Thanks, > Tony Lu