Home
last modified time | relevance | path

Searched refs:neigh (Results 1 – 25 of 29) sorted by relevance

12

/drivers/net/ethernet/sfc/
Dtc_encap_actions.c41 struct efx_neigh_binder *neigh = ptr; in efx_neigh_free() local
43 WARN_ON(refcount_read(&neigh->ref)); in efx_neigh_free()
44 WARN_ON(!list_empty(&neigh->users)); in efx_neigh_free()
45 put_net_track(neigh->net, &neigh->ns_tracker); in efx_neigh_free()
46 netdev_put(neigh->egdev, &neigh->dev_tracker); in efx_neigh_free()
47 kfree(neigh); in efx_neigh_free()
88 struct efx_neigh_binder *neigh, *old; in efx_bind_neigh() local
121 neigh = kzalloc(sizeof(*neigh), GFP_KERNEL_ACCOUNT); in efx_bind_neigh()
122 if (!neigh) in efx_bind_neigh()
124 neigh->net = get_net_track(net, &neigh->ns_tracker, GFP_KERNEL_ACCOUNT); in efx_bind_neigh()
[all …]
Dtc_counters.c102 if (!encap->neigh) /* can't happen */ in efx_tc_counter_work()
104 if (time_after_eq(encap->neigh->used, touched)) in efx_tc_counter_work()
106 encap->neigh->used = touched; in efx_tc_counter_work()
110 if (encap->neigh->dst_ip) in efx_tc_counter_work()
111 n = neigh_lookup(&arp_tbl, &encap->neigh->dst_ip, in efx_tc_counter_work()
112 encap->neigh->egdev); in efx_tc_counter_work()
116 &encap->neigh->dst_ip6, in efx_tc_counter_work()
117 encap->neigh->egdev); in efx_tc_counter_work()
Dtc_encap_actions.h78 struct efx_neigh_binder *neigh; member
/drivers/net/ethernet/chelsio/cxgb3/
Dl2t.c77 if (e->neigh) in neigh_replace()
78 neigh_release(e->neigh); in neigh_replace()
79 e->neigh = n; in neigh_replace()
105 memcpy(e->dmac, e->neigh->ha, sizeof(e->dmac)); in setup_l2e_send_pending()
134 neigh_event_send(e->neigh, NULL); in t3_l2t_send_slow()
160 if (!neigh_event_send(e->neigh, NULL)) { in t3_l2t_send_slow()
184 neigh_event_send(e->neigh, NULL); in t3_l2t_send_event()
210 neigh_event_send(e->neigh, NULL); in t3_l2t_send_event()
268 if (e->neigh) { in t3_l2e_free()
269 neigh_release(e->neigh); in t3_l2e_free()
[all …]
Dl2t.h64 struct neighbour *neigh; /* associated neighbour */ member
111 void t3_l2t_update(struct t3cdev *dev, struct neighbour *neigh);
Dcxgb3_offload.c66 static void cxgb_neigh_update(struct neighbour *neigh);
68 struct neighbour *neigh, const void *daddr);
488 static void dummy_neigh_update(struct t3cdev *dev, struct neighbour *neigh) in dummy_neigh_update() argument
972 cxgb_redirect(nr->old, nr->new, nr->neigh, in nb_callback()
974 cxgb_neigh_update(nr->neigh); in nb_callback()
1073 static void cxgb_neigh_update(struct neighbour *neigh) in cxgb_neigh_update() argument
1077 if (!neigh) in cxgb_neigh_update()
1079 dev = neigh->dev; in cxgb_neigh_update()
1084 t3_l2t_update(tdev, neigh); in cxgb_neigh_update()
1111 struct neighbour *neigh, in cxgb_redirect() argument
[all …]
Dt3cdev.h61 void (*neigh_update)(struct t3cdev *dev, struct neighbour *neigh);
/drivers/infiniband/ulp/ipoib/
Dipoib_main.c752 struct ipoib_neigh *neigh, *tn; in path_rec_completion() local
808 list_for_each_entry_safe(neigh, tn, &path->neigh_list, list) { in path_rec_completion()
809 if (neigh->ah) { in path_rec_completion()
810 WARN_ON(neigh->ah != old_ah); in path_rec_completion()
818 ipoib_put_ah(neigh->ah); in path_rec_completion()
821 neigh->ah = path->ah; in path_rec_completion()
823 if (ipoib_cm_enabled(dev, neigh->daddr)) { in path_rec_completion()
824 if (!ipoib_cm_get(neigh)) in path_rec_completion()
825 ipoib_cm_set(neigh, ipoib_cm_create_tx(dev, in path_rec_completion()
827 neigh)); in path_rec_completion()
[all …]
Dipoib.h250 struct ipoib_neigh *neigh; member
465 void ipoib_neigh_dtor(struct ipoib_neigh *neigh);
466 static inline void ipoib_neigh_put(struct ipoib_neigh *neigh) in ipoib_neigh_put() argument
468 if (refcount_dec_and_test(&neigh->refcnt)) in ipoib_neigh_put()
469 ipoib_neigh_dtor(neigh); in ipoib_neigh_put()
474 void ipoib_neigh_free(struct ipoib_neigh *neigh);
638 static inline int ipoib_cm_up(struct ipoib_neigh *neigh) in ipoib_cm_up() argument
641 return test_bit(IPOIB_FLAG_OPER_UP, &neigh->cm->flags); in ipoib_cm_up()
644 static inline struct ipoib_cm_tx *ipoib_cm_get(struct ipoib_neigh *neigh) in ipoib_cm_get() argument
646 return neigh->cm; in ipoib_cm_get()
[all …]
Dipoib_cm.c834 struct ipoib_neigh *neigh; in ipoib_cm_handle_tx_wc() local
850 neigh = tx->neigh; in ipoib_cm_handle_tx_wc()
852 if (neigh) { in ipoib_cm_handle_tx_wc()
853 neigh->cm = NULL; in ipoib_cm_handle_tx_wc()
854 ipoib_neigh_free(neigh); in ipoib_cm_handle_tx_wc()
856 tx->neigh = NULL; in ipoib_cm_handle_tx_wc()
1035 if (p->neigh) in ipoib_cm_rep_handler()
1036 while ((skb = __skb_dequeue(&p->neigh->queue))) in ipoib_cm_rep_handler()
1255 struct ipoib_neigh *neigh; in ipoib_cm_tx_handler() local
1277 neigh = tx->neigh; in ipoib_cm_tx_handler()
[all …]
Dipoib_multicast.c795 struct ipoib_neigh *neigh; in ipoib_mcast_send() local
798 neigh = ipoib_neigh_get(dev, daddr); in ipoib_mcast_send()
800 if (!neigh) { in ipoib_mcast_send()
801 neigh = ipoib_neigh_alloc(daddr, dev); in ipoib_mcast_send()
805 if (neigh && list_empty(&neigh->list)) { in ipoib_mcast_send()
807 neigh->ah = mcast->ah; in ipoib_mcast_send()
808 neigh->ah->valid = 1; in ipoib_mcast_send()
809 list_add_tail(&neigh->list, &mcast->neigh_list); in ipoib_mcast_send()
815 if (neigh) in ipoib_mcast_send()
816 ipoib_neigh_put(neigh); in ipoib_mcast_send()
/drivers/net/ethernet/chelsio/cxgb4/
Dl2t.c129 if (e->neigh) in neigh_replace()
130 neigh_release(e->neigh); in neigh_replace()
131 e->neigh = n; in neigh_replace()
158 if (e->neigh && !(e->neigh->dev->flags & IFF_LOOPBACK)) in write_l2e()
159 memcpy(e->dmac, e->neigh->ha, sizeof(e->dmac)); in write_l2e()
205 e->state = (e->neigh->nud_state & NUD_STALE) ? in do_l2t_write_rpl()
229 neigh_event_send(e->neigh, NULL); in cxgb4_l2t_send()
249 !neigh_event_send(e->neigh, NULL)) { in cxgb4_l2t_send()
356 if (e->neigh) { in _t4_l2e_free()
357 neigh_release(e->neigh); in _t4_l2e_free()
[all …]
Dl2t.h78 struct neighbour *neigh; /* associated neighbour */ member
113 struct l2t_entry *cxgb4_l2t_get(struct l2t_data *d, struct neighbour *neigh,
120 void t4_l2t_update(struct adapter *adap, struct neighbour *neigh);
/drivers/net/ethernet/marvell/prestera/
Dprestera_router_hw.c289 struct prestera_nh_neigh *neigh) in __prestera_nh_neigh_destroy() argument
292 &neigh->ht_node, in __prestera_nh_neigh_destroy()
294 kfree(neigh); in __prestera_nh_neigh_destroy()
301 struct prestera_nh_neigh *neigh; in __prestera_nh_neigh_create() local
304 neigh = kzalloc(sizeof(*neigh), GFP_KERNEL); in __prestera_nh_neigh_create()
305 if (!neigh) in __prestera_nh_neigh_create()
308 memcpy(&neigh->key, key, sizeof(*key)); in __prestera_nh_neigh_create()
309 neigh->info.connected = false; in __prestera_nh_neigh_create()
310 INIT_LIST_HEAD(&neigh->nexthop_group_list); in __prestera_nh_neigh_create()
312 &neigh->ht_node, in __prestera_nh_neigh_create()
[all …]
Dprestera_router_hw.h74 struct prestera_nh_neigh_key neigh[PRESTERA_NHGR_SIZE_MAX]; member
86 struct prestera_nh_neigh *neigh; member
138 struct prestera_nh_neigh *neigh);
140 struct prestera_nh_neigh *neigh);
Dprestera_router.c397 if (fib_node->info.nh_grp->nh_neigh_head[1].neigh) in prestera_fib_node_util_is_neighbour()
400 if (!fib_node->info.nh_grp->nh_neigh_head[0].neigh) in prestera_fib_node_util_is_neighbour()
403 if (memcmp(&fib_node->info.nh_grp->nh_neigh_head[0].neigh->key.addr, in prestera_fib_node_util_is_neighbour()
762 &nh_grp_key.neigh[0]); in __prestera_k_arb_n_lpm_set()
879 fc->lpm_info.nh_grp_key.neigh[0].addr = in __prestera_pr_k_arb_fc_lpm_info_calc()
881 fc->lpm_info.nh_grp_key.neigh[0].rif = in __prestera_pr_k_arb_fc_lpm_info_calc()
895 fc->lpm_info.nh_grp_key.neigh[nh_cnt].addr = in __prestera_pr_k_arb_fc_lpm_info_calc()
897 fc->lpm_info.nh_grp_key.neigh[nh_cnt].rif = in __prestera_pr_k_arb_fc_lpm_info_calc()
/drivers/net/ethernet/netronome/nfp/flower/
Dtunnel_conf.c323 struct nfp_neigh_entry *neigh) in nfp_tun_mutual_link() argument
329 if (flow_pay->pre_tun_rule.is_ipv6 != neigh->is_ipv6) in nfp_tun_mutual_link()
336 if (neigh->flow) in nfp_tun_mutual_link()
339 common = neigh->is_ipv6 ? in nfp_tun_mutual_link()
340 &((struct nfp_tun_neigh_v6 *)neigh->payload)->common : in nfp_tun_mutual_link()
341 &((struct nfp_tun_neigh_v4 *)neigh->payload)->common; in nfp_tun_mutual_link()
342 ext = neigh->is_ipv6 ? in nfp_tun_mutual_link()
343 &((struct nfp_tun_neigh_v6 *)neigh->payload)->ext : in nfp_tun_mutual_link()
344 &((struct nfp_tun_neigh_v4 *)neigh->payload)->ext; in nfp_tun_mutual_link()
352 list_add(&neigh->list_head, &predt->nn_list); in nfp_tun_mutual_link()
[all …]
/drivers/infiniband/hw/qedr/
Dqedr_iw_cm.c446 struct neighbour *neigh = NULL; in qedr_addr4_resolve() local
456 neigh = dst_neigh_lookup(&rt->dst, &dst_ip); in qedr_addr4_resolve()
458 if (neigh) { in qedr_addr4_resolve()
460 if (neigh->nud_state & NUD_VALID) { in qedr_addr4_resolve()
461 ether_addr_copy(dst_mac, neigh->ha); in qedr_addr4_resolve()
464 neigh_event_send(neigh, NULL); in qedr_addr4_resolve()
467 neigh_release(neigh); in qedr_addr4_resolve()
480 struct neighbour *neigh = NULL; in qedr_addr6_resolve() local
500 neigh = dst_neigh_lookup(dst, &fl6.daddr); in qedr_addr6_resolve()
501 if (neigh) { in qedr_addr6_resolve()
[all …]
/drivers/net/ethernet/mellanox/mlxsw/
Dspectrum_span.c232 struct neighbour *neigh = neigh_lookup(tbl, pkey, dev); in mlxsw_sp_span_dmac() local
235 if (!neigh) { in mlxsw_sp_span_dmac()
236 neigh = neigh_create(tbl, pkey, dev); in mlxsw_sp_span_dmac()
237 if (IS_ERR(neigh)) in mlxsw_sp_span_dmac()
238 return PTR_ERR(neigh); in mlxsw_sp_span_dmac()
241 neigh_event_send(neigh, NULL); in mlxsw_sp_span_dmac()
243 read_lock_bh(&neigh->lock); in mlxsw_sp_span_dmac()
244 if ((neigh->nud_state & NUD_VALID) && !neigh->dead) in mlxsw_sp_span_dmac()
245 memcpy(dmac, neigh->ha, ETH_ALEN); in mlxsw_sp_span_dmac()
248 read_unlock_bh(&neigh->lock); in mlxsw_sp_span_dmac()
[all …]
/drivers/net/
Dvrf.c647 struct neighbour *neigh; in vrf_finish_output6() local
657 neigh = __ipv6_neigh_lookup_noref(dst->dev, nexthop); in vrf_finish_output6()
658 if (unlikely(!neigh)) in vrf_finish_output6()
659 neigh = __neigh_create(&nd_tbl, nexthop, dst->dev, false); in vrf_finish_output6()
660 if (!IS_ERR(neigh)) { in vrf_finish_output6()
661 sock_confirm_neigh(skb, neigh); in vrf_finish_output6()
662 ret = neigh_output(neigh, skb, false); in vrf_finish_output6()
866 struct neighbour *neigh; in vrf_finish_output() local
882 neigh = ip_neigh_for_gw(rt, skb, &is_v6gw); in vrf_finish_output()
883 if (!IS_ERR(neigh)) { in vrf_finish_output()
[all …]
/drivers/infiniband/hw/irdma/
Dcm.c1983 struct neighbour *neigh; in irdma_addr_resolve_neigh() local
1994 neigh = dst_neigh_lookup(&rt->dst, &dst_ipaddr); in irdma_addr_resolve_neigh()
1995 if (!neigh) in irdma_addr_resolve_neigh()
1998 if (neigh->nud_state & NUD_VALID) in irdma_addr_resolve_neigh()
1999 rc = irdma_add_arp(iwdev->rf, &dst_ip, true, neigh->ha); in irdma_addr_resolve_neigh()
2001 neigh_event_send(neigh, NULL); in irdma_addr_resolve_neigh()
2002 if (neigh) in irdma_addr_resolve_neigh()
2003 neigh_release(neigh); in irdma_addr_resolve_neigh()
2044 struct neighbour *neigh; in irdma_addr_resolve_neigh_ipv6() local
2065 neigh = dst_neigh_lookup(dst, dst_addr.sin6_addr.in6_u.u6_addr32); in irdma_addr_resolve_neigh_ipv6()
[all …]
Dutils.c253 struct neighbour *neigh = ptr; in irdma_net_event() local
254 struct net_device *real_dev, *netdev = (struct net_device *)neigh->dev; in irdma_net_event()
271 p = (__be32 *)neigh->primary_key; in irdma_net_event()
272 if (neigh->tbl->family == AF_INET6) { in irdma_net_event()
281 iwdev->netdev, neigh->nud_state, local_ipaddr, in irdma_net_event()
282 neigh->ha); in irdma_net_event()
284 if (neigh->nud_state & NUD_VALID) in irdma_net_event()
285 irdma_add_arp(iwdev->rf, local_ipaddr, ipv4, neigh->ha); in irdma_net_event()
288 irdma_manage_arp_cache(iwdev->rf, neigh->ha, in irdma_net_event()
/drivers/net/plip/
Dplip.c150 static int plip_hard_header_cache(const struct neighbour *neigh,
1043 static int plip_hard_header_cache(const struct neighbour *neigh, in plip_hard_header_cache() argument
1048 ret = eth_header_cache(neigh, hh, type); in plip_hard_header_cache()
1054 plip_rewrite_address (neigh->dev, eth); in plip_hard_header_cache()
/drivers/infiniband/core/
Daddr.c857 struct neighbour *neigh = ctx; in netevent_callback() local
859 if (neigh->nud_state & NUD_VALID) { in netevent_callback()
/drivers/firewire/
Dnet.c232 static int fwnet_header_cache(const struct neighbour *neigh, in fwnet_header_cache() argument
240 net = neigh->dev; in fwnet_header_cache()
243 memcpy(h->h_dest, neigh->ha, net->addr_len); in fwnet_header_cache()

12