aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/sw/rxe
diff options
context:
space:
mode:
authorParav Pandit <parav@mellanox.com>2018-04-01 15:08:24 +0300
committerJason Gunthorpe <jgg@mellanox.com>2018-04-03 21:34:16 -0600
commit414448d249d82c9be93b35e61e0303e84ef2f959 (patch)
treee9d417bc1511726395c4171380e16be804999d96 /drivers/infiniband/sw/rxe
parentIB/providers: Avoid null netdev check for RoCE (diff)
downloadlinux-dev-414448d249d82c9be93b35e61e0303e84ef2f959.tar.xz
linux-dev-414448d249d82c9be93b35e61e0303e84ef2f959.zip
RDMA: Use ib_gid_attr during GID modification
Now that ib_gid_attr contains device, port and index, simplify the provider APIs add_gid() and del_gid() to use device, port and index fields from the ib_gid_attr attributes structure. Signed-off-by: Parav Pandit <parav@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/sw/rxe')
-rw-r--r--drivers/infiniband/sw/rxe/rxe_verbs.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/infiniband/sw/rxe/rxe_verbs.c b/drivers/infiniband/sw/rxe/rxe_verbs.c
index 0661c2783b14..08f3e0618b81 100644
--- a/drivers/infiniband/sw/rxe/rxe_verbs.c
+++ b/drivers/infiniband/sw/rxe/rxe_verbs.c
@@ -77,19 +77,17 @@ out:
return rc;
}
-static int rxe_add_gid(struct ib_device *device, u8 port_num, unsigned int
- index, const union ib_gid *gid,
+static int rxe_add_gid(const union ib_gid *gid,
const struct ib_gid_attr *attr, void **context)
{
- if (index >= RXE_PORT_GID_TBL_LEN)
+ if (attr->index >= RXE_PORT_GID_TBL_LEN)
return -EINVAL;
return 0;
}
-static int rxe_del_gid(struct ib_device *device, u8 port_num, unsigned int
- index, void **context)
+static int rxe_del_gid(const struct ib_gid_attr *attr, void **context)
{
- if (index >= RXE_PORT_GID_TBL_LEN)
+ if (attr->index >= RXE_PORT_GID_TBL_LEN)
return -EINVAL;
return 0;
}