Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7eae20db authored by Majd Dibbiny's avatar Majd Dibbiny Committed by Roland Dreier
Browse files

IB/mlx5: Update the dev in reg_create



When we create an MR using reg_create, the mlx5_ib_dev pointer is not
updated on the new MR. This results in a kernel panics for ODP MRs
while handling page faults, when the mlx5_ib_update_mtt function uses
the invalid device pointer.

Signed-off-by: default avatarMajd Dibbiny <majd@mellanox.com>
Signed-off-by: default avatarHaggai Eran <haggaie@mellanox.com>
Signed-off-by: default avatarRoland Dreier <roland@purestorage.com>
parent bfa76d49
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1012,6 +1012,7 @@ static struct mlx5_ib_mr *reg_create(struct ib_pd *pd, u64 virt_addr,
		goto err_2;
	}
	mr->umem = umem;
	mr->dev = dev;
	mr->live = 1;
	kvfree(in);