summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorKamal Heib <kamalheib1@gmail.com>2018-12-10 22:09:48 +0300
committerJason Gunthorpe <jgg@mellanox.com>2018-12-12 17:40:16 +0300
commit3023a1e93656c02b8d6a3a46e712b815843fa514 (patch)
tree6c1471a47bb6ee96cee6fcac950a116701d79f8d /net
parent02a42f8e40caed53fd357c9c33912e1bfb6f0365 (diff)
downloadlinux-3023a1e93656c02b8d6a3a46e712b815843fa514.tar.xz
RDMA: Start use ib_device_ops
Make all the required change to start use the ib_device_ops structure. Signed-off-by: Kamal Heib <kamalheib1@gmail.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'net')
-rw-r--r--net/rds/ib.c4
-rw-r--r--net/sunrpc/xprtrdma/fmr_ops.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/net/rds/ib.c b/net/rds/ib.c
index eba75c1ba359..9d7b7586f240 100644
--- a/net/rds/ib.c
+++ b/net/rds/ib.c
@@ -148,8 +148,8 @@ static void rds_ib_add_one(struct ib_device *device)
has_fr = (device->attrs.device_cap_flags &
IB_DEVICE_MEM_MGT_EXTENSIONS);
- has_fmr = (device->alloc_fmr && device->dealloc_fmr &&
- device->map_phys_fmr && device->unmap_fmr);
+ has_fmr = (device->ops.alloc_fmr && device->ops.dealloc_fmr &&
+ device->ops.map_phys_fmr && device->ops.unmap_fmr);
rds_ibdev->use_fastreg = (has_fr && !has_fmr);
rds_ibdev->fmr_max_remaps = device->attrs.max_map_per_fmr?: 32;
diff --git a/net/sunrpc/xprtrdma/fmr_ops.c b/net/sunrpc/xprtrdma/fmr_ops.c
index 7f5632cd5a48..fd8fea59fe92 100644
--- a/net/sunrpc/xprtrdma/fmr_ops.c
+++ b/net/sunrpc/xprtrdma/fmr_ops.c
@@ -41,7 +41,7 @@ enum {
bool
fmr_is_supported(struct rpcrdma_ia *ia)
{
- if (!ia->ri_device->alloc_fmr) {
+ if (!ia->ri_device->ops.alloc_fmr) {
pr_info("rpcrdma: 'fmr' mode is not supported by device %s\n",
ia->ri_device->name);
return false;