IB: Set IOVA/LENGTH on IB_MR in core/uverbs layers
authorDaisuke Matsuda <matsuda-daisuke@fujitsu.com>
Wed, 21 Sep 2022 08:08:43 +0000 (17:08 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 26 Oct 2022 10:35:13 +0000 (12:35 +0200)
commit4d7d8f5cb28443cafef073a3733ce658d2694787
treea291aa5d7d022490cd47c9716d1a72b4608d760f
parente221b4f16e9e1bb2c1efbb0a62cbd4505e9184b1
IB: Set IOVA/LENGTH on IB_MR in core/uverbs layers

[ Upstream commit 241f9a27e0fc0eaf23e3d52c8450f10648cd11f1 ]

Set 'iova' and 'length' on ib_mr in ib_uverbs and ib_core layers to let all
drivers have the members filled. Also, this commit removes redundancy in
the respective drivers.

Previously, commit 04c0a5fcfcf65 ("IB/uverbs: Set IOVA on IB MR in uverbs
layer") changed to set 'iova', but seems to have missed 'length' and the
ib_core layer at that time.

Fixes: 04c0a5fcfcf65 ("IB/uverbs: Set IOVA on IB MR in uverbs layer")
Signed-off-by: Daisuke Matsuda <matsuda-daisuke@fujitsu.com>
Link: https://lore.kernel.org/r/20220921080844.1616883-1-matsuda-daisuke@fujitsu.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/infiniband/core/uverbs_cmd.c
drivers/infiniband/core/verbs.c
drivers/infiniband/hw/hns/hns_roce_mr.c
drivers/infiniband/hw/mlx4/mr.c