/Linux-v5.4/include/net/ |
D | nexthop.h | 21 struct nexthop; 51 struct nexthop *nh_parent; 64 struct nexthop *nh; 69 struct nexthop *nh_parent; /* nexthop of group with this entry */ 79 struct nexthop { struct 102 struct nexthop *nexthop_find_by_id(struct net *net, u32 id); 105 static inline bool nexthop_get(struct nexthop *nh) in nexthop_get() 110 static inline void nexthop_put(struct nexthop *nh) in nexthop_put() 116 static inline bool nexthop_cmp(const struct nexthop *nh1, in nexthop_cmp() 117 const struct nexthop *nh2) in nexthop_cmp() [all …]
|
/Linux-v5.4/tools/testing/selftests/net/forwarding/ |
D | router_mpath_nh.sh | 19 ip route add 198.51.100.0/24 vrf vrf-h1 nexthop via 192.0.2.1 20 ip route add 2001:db8:2::/64 vrf vrf-h1 nexthop via 2001:db8:1::1 46 ip route add 192.0.2.0/24 vrf vrf-h2 nexthop via 198.51.100.1 47 ip route add 2001:db8:1::/64 vrf vrf-h2 nexthop via 2001:db8:2::1 98 ip nexthop del id 103 99 ip nexthop del id 101 100 ip nexthop del id 102 101 ip nexthop del id 106 102 ip nexthop del id 104 103 ip nexthop del id 105 [all …]
|
D | router_multipath.sh | 19 ip route add 198.51.100.0/24 vrf vrf-h1 nexthop via 192.0.2.1 20 ip route add 2001:db8:2::/64 vrf vrf-h1 nexthop via 2001:db8:1::1 46 ip route add 192.0.2.0/24 vrf vrf-h2 nexthop via 198.51.100.1 47 ip route add 2001:db8:1::/64 vrf vrf-h2 nexthop via 2001:db8:2::1 84 nexthop via 169.254.2.22 dev $rp12 \ 85 nexthop via 169.254.3.23 dev $rp13 87 nexthop via fe80:2::22 dev $rp12 \ 88 nexthop via fe80:3::23 dev $rp13 134 nexthop via 169.254.2.12 dev $rp22 \ 135 nexthop via 169.254.3.13 dev $rp23 [all …]
|
D | gre_inner_v4_multipath.sh | 103 ip route add vrf v$ol1 192.0.4.0/24 nexthop dev g1 127 nexthop via 192.0.2.146 \ 128 nexthop via 192.0.2.162 151 nexthop via 192.0.2.145 \ 152 nexthop via 192.0.2.161 183 ip route add vrf v$ol4 192.0.3.0/24 nexthop dev g2 262 nexthop via 192.0.2.146 weight $weight1 \ 263 nexthop via 192.0.2.162 weight $weight2 281 nexthop via 192.0.2.146 \ 282 nexthop via 192.0.2.162
|
D | ip6gre_inner_v4_multipath.sh | 102 ip route add vrf v$ol1 192.0.4.0/24 nexthop dev g1 126 nexthop via 2001:db8:81::2 \ 127 nexthop via 2001:db8:82::2 150 nexthop via 2001:db8:81::1 \ 151 nexthop via 2001:db8:82::1 182 ip route add vrf v$ol4 192.0.3.0/24 nexthop dev g2 261 nexthop via 2001:db8:81::2 weight $weight1 \ 262 nexthop via 2001:db8:82::2 weight $weight2 280 nexthop via 2001:db8:81::2 \ 281 nexthop via 2001:db8:82::2
|
D | gre_multipath.sh | 94 nexthop dev g1a \ 95 nexthop dev g1b 132 nexthop dev g2a \ 133 nexthop dev g2b 215 nexthop dev g1a weight $weight1 \ 216 nexthop dev g1b weight $weight2 233 nexthop dev g1a \ 234 nexthop dev g1b
|
D | gre_inner_v6_multipath.sh | 127 nexthop via 192.0.2.146 \ 128 nexthop via 192.0.2.162 151 nexthop via 192.0.2.145 \ 152 nexthop via 192.0.2.161 262 nexthop via 192.0.2.146 weight $weight1 \ 263 nexthop via 192.0.2.162 weight $weight2 282 nexthop via 192.0.2.146 \ 283 nexthop via 192.0.2.162
|
D | ip6gre_inner_v6_multipath.sh | 126 nexthop via 2001:db8:81::2 \ 127 nexthop via 2001:db8:82::2 150 nexthop via 2001:db8:81::1 \ 151 nexthop via 2001:db8:82::1 261 nexthop via 2001:db8:81::2 weight $weight1 \ 262 nexthop via 2001:db8:82::2 weight $weight2 281 nexthop via 2001:db8:81::2 \ 282 nexthop via 2001:db8:82::2
|
D | tc_flower_router.sh | 13 ip route add 192.0.2.0/24 vrf v$h1 nexthop via 192.0.1.2 14 ip route add 192.0.3.0/24 vrf v$h1 nexthop via 192.0.1.2 29 ip route add 192.0.1.0/24 vrf v$h2 nexthop via 192.0.2.2 30 ip route add 192.0.3.0/24 vrf v$h2 nexthop via 192.0.2.2 45 ip route add 192.0.1.0/24 vrf v$h3 nexthop via 192.0.3.2 46 ip route add 192.0.2.0/24 vrf v$h3 nexthop via 192.0.3.2
|
D | router_multicast.sh | 44 ip route add 198.51.100.16/28 vrf v$h1 nexthop via 198.51.100.1 45 ip route add 198.51.100.32/28 vrf v$h1 nexthop via 198.51.100.1 47 ip route add 2001:db8:2::/64 vrf v$h1 nexthop via 2001:db8:1::1 48 ip route add 2001:db8:3::/64 vrf v$h1 nexthop via 2001:db8:1::1 70 ip route add 198.51.100.0/28 vrf v$h2 nexthop via 198.51.100.17 71 ip route add 198.51.100.32/28 vrf v$h2 nexthop via 198.51.100.17 73 ip route add 2001:db8:1::/64 vrf v$h2 nexthop via 2001:db8:2::1 74 ip route add 2001:db8:3::/64 vrf v$h2 nexthop via 2001:db8:2::1 96 ip route add 198.51.100.0/28 vrf v$h3 nexthop via 198.51.100.33 97 ip route add 198.51.100.16/28 vrf v$h3 nexthop via 198.51.100.33 [all …]
|
D | router_bridge.sh | 14 ip -4 route add 192.0.2.128/28 vrf v$h1 nexthop via 192.0.2.2 15 ip -6 route add 2001:db8:2::/64 vrf v$h1 nexthop via 2001:db8:1::2 28 ip -4 route add 192.0.2.0/28 vrf v$h2 nexthop via 192.0.2.129 29 ip -6 route add 2001:db8:1::/64 vrf v$h2 nexthop via 2001:db8:2::1
|
D | router_bridge_vlan.sh | 16 ip -4 route add 192.0.2.128/28 vrf v$h1 nexthop via 192.0.2.2 17 ip -6 route add 2001:db8:2::/64 vrf v$h1 nexthop via 2001:db8:1::2 31 ip -4 route add 192.0.2.0/28 vrf v$h2 nexthop via 192.0.2.129 32 ip -6 route add 2001:db8:1::/64 vrf v$h2 nexthop via 2001:db8:2::1
|
D | router_broadcast.sh | 18 ip route add 198.51.100.0/24 vrf vrf-h1 nexthop via 192.0.2.1 19 ip route add 198.51.200.0/24 vrf vrf-h1 nexthop via 192.0.2.1 43 ip route add 192.0.2.0/24 vrf vrf-h2 nexthop via 198.51.100.1 44 ip route add 198.51.200.0/24 vrf vrf-h2 nexthop via 198.51.100.1 68 ip route add 192.0.2.0/24 vrf vrf-h3 nexthop via 198.51.200.1 69 ip route add 198.51.100.0/24 vrf vrf-h3 nexthop via 198.51.200.1
|
D | router_vid_1.sh | 16 ip route add 198.51.100.0/24 vrf vrf-h1 nexthop via 192.0.2.1 17 ip route add 2001:db8:2::/64 vrf vrf-h1 nexthop via 2001:db8:1::1 40 ip route add 192.0.2.0/24 vrf vrf-h2 nexthop via 198.51.100.1 41 ip route add 2001:db8:1::/64 vrf vrf-h2 nexthop via 2001:db8:2::1
|
D | router.sh | 19 ip route add 198.51.100.0/24 vrf vrf-h1 nexthop via 192.0.2.1 20 ip route add 2001:db8:2::/64 vrf vrf-h1 nexthop via 2001:db8:1::1 46 ip route add 192.0.2.0/24 vrf vrf-h2 nexthop via 198.51.100.1 47 ip route add 2001:db8:1::/64 vrf vrf-h2 nexthop via 2001:db8:2::1
|
D | vxlan_symmetric.sh | 129 ip route add default vrf $vrf_name nexthop via $gw_ip 140 ip route del default vrf $vrf_name nexthop via $gw_ip 179 ip route add 10.0.0.2/32 nexthop via 192.0.2.2 287 ip route del 10.0.0.2/32 nexthop via 192.0.2.2 307 ip route add 10.0.0.1/32 vrf vrf-spine nexthop via 192.0.2.1 308 ip route add 10.0.0.2/32 vrf vrf-spine nexthop via 192.0.3.1 313 ip route del 10.0.0.2/32 vrf vrf-spine nexthop via 192.0.3.1 314 ip route del 10.0.0.1/32 vrf vrf-spine nexthop via 192.0.2.1 344 ip route add 10.0.0.1/32 nexthop via 192.0.3.2 477 ip route add $host1_ip/32 vrf vrf-green nexthop via $vtep_ip \ [all …]
|
D | ipip_lib.sh | 188 ip route add 192.0.2.16/28 nexthop dev g1a 222 ip route add vrf v$ol2 192.0.2.0/28 nexthop dev g2a 258 ip route add vrf v$ol1 192.0.2.16/28 nexthop dev g1a 297 ip route add vrf v$ol2 192.0.2.0/28 nexthop dev g2a
|
D | vxlan_asymmetric.sh | 119 ip route add default vrf $vrf_name nexthop via $gw_ip 130 ip route del default vrf $vrf_name nexthop via $gw_ip 169 ip route add 10.0.0.2/32 nexthop via 192.0.2.2 256 ip route del 10.0.0.2/32 nexthop via 192.0.2.2 276 ip route add 10.0.0.1/32 vrf vrf-spine nexthop via 192.0.2.1 277 ip route add 10.0.0.2/32 vrf vrf-spine nexthop via 192.0.3.1 282 ip route del 10.0.0.2/32 vrf vrf-spine nexthop via 192.0.3.1 283 ip route del 10.0.0.1/32 vrf vrf-spine nexthop via 192.0.2.1 313 ip route add 10.0.0.1/32 nexthop via 192.0.3.2
|
/Linux-v5.4/tools/testing/selftests/drivers/net/mlxsw/ |
D | fib_offload.sh | 118 nexthop via 2001:db8:1::2 dev $spine_p1 \ 119 nexthop via 2001:db8:2::2 dev $spine_p2 125 nexthop via 2001:db8:1::3 dev $spine_p1 133 nexthop via 2001:db8:1::2 dev $spine_p1 \ 134 nexthop via 2001:db8:2::2 dev $spine_p2 141 nexthop via 2001:db8:1::3 dev $spine_p1 150 nexthop via 2001:db8:1::3 dev $spine_p1 183 nexthop via 2001:db8:1::2 dev $spine_p1 \ 184 nexthop via 2001:db8:2::2 dev $spine_p2 198 nexthop via 2001:db8:1::3 dev $spine_p1 \ [all …]
|
D | blackhole_routes.sh | 55 ip -4 route add default vrf v$h1 nexthop via 192.0.2.2 56 ip -6 route add default vrf v$h1 nexthop via 2001:db8:1::2 61 ip -6 route del default vrf v$h1 nexthop via 2001:db8:1::2 62 ip -4 route del default vrf v$h1 nexthop via 192.0.2.2 71 ip -4 route add default vrf v$h2 nexthop via 198.51.100.2 72 ip -6 route add default vrf v$h2 nexthop via 2001:db8:2::2 77 ip -6 route del default vrf v$h2 nexthop via 2001:db8:2::2 78 ip -4 route del default vrf v$h2 nexthop via 198.51.100.2
|
D | one_armed_router.sh | 56 ip -4 route add default vrf v$h1 nexthop via 192.0.2.2 57 ip -6 route add default vrf v$h1 nexthop via 2001:db8:1::2 62 ip -6 route del default vrf v$h1 nexthop via 2001:db8:1::2 63 ip -4 route del default vrf v$h1 nexthop via 192.0.2.2 72 ip -4 route add default vrf v$h2 nexthop via 198.51.100.2 73 ip -6 route add default vrf v$h2 nexthop via 2001:db8:2::2 78 ip -6 route del default vrf v$h2 nexthop via 2001:db8:2::2 79 ip -4 route del default vrf v$h2 nexthop via 198.51.100.2
|
/Linux-v5.4/net/ipv4/ |
D | nexthop.c | 19 static void remove_nexthop(struct net *net, struct nexthop *nh, 57 head = &net->nexthop.devhash[hash]; in nexthop_devhash_add() 61 static void nexthop_free_mpath(struct nexthop *nh) in nexthop_free_mpath() 73 static void nexthop_free_single(struct nexthop *nh) in nexthop_free_single() 91 struct nexthop *nh = container_of(head, struct nexthop, rcu); in nexthop_free_rcu() 102 static struct nexthop *nexthop_alloc(void) in nexthop_alloc() 104 struct nexthop *nh; in nexthop_alloc() 106 nh = kzalloc(sizeof(struct nexthop), GFP_KERNEL); in nexthop_alloc() 117 size_t sz = offsetof(struct nexthop, nh_grp) in nexthop_grp_alloc() 131 while (++net->nexthop.seq == 0) in nh_base_seq_inc() [all …]
|
D | ip_options.c | 592 if (memcmp(&opt->nexthop, &optptr[srrptr-1], 4) == 0) in ip_forward_options() 597 ip_hdr(skb)->daddr = opt->nexthop; in ip_forward_options() 620 __be32 nexthop; in ip_options_rcv_srr() local 647 memcpy(&nexthop, &optptr[srrptr-1], 4); in ip_options_rcv_srr() 651 err = ip_route_input(skb, nexthop, iph->saddr, iph->tos, dev); in ip_options_rcv_srr() 662 iph->daddr = nexthop; in ip_options_rcv_srr() 667 opt->nexthop = nexthop; in ip_options_rcv_srr()
|
/Linux-v5.4/tools/testing/selftests/net/ |
D | icmp_redirect.sh | 337 run_cmd ip -netns r1 nexthop replace id 1 via ${R2_N1_IP} dev eth0 338 run_cmd ip -netns r1 nexthop replace id 2 via ${R2_LLADDR} dev eth0 343 run_cmd ip -netns r1 nexthop flush 344 run_cmd ip -netns h1 nexthop flush 352 run_cmd ip -netns r1 nexthop add id 1 via ${R2_R1_N1_IP} dev eth1 355 run_cmd ip -netns r1 nexthop add id 2 via ${R2_R1_N1_IP6} dev eth1 359 run_cmd ip -netns h1 nexthop add id 1 via ${R1_N1_IP} dev br0 362 run_cmd ip -netns h1 nexthop add id 2 via ${R1_LLADDR} dev br0 516 ip nexthop ls >/dev/null 2>&1
|
D | fib_nexthops.sh | 229 out=$($IP nexthop ls ${nharg} 2>/dev/null) 334 $IP nexthop flush >/dev/null 2>&1 374 $IP nexthop flush >/dev/null 2>&1 507 $IP nexthop flush >/dev/null 2>&1 598 $IP nexthop flush >/dev/null 2>&1 636 $IP nexthop flush >/dev/null 2>&1 960 $IP nexthop flush >/dev/null 2>&1 1017 ip help 2>&1 | grep -q nexthop 1023 out=$(ip nexthop ls 2>&1 | grep -q "Operation not supported")
|