diff options
author | Yixian Liu <liuyixian@huawei.com> | 2018-10-05 17:53:24 +0800 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2018-10-16 00:17:08 -0600 |
commit | 68a997c5d28c581ae23594eb8a1420d834c30d24 (patch) | |
tree | 802dbfe91c2a714844365f5eff74e49de1ef6428 /drivers/infiniband/hw/hns/hns_roce_main.c | |
parent | 5df950994934814a8b91f0cf9f653842d2ba082d (diff) | |
download | linux-68a997c5d28c581ae23594eb8a1420d834c30d24.tar.bz2 |
RDMA/hns: Add FRMR support for hip08
This patch adds fast register physical memory region (FRMR) support for
hip08.
Signed-off-by: Yixian Liu <liuyixian@huawei.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/hw/hns/hns_roce_main.c')
-rw-r--r-- | drivers/infiniband/hw/hns/hns_roce_main.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/hns/hns_roce_main.c b/drivers/infiniband/hw/hns/hns_roce_main.c index 7e693b11c823..1b3ee514f2ef 100644 --- a/drivers/infiniband/hw/hns/hns_roce_main.c +++ b/drivers/infiniband/hw/hns/hns_roce_main.c @@ -535,6 +535,12 @@ static int hns_roce_register_device(struct hns_roce_dev *hr_dev) (1ULL << IB_USER_VERBS_CMD_DEALLOC_MW); } + /* FRMR */ + if (hr_dev->caps.flags & HNS_ROCE_CAP_FLAG_FRMR) { + ib_dev->alloc_mr = hns_roce_alloc_mr; + ib_dev->map_mr_sg = hns_roce_map_mr_sg; + } + /* OTHERS */ ib_dev->get_port_immutable = hns_roce_port_immutable; ib_dev->disassociate_ucontext = hns_roce_disassociate_ucontext; |