summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/ocrdma
diff options
context:
space:
mode:
authorMatan Barak <matanb@mellanox.com>2015-12-23 13:56:53 +0100
committerDoug Ledford <dledford@redhat.com>2015-12-23 16:35:12 +0100
commit200298326b276d8dbeff204f7d407432100d9963 (patch)
tree285f2b2fbcc1c6672ce95f7d24009b328078fba4 /drivers/infiniband/hw/ocrdma
parentIB/core: Move rdma_is_upper_dev_rcu to header file (diff)
downloadlinux-200298326b276d8dbeff204f7d407432100d9963.tar.xz
linux-200298326b276d8dbeff204f7d407432100d9963.zip
IB/core: Validate route when we init ah
In order to make sure API users don't try to use SGIDs which don't conform to the routing table, validate the route before searching the RoCE GID table. Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/ocrdma')
-rw-r--r--drivers/infiniband/hw/ocrdma/ocrdma_ah.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_ah.c b/drivers/infiniband/hw/ocrdma/ocrdma_ah.c
index 9820074be59d..a343e0377bf6 100644
--- a/drivers/infiniband/hw/ocrdma/ocrdma_ah.c
+++ b/drivers/infiniband/hw/ocrdma/ocrdma_ah.c
@@ -154,7 +154,7 @@ struct ib_ah *ocrdma_create_ah(struct ib_pd *ibpd, struct ib_ah_attr *attr)
(!rdma_link_local_addr((struct in6_addr *)attr->grh.dgid.raw))) {
status = rdma_addr_find_dmac_by_grh(&sgid, &attr->grh.dgid,
attr->dmac, &vlan_tag,
- sgid_attr.ndev->ifindex);
+ &sgid_attr.ndev->ifindex);
if (status) {
pr_err("%s(): Failed to resolve dmac from gid."
"status = %d\n", __func__, status);