Lines Matching refs:ipv6
344 struct rt6_info *rt = dst_alloc(&net->ipv6.ip6_dst_ops, dev, in ip6_dst_alloc()
349 atomic_inc(&net->ipv6.rt6_stats->fib_rt_alloc); in ip6_dst_alloc()
565 res->f6i = net->ipv6.fib6_null_entry; in rt6_device_match()
579 res->f6i = net->ipv6.fib6_null_entry; in rt6_device_match()
874 if (!leaf || leaf == net->ipv6.fib6_null_entry) in rt6_select()
913 res->f6i = net->ipv6.fib6_null_entry; in rt6_select()
1166 rt = net->ipv6.ip6_null_entry; in ip6_hold_safe()
1197 nrt = dev_net(dev)->ipv6.ip6_null_entry; in ip6_create_rt_rcu()
1217 res.f6i = net->ipv6.fib6_null_entry; in ip6_pol_route_lookup()
1222 if (res.f6i == net->ipv6.fib6_null_entry) { in ip6_pol_route_lookup()
1227 rt = net->ipv6.ip6_null_entry; in ip6_pol_route_lookup()
1452 net->ipv6.rt6_stats->fib_rt_cache--; in rt6_remove_exception()
1713 net->ipv6.rt6_stats->fib_rt_cache++; in rt6_insert_exception()
2183 if (res->f6i == net->ipv6.fib6_null_entry) { in fib6_table_lookup()
2213 if (net->ipv6.devconf_all->forwarding == 0) in ip6_pol_route()
2219 if (res.f6i == net->ipv6.fib6_null_entry) in ip6_pol_route()
2260 rt = net->ipv6.ip6_null_entry; in ip6_pol_route()
2642 dst = &net->ipv6.ip6_null_entry->dst; in ip6_route_output_flags()
2661 atomic_inc(&net->ipv6.rt6_stats->fib_rt_alloc); in ip6_blackhole_route()
2830 rt6_update_expires(rt, net->ipv6.sysctl.ip6_rt_mtu_expires); in rt6_do_update_pmtu()
3091 rt = net->ipv6.fib6_null_entry; in __ip6_route_redirect()
3093 ret = net->ipv6.ip6_null_entry; in __ip6_route_redirect()
3097 if (rt == net->ipv6.fib6_null_entry) { in __ip6_route_redirect()
3189 if (mtu < net->ipv6.sysctl.ip6_rt_min_advmss) in ip6_default_advmss()
3190 mtu = net->ipv6.sysctl.ip6_rt_min_advmss; in ip6_default_advmss()
3289 struct net *net = container_of(ops, struct net, ipv6.ip6_dst_ops); in ip6_dst_gc()
3290 int rt_min_interval = net->ipv6.sysctl.ip6_rt_gc_min_interval; in ip6_dst_gc()
3291 int rt_max_size = net->ipv6.sysctl.ip6_rt_max_size; in ip6_dst_gc()
3292 int rt_elasticity = net->ipv6.sysctl.ip6_rt_gc_elasticity; in ip6_dst_gc()
3293 int rt_gc_timeout = net->ipv6.sysctl.ip6_rt_gc_timeout; in ip6_dst_gc()
3294 unsigned long rt_last_gc = net->ipv6.ip6_rt_last_gc; in ip6_dst_gc()
3306 fib6_run_gc(atomic_inc_return(&net->ipv6.ip6_rt_gc_expire), net, true); in ip6_dst_gc()
3309 atomic_set(&net->ipv6.ip6_rt_gc_expire, rt_gc_timeout >> 1); in ip6_dst_gc()
3311 val = atomic_read(&net->ipv6.ip6_rt_gc_expire); in ip6_dst_gc()
3312 atomic_set(&net->ipv6.ip6_rt_gc_expire, val - (val >> rt_elasticity)); in ip6_dst_gc()
3338 if (!err && res->f6i != net->ipv6.fib6_null_entry) in ip6_nh_lookup_table()
3859 if (rt == net->ipv6.fib6_null_entry) { in __ip6_del_rt()
3892 if (rt == net->ipv6.fib6_null_entry) in __ip6_del_rt_siblings()
4419 head = &net->ipv6.fib_table_hash[h]; in rt6_purge_dflt_routers()
4576 (net->ipv6.devconf_all->disable_policy || in addrconf_f6i_alloc()
4599 rt != net->ipv6.fib6_null_entry && in fib6_remove_prefsrc()
4758 if (rt != net->ipv6.fib6_null_entry && !rt->nh && in fib6_ifup()
4844 if (rt == net->ipv6.fib6_null_entry || rt->nh) in fib6_ifdown()
4891 if (net->ipv6.sysctl.skip_notify_on_dev_down) in rt6_sync_down_dev()
5891 if (rt == net->ipv6.fib6_null_entry) in rt6_dump_route()
6118 if (rt == net->ipv6.ip6_null_entry) { in inet6_rtm_getroute()
6234 if (net->ipv6.sysctl.fib_notify_on_flag_change == 2 && in fib6_info_hw_flags_set()
6246 if (!net->ipv6.sysctl.fib_notify_on_flag_change) in fib6_info_hw_flags_set()
6282 net->ipv6.fib6_null_entry->fib6_nh->fib_nh_dev = dev; in ip6_route_dev_notify()
6283 net->ipv6.ip6_null_entry->dst.dev = dev; in ip6_route_dev_notify()
6284 net->ipv6.ip6_null_entry->rt6i_idev = in6_dev_get(dev); in ip6_route_dev_notify()
6286 net->ipv6.ip6_prohibit_entry->dst.dev = dev; in ip6_route_dev_notify()
6287 net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev); in ip6_route_dev_notify()
6288 net->ipv6.ip6_blk_hole_entry->dst.dev = dev; in ip6_route_dev_notify()
6289 net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev); in ip6_route_dev_notify()
6296 in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev); in ip6_route_dev_notify()
6298 in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev); in ip6_route_dev_notify()
6299 in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev); in ip6_route_dev_notify()
6315 net->ipv6.rt6_stats->fib_nodes, in rt6_stats_seq_show()
6316 net->ipv6.rt6_stats->fib_route_nodes, in rt6_stats_seq_show()
6317 atomic_read(&net->ipv6.rt6_stats->fib_rt_alloc), in rt6_stats_seq_show()
6318 net->ipv6.rt6_stats->fib_rt_entries, in rt6_stats_seq_show()
6319 net->ipv6.rt6_stats->fib_rt_cache, in rt6_stats_seq_show()
6320 dst_entries_get_slow(&net->ipv6.ip6_dst_ops), in rt6_stats_seq_show()
6321 net->ipv6.rt6_stats->fib_discarded_routes); in rt6_stats_seq_show()
6339 delay = net->ipv6.sysctl.flush_delay; in ipv6_sysctl_rtcache_flush()
6351 .data = &init_net.ipv6.sysctl.ip6_rt_max_size,
6365 .data = &init_net.ipv6.sysctl.flush_delay,
6372 .data = &init_net.ipv6.sysctl.ip6_rt_gc_min_interval,
6379 .data = &init_net.ipv6.sysctl.ip6_rt_gc_timeout,
6386 .data = &init_net.ipv6.sysctl.ip6_rt_gc_interval,
6393 .data = &init_net.ipv6.sysctl.ip6_rt_gc_elasticity,
6400 .data = &init_net.ipv6.sysctl.ip6_rt_mtu_expires,
6407 .data = &init_net.ipv6.sysctl.ip6_rt_min_advmss,
6414 .data = &init_net.ipv6.sysctl.ip6_rt_gc_min_interval,
6421 .data = &init_net.ipv6.sysctl.skip_notify_on_dev_down,
6440 table[0].data = &net->ipv6.sysctl.ip6_rt_max_size; in ipv6_route_sysctl_init()
6441 table[1].data = &net->ipv6.ip6_dst_ops.gc_thresh; in ipv6_route_sysctl_init()
6442 table[2].data = &net->ipv6.sysctl.flush_delay; in ipv6_route_sysctl_init()
6444 table[3].data = &net->ipv6.sysctl.ip6_rt_gc_min_interval; in ipv6_route_sysctl_init()
6445 table[4].data = &net->ipv6.sysctl.ip6_rt_gc_timeout; in ipv6_route_sysctl_init()
6446 table[5].data = &net->ipv6.sysctl.ip6_rt_gc_interval; in ipv6_route_sysctl_init()
6447 table[6].data = &net->ipv6.sysctl.ip6_rt_gc_elasticity; in ipv6_route_sysctl_init()
6448 table[7].data = &net->ipv6.sysctl.ip6_rt_mtu_expires; in ipv6_route_sysctl_init()
6449 table[8].data = &net->ipv6.sysctl.ip6_rt_min_advmss; in ipv6_route_sysctl_init()
6450 table[9].data = &net->ipv6.sysctl.ip6_rt_gc_min_interval; in ipv6_route_sysctl_init()
6451 table[10].data = &net->ipv6.sysctl.skip_notify_on_dev_down; in ipv6_route_sysctl_init()
6466 memcpy(&net->ipv6.ip6_dst_ops, &ip6_dst_ops_template, in ip6_route_net_init()
6467 sizeof(net->ipv6.ip6_dst_ops)); in ip6_route_net_init()
6469 if (dst_entries_init(&net->ipv6.ip6_dst_ops) < 0) in ip6_route_net_init()
6472 net->ipv6.fib6_null_entry = fib6_info_alloc(GFP_KERNEL, true); in ip6_route_net_init()
6473 if (!net->ipv6.fib6_null_entry) in ip6_route_net_init()
6475 memcpy(net->ipv6.fib6_null_entry, &fib6_null_entry_template, in ip6_route_net_init()
6476 sizeof(*net->ipv6.fib6_null_entry)); in ip6_route_net_init()
6478 net->ipv6.ip6_null_entry = kmemdup(&ip6_null_entry_template, in ip6_route_net_init()
6479 sizeof(*net->ipv6.ip6_null_entry), in ip6_route_net_init()
6481 if (!net->ipv6.ip6_null_entry) in ip6_route_net_init()
6483 net->ipv6.ip6_null_entry->dst.ops = &net->ipv6.ip6_dst_ops; in ip6_route_net_init()
6484 dst_init_metrics(&net->ipv6.ip6_null_entry->dst, in ip6_route_net_init()
6486 INIT_LIST_HEAD(&net->ipv6.ip6_null_entry->rt6i_uncached); in ip6_route_net_init()
6489 net->ipv6.fib6_has_custom_rules = false; in ip6_route_net_init()
6490 net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template, in ip6_route_net_init()
6491 sizeof(*net->ipv6.ip6_prohibit_entry), in ip6_route_net_init()
6493 if (!net->ipv6.ip6_prohibit_entry) in ip6_route_net_init()
6495 net->ipv6.ip6_prohibit_entry->dst.ops = &net->ipv6.ip6_dst_ops; in ip6_route_net_init()
6496 dst_init_metrics(&net->ipv6.ip6_prohibit_entry->dst, in ip6_route_net_init()
6498 INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->rt6i_uncached); in ip6_route_net_init()
6500 net->ipv6.ip6_blk_hole_entry = kmemdup(&ip6_blk_hole_entry_template, in ip6_route_net_init()
6501 sizeof(*net->ipv6.ip6_blk_hole_entry), in ip6_route_net_init()
6503 if (!net->ipv6.ip6_blk_hole_entry) in ip6_route_net_init()
6505 net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops; in ip6_route_net_init()
6506 dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst, in ip6_route_net_init()
6508 INIT_LIST_HEAD(&net->ipv6.ip6_blk_hole_entry->rt6i_uncached); in ip6_route_net_init()
6510 net->ipv6.fib6_routes_require_src = 0; in ip6_route_net_init()
6514 net->ipv6.sysctl.flush_delay = 0; in ip6_route_net_init()
6515 net->ipv6.sysctl.ip6_rt_max_size = 4096; in ip6_route_net_init()
6516 net->ipv6.sysctl.ip6_rt_gc_min_interval = HZ / 2; in ip6_route_net_init()
6517 net->ipv6.sysctl.ip6_rt_gc_timeout = 60*HZ; in ip6_route_net_init()
6518 net->ipv6.sysctl.ip6_rt_gc_interval = 30*HZ; in ip6_route_net_init()
6519 net->ipv6.sysctl.ip6_rt_gc_elasticity = 9; in ip6_route_net_init()
6520 net->ipv6.sysctl.ip6_rt_mtu_expires = 10*60*HZ; in ip6_route_net_init()
6521 net->ipv6.sysctl.ip6_rt_min_advmss = IPV6_MIN_MTU - 20 - 40; in ip6_route_net_init()
6522 net->ipv6.sysctl.skip_notify_on_dev_down = 0; in ip6_route_net_init()
6524 atomic_set(&net->ipv6.ip6_rt_gc_expire, 30*HZ); in ip6_route_net_init()
6532 kfree(net->ipv6.ip6_prohibit_entry); in ip6_route_net_init()
6534 kfree(net->ipv6.ip6_null_entry); in ip6_route_net_init()
6537 kfree(net->ipv6.fib6_null_entry); in ip6_route_net_init()
6539 dst_entries_destroy(&net->ipv6.ip6_dst_ops); in ip6_route_net_init()
6546 kfree(net->ipv6.fib6_null_entry); in ip6_route_net_exit()
6547 kfree(net->ipv6.ip6_null_entry); in ip6_route_net_exit()
6549 kfree(net->ipv6.ip6_prohibit_entry); in ip6_route_net_exit()
6550 kfree(net->ipv6.ip6_blk_hole_entry); in ip6_route_net_exit()
6552 dst_entries_destroy(&net->ipv6.ip6_dst_ops); in ip6_route_net_exit()
6592 net->ipv6.peers = bp; in ipv6_inetpeer_init()
6598 struct inet_peer_base *bp = net->ipv6.peers; in ipv6_inetpeer_exit()
6600 net->ipv6.peers = NULL; in ipv6_inetpeer_exit()
6625 init_net.ipv6.fib6_null_entry->fib6_nh->fib_nh_dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6626 init_net.ipv6.ip6_null_entry->dst.dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6627 init_net.ipv6.ip6_null_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); in ip6_route_init_special_entries()
6629 init_net.ipv6.ip6_prohibit_entry->dst.dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6630 init_net.ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); in ip6_route_init_special_entries()
6631 init_net.ipv6.ip6_blk_hole_entry->dst.dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6632 init_net.ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); in ip6_route_init_special_entries()