OSDN Git Service

IB/umem: Update on demand page (ODP) support
authorArtemy Kovalyov <artemyko@mellanox.com>
Wed, 18 Jan 2017 14:58:07 +0000 (16:58 +0200)
committerDoug Ledford <dledford@redhat.com>
Tue, 14 Feb 2017 16:41:17 +0000 (11:41 -0500)
commitd07d1d70ce1ad1c525f51f459ce36ca49ec2bf48
tree09873cb0c3319aa49d59d1f44e2007e9bbd96356
parent25bf14d6f5898a59325f3ecabda7695565776594
IB/umem: Update on demand page (ODP) support

Currently ODP MR may explicitly register virtual address space area
of limited length.
This change allows MR to cover entire process virtual address space
dynamicaly adding/removing translation entries to device MTT.

Add following changes to support implicit MR:
* Allow umem to be zero size to back-up implicit MR.
* Add new function ib_alloc_odp_umem() to add virtual memory regions
  to implicit MR dynamically on demand.
* Add new function rbt_ib_umem_lookup() to find dynamically added
  virtual memory regions.
* Expose function rbt_ib_umem_for_each_in_range() to other modules and
  make it safe

Signed-off-by: Artemy Kovalyov <artemyko@mellanox.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/core/umem.c
drivers/infiniband/core/umem_odp.c
drivers/infiniband/core/umem_rbtree.c
include/rdma/ib_umem_odp.h