diff options
Diffstat (limited to 'drivers/infiniband/hw/nes')
-rw-r--r-- | drivers/infiniband/hw/nes/nes_cm.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/nes/nes_cm.c b/drivers/infiniband/hw/nes/nes_cm.c index a4972abedef1..c5e4cb2d3223 100644 --- a/drivers/infiniband/hw/nes/nes_cm.c +++ b/drivers/infiniband/hw/nes/nes_cm.c | |||
@@ -1351,8 +1351,9 @@ static int nes_addr_resolve_neigh(struct nes_vnic *nesvnic, u32 dst_ip, int arpi | |||
1351 | else | 1351 | else |
1352 | netdev = nesvnic->netdev; | 1352 | netdev = nesvnic->netdev; |
1353 | 1353 | ||
1354 | neigh = dst_neigh_lookup(&rt->dst, &dst_ip); | ||
1355 | |||
1354 | rcu_read_lock(); | 1356 | rcu_read_lock(); |
1355 | neigh = dst_get_neighbour_noref(&rt->dst); | ||
1356 | if (neigh) { | 1357 | if (neigh) { |
1357 | if (neigh->nud_state & NUD_VALID) { | 1358 | if (neigh->nud_state & NUD_VALID) { |
1358 | nes_debug(NES_DBG_CM, "Neighbor MAC address for 0x%08X" | 1359 | nes_debug(NES_DBG_CM, "Neighbor MAC address for 0x%08X" |
@@ -1379,9 +1380,12 @@ static int nes_addr_resolve_neigh(struct nes_vnic *nesvnic, u32 dst_ip, int arpi | |||
1379 | neigh_event_send(neigh, NULL); | 1380 | neigh_event_send(neigh, NULL); |
1380 | } | 1381 | } |
1381 | } | 1382 | } |
1382 | |||
1383 | out: | 1383 | out: |
1384 | rcu_read_unlock(); | 1384 | rcu_read_unlock(); |
1385 | |||
1386 | if (neigh) | ||
1387 | neigh_release(neigh); | ||
1388 | |||
1385 | ip_rt_put(rt); | 1389 | ip_rt_put(rt); |
1386 | return rc; | 1390 | return rc; |
1387 | } | 1391 | } |