Home
last modified time | relevance | path

Searched refs:fib6_nh (Results 1 – 9 of 9) sorted by relevance

/linux/net/ipv6/
H A Droute.c107 static int rt6_score_route(const struct fib6_nh *nh, u32 fib6_flags, int oif,
472 if (hash <= atomic_read(&first->fib6_nh->fib_nh_upper_bound)) { in fib6_select_path()
473 if (rt6_score_route(first->fib6_nh, first->fib6_flags, oif, in fib6_select_path()
481 const struct fib6_nh *nh = sibling->fib6_nh; in fib6_select_path()
495 res->nh = match->fib6_nh; in fib6_select_path()
502 static bool __rt6_device_match(struct net *net, const struct fib6_nh *nh, in __rt6_device_match()
528 struct fib6_nh *nh;
531 static int __rt6_nh_dev_match(struct fib6_nh *nh, void *_arg) in __rt6_nh_dev_match()
541 static struct fib6_nh *rt6_nh_dev_match(struct net *net, struct nexthop *nh, in rt6_nh_dev_match()
567 struct fib6_nh *nh; in rt6_device_match()
[all …]
H A Dip6_fib.c153 sz += sizeof(struct fib6_nh); in fib6_info_alloc()
177 fib6_nh_release(f6i->fib6_nh); in fib6_info_destroy_rcu()
978 static void __fib6_drop_pcpu_from(struct fib6_nh *fib6_nh, in __fib6_drop_pcpu_from() argument
983 if (!fib6_nh->rt6i_pcpu) in __fib6_drop_pcpu_from()
994 ppcpu_rt = per_cpu_ptr(fib6_nh->rt6i_pcpu, cpu); in __fib6_drop_pcpu_from()
1014 static int fib6_nh_drop_pcpu_from(struct fib6_nh *nh, void *_arg) in fib6_nh_drop_pcpu_from()
1035 struct fib6_nh *fib6_nh; in fib6_drop_pcpu_from() local
1037 fib6_nh = f6i->fib6_nh; in fib6_drop_pcpu_from()
1038 __fib6_drop_pcpu_from(fib6_nh, f6i); in fib6_drop_pcpu_from()
1153 (iter->nh || !iter->fib6_nh->fib_nh_gw_family)) { in fib6_add_rt2node()
[all …]
H A Dndisc.c1352 neigh = ip6_neigh_lookup(&rt->fib6_nh->fib_nh_gw6, in ndisc_router_discovery()
1353 rt->fib6_nh->fib_nh_dev, NULL, in ndisc_router_discovery()
1386 neigh = ip6_neigh_lookup(&rt->fib6_nh->fib_nh_gw6, in ndisc_router_discovery()
1387 rt->fib6_nh->fib_nh_dev, NULL, in ndisc_router_discovery()
H A Daddrconf.c2517 if (rt->fib6_nh->fib_nh_dev->ifindex != dev->ifindex) in addrconf_get_prefix_route()
2519 if (no_gw && rt->fib6_nh->fib_nh_gw_family) in addrconf_get_prefix_route()
6684 struct fib6_nh *nh = ifa->rt->fib6_nh; in addrconf_disable_policy_idev()
/linux/include/net/
H A Dip6_fib.h147 struct fib6_nh { struct
204 struct fib6_nh fib6_nh[]; member
223 struct fib6_nh *nh;
490 int fib6_nh_init(struct net *net, struct fib6_nh *fib6_nh,
493 void fib6_nh_release(struct fib6_nh *fib6_nh);
494 void fib6_nh_release_dsts(struct fib6_nh *fib6_nh);
496 static inline int fib6_nh_init(struct net *net, struct fib6_nh *fib6_nh, in fib6_nh_init() argument
504 static inline void fib6_nh_release(struct fib6_nh *fib6_nh) in fib6_nh_release() argument
508 static inline void fib6_nh_release_dsts(struct fib6_nh *fib6_nh) in fib6_nh_release_dsts() argument
H A Dnexthop.h70 struct fib6_nh fib6_nh; member
403 BUILD_BUG_ON(offsetof(struct fib6_nh, nh_common) != 0); in nexthop_fib_nhc()
512 static inline struct fib6_nh *nexthop_fib6_nh(struct nexthop *nh) in nexthop_fib6_nh()
527 return &nhi->fib6_nh; in nexthop_fib6_nh()
534 struct fib6_nh *fib6_nh; in fib6_info_nh_dev()
536 fib6_nh = f6i->nh ? nexthop_fib6_nh(f6i->nh) : f6i->fib6_nh; in fib6_info_nh_dev()
537 return fib6_nh in fib6_info_nh_dev()
532 struct fib6_nh *fib6_nh; fib6_info_nh_dev() local
[all...]
/linux/net/ipv4/
H A Dnexthop.c513 fib6_nh_release(&nhi->fib6_nh); in nexthop_free_single()
918 struct fib6_nh *fib6_nh; in nh_fill_node() local
977 fib6_nh = &nhi->fib6_nh; in nh_fill_node()
978 if (fib6_nh->fib_nh_gw_family && in nh_fill_node()
979 nla_put_in6_addr(skb, NHA_GATEWAY, &fib6_nh->fib_nh_gw6)) in nh_fill_node()
1053 if (nhi->fib6_nh.fib_nh_gw_family) in nh_nlmsg_size_single()
1378 static bool ipv6_good_nh(const struct fib6_nh *nh) in ipv6_good_nh()
1419 return IS_ENABLED(CONFIG_IPV6) && ipv6_good_nh(&nhi->fib6_nh); in nexthop_is_good_nh()
1512 int (*cb)(struct fib6_nh *nh, void *arg), in nexthop_for_each_fib6_nh()
1527 err = cb(&nhi->fib6_nh, arg); in nexthop_for_each_fib6_nh()
[all …]
/linux/drivers/net/ethernet/mellanox/mlxsw/
H A Dspectrum_router.c3506 struct fib6_nh *fib6_nh = mlxsw_sp_rt6->rt->fib6_nh; in mlxsw_sp_nexthop6_group_cmp() local
3510 ifindex = fib6_nh->fib_nh_dev->ifindex; in mlxsw_sp_nexthop6_group_cmp()
3511 weight = fib6_nh->fib_nh_weight; in mlxsw_sp_nexthop6_group_cmp()
3512 gw = &fib6_nh->fib_nh_gw6; in mlxsw_sp_nexthop6_group_cmp()
3579 struct fib6_nh *fib6_nh = mlxsw_sp_rt6->rt->fib6_nh; in mlxsw_sp_nexthop6_group_hash() local
3580 struct net_device *dev = fib6_nh->fib_nh_dev; in mlxsw_sp_nexthop6_group_hash()
3581 struct in6_addr *gw = &fib6_nh->fib_nh_gw6; in mlxsw_sp_nexthop6_group_hash()
4066 struct fib6_nh *fib6_nh = mlxsw_sp_rt6->rt->fib6_nh; in __mlxsw_sp_nexthop6_group_offload_refresh() local
4071 fib6_nh->fib_nh_flags |= RTNH_F_OFFLOAD; in __mlxsw_sp_nexthop6_group_offload_refresh()
4073 fib6_nh->fib_nh_flags &= ~RTNH_F_OFFLOAD; in __mlxsw_sp_nexthop6_group_offload_refresh()
[all …]
/linux/drivers/net/ethernet/marvell/prestera/
H A Dprestera_router.c198 if (!fi->fib6_nh->nh_common.nhc_gw_family) in __prestera_fi6_is_direct()
332 return &fen6_info->rt->fib6_nh->nh_common; in prestera_kern_fib_info_nhc()
337 return &iter->fib6_nh->nh_common; in prestera_kern_fib_info_nhc()