diff options
author | Parav Pandit <parav@mellanox.com> | 2018-03-25 12:40:22 +0200 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2018-03-28 00:22:12 +0200 |
commit | 22d24f75a19399bd8c4822541c60e853a16a1956 (patch) | |
tree | b9cc6c59302756816cf9e672479f03aca209a55a /drivers/infiniband | |
parent | IB/core: Refer to RoCE port property instead of GID table property (diff) | |
download | linux-22d24f75a19399bd8c4822541c60e853a16a1956.tar.xz linux-22d24f75a19399bd8c4822541c60e853a16a1956.zip |
IB/core: Search GID only for IB link layer
Even though API is only used by IPoIB driver, its incorrect to refer
RoCE GID table property to search for GID.
Look for only IB link layer to search for the GID.
Fixes: dbb12562f7c2 ("IB/{core, ipoib}: Simplify ib_find_gid to search only for IB link layer")
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')
-rw-r--r-- | drivers/infiniband/core/device.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c index ba0e34b09648..dbe984faed65 100644 --- a/drivers/infiniband/core/device.c +++ b/drivers/infiniband/core/device.c @@ -1061,7 +1061,7 @@ int ib_find_gid(struct ib_device *device, union ib_gid *gid, int ret, port, i; for (port = rdma_start_port(device); port <= rdma_end_port(device); ++port) { - if (rdma_cap_roce_gid_table(device, port)) + if (!rdma_protocol_ib(device, port)) continue; for (i = 0; i < device->port_immutable[port].gid_tbl_len; ++i) { |