diff options
author | Ursula Braun <ubraun@linux.ibm.com> | 2018-07-25 16:35:31 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-07-25 22:25:53 -0700 |
commit | 7005ada68d1774d7c1109deaba0c2cd8e46f5091 (patch) | |
tree | cf7d9bc452cdbee2f3197874adbbf8089fc7a879 /net/smc/smc_diag.c | |
parent | 947541f36c561b5e0ca639ffc450a8c5221de467 (diff) |
net/smc: use correct vlan gid of RoCE device
SMC code uses the base gid for VLAN traffic. The gids exchanged in
the CLC handshake and the gid index used for the QP have to switch
from the base gid to the appropriate vlan gid.
When searching for a matching IB device port for a certain vlan
device, it does not make sense to return an IB device port, which
is not enabled for the used vlan_id. Add another check whether a
vlan gid exists for a certain IB device port.
Signed-off-by: Ursula Braun <ubraun@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/smc/smc_diag.c')
-rw-r--r-- | net/smc/smc_diag.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/smc/smc_diag.c b/net/smc/smc_diag.c index d772cd10297e..a3cf7313a2d3 100644 --- a/net/smc/smc_diag.c +++ b/net/smc/smc_diag.c @@ -154,7 +154,7 @@ static int __smc_diag_dump(struct sock *sk, struct sk_buff *skb, smc->conn.lgr->lnk[0].smcibdev->ibdev->name, sizeof(smc->conn.lgr->lnk[0].smcibdev->ibdev->name)); smc_gid_be16_convert(linfo.lnk[0].gid, - smc->conn.lgr->lnk[0].gid.raw); + smc->conn.lgr->lnk[0].gid); smc_gid_be16_convert(linfo.lnk[0].peer_gid, smc->conn.lgr->lnk[0].peer_gid); |