IB/core: Add UVERBS_METHOD_REG_MR on the MR object
This new method enables us to use a single ioctl from user space which supports the below variants of reg_mr [1]. The method will be extended in the next patches from the series with an extra attribute to let us pass DMA handle to be used as part of the registration. [1] ibv_reg_mr(), ibv_reg_mr_iova(), ibv_reg_mr_iova2(), ibv_reg_dmabuf_mr(). Signed-off-by: Yishai Hadas <yishaih@nvidia.com> Reviewed-by: Edward Srouji <edwards@nvidia.com> Link: https://patch.msgid.link/5a3822ceef084efe967c9752e89c58d8250337c7.1752752567.git.leon@kernel.org Signed-off-by: Leon Romanovsky <leon@kernel.org>
This commit is contained in:
committed by
Leon Romanovsky
parent
b272fc8972
commit
5b2e45049d
@@ -257,6 +257,7 @@ enum uverbs_methods_mr {
|
||||
UVERBS_METHOD_ADVISE_MR,
|
||||
UVERBS_METHOD_QUERY_MR,
|
||||
UVERBS_METHOD_REG_DMABUF_MR,
|
||||
UVERBS_METHOD_REG_MR,
|
||||
};
|
||||
|
||||
enum uverbs_attrs_mr_destroy_ids {
|
||||
@@ -290,6 +291,19 @@ enum uverbs_attrs_reg_dmabuf_mr_cmd_attr_ids {
|
||||
UVERBS_ATTR_REG_DMABUF_MR_RESP_RKEY,
|
||||
};
|
||||
|
||||
enum uverbs_attrs_reg_mr_cmd_attr_ids {
|
||||
UVERBS_ATTR_REG_MR_HANDLE,
|
||||
UVERBS_ATTR_REG_MR_PD_HANDLE,
|
||||
UVERBS_ATTR_REG_MR_IOVA,
|
||||
UVERBS_ATTR_REG_MR_ADDR,
|
||||
UVERBS_ATTR_REG_MR_LENGTH,
|
||||
UVERBS_ATTR_REG_MR_ACCESS_FLAGS,
|
||||
UVERBS_ATTR_REG_MR_FD,
|
||||
UVERBS_ATTR_REG_MR_FD_OFFSET,
|
||||
UVERBS_ATTR_REG_MR_RESP_LKEY,
|
||||
UVERBS_ATTR_REG_MR_RESP_RKEY,
|
||||
};
|
||||
|
||||
enum uverbs_attrs_create_counters_cmd_attr_ids {
|
||||
UVERBS_ATTR_CREATE_COUNTERS_HANDLE,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user