Lines Matching refs:ipv6
156 atomic_dec(&net->ipv6.rt6_stats->fib_rt_uncache); in rt6_uncached_list_del()
341 struct rt6_info *rt = dst_alloc(&net->ipv6.ip6_dst_ops, dev, in ip6_dst_alloc()
346 atomic_inc(&net->ipv6.rt6_stats->fib_rt_alloc); in ip6_dst_alloc()
563 res->f6i = net->ipv6.fib6_null_entry; in rt6_device_match()
577 res->f6i = net->ipv6.fib6_null_entry; in rt6_device_match()
871 if (!leaf || leaf == net->ipv6.fib6_null_entry) in rt6_select()
910 res->f6i = net->ipv6.fib6_null_entry; in rt6_select()
1163 rt = net->ipv6.ip6_null_entry; in ip6_hold_safe()
1194 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()
2186 if (res->f6i == net->ipv6.fib6_null_entry) { in fib6_table_lookup()
2216 if (net->ipv6.devconf_all->forwarding == 0) in ip6_pol_route()
2222 if (res.f6i == net->ipv6.fib6_null_entry) in ip6_pol_route()
2247 atomic_inc(&net->ipv6.rt6_stats->fib_rt_uncache); in ip6_pol_route()
2264 rt = net->ipv6.ip6_null_entry; in ip6_pol_route()
2646 dst = &net->ipv6.ip6_null_entry->dst; in ip6_route_output_flags()
2665 atomic_inc(&net->ipv6.rt6_stats->fib_rt_alloc); in ip6_blackhole_route()
2834 rt6_update_expires(rt, net->ipv6.sysctl.ip6_rt_mtu_expires); in rt6_do_update_pmtu()
3101 rt = net->ipv6.fib6_null_entry; in __ip6_route_redirect()
3103 ret = net->ipv6.ip6_null_entry; in __ip6_route_redirect()
3107 if (rt == net->ipv6.fib6_null_entry) { in __ip6_route_redirect()
3199 if (mtu < net->ipv6.sysctl.ip6_rt_min_advmss) in ip6_default_advmss()
3200 mtu = net->ipv6.sysctl.ip6_rt_min_advmss; in ip6_default_advmss()
3290 atomic_inc(&net->ipv6.rt6_stats->fib_rt_uncache); in icmp6_dst_alloc()
3300 struct net *net = container_of(ops, struct net, ipv6.ip6_dst_ops); in ip6_dst_gc()
3301 int rt_min_interval = net->ipv6.sysctl.ip6_rt_gc_min_interval; in ip6_dst_gc()
3302 int rt_max_size = net->ipv6.sysctl.ip6_rt_max_size; in ip6_dst_gc()
3303 int rt_elasticity = net->ipv6.sysctl.ip6_rt_gc_elasticity; in ip6_dst_gc()
3304 int rt_gc_timeout = net->ipv6.sysctl.ip6_rt_gc_timeout; in ip6_dst_gc()
3305 unsigned long rt_last_gc = net->ipv6.ip6_rt_last_gc; in ip6_dst_gc()
3316 net->ipv6.ip6_rt_gc_expire++; in ip6_dst_gc()
3317 fib6_run_gc(net->ipv6.ip6_rt_gc_expire, net, true); in ip6_dst_gc()
3320 net->ipv6.ip6_rt_gc_expire = rt_gc_timeout>>1; in ip6_dst_gc()
3322 net->ipv6.ip6_rt_gc_expire -= net->ipv6.ip6_rt_gc_expire>>rt_elasticity; in ip6_dst_gc()
3348 if (!err && res->f6i != net->ipv6.fib6_null_entry) in ip6_nh_lookup_table()
3864 if (rt == net->ipv6.fib6_null_entry) { in __ip6_del_rt()
3897 if (rt == net->ipv6.fib6_null_entry) in __ip6_del_rt_siblings()
4424 head = &net->ipv6.fib_table_hash[h]; in rt6_purge_dflt_routers()
4593 rt != net->ipv6.fib6_null_entry && in fib6_remove_prefsrc()
4752 if (rt != net->ipv6.fib6_null_entry && !rt->nh && in fib6_ifup()
4838 if (rt == net->ipv6.fib6_null_entry || rt->nh) in fib6_ifdown()
4885 if (net->ipv6.sysctl.skip_notify_on_dev_down) in rt6_sync_down_dev()
5851 if (rt == net->ipv6.fib6_null_entry) in rt6_dump_route()
6078 if (rt == net->ipv6.ip6_null_entry) { in inet6_rtm_getroute()
6193 if (net->ipv6.sysctl.fib_notify_on_flag_change == 2 && in fib6_info_hw_flags_set()
6205 if (!net->ipv6.sysctl.fib_notify_on_flag_change) in fib6_info_hw_flags_set()
6241 net->ipv6.fib6_null_entry->fib6_nh->fib_nh_dev = dev; in ip6_route_dev_notify()
6242 net->ipv6.ip6_null_entry->dst.dev = dev; in ip6_route_dev_notify()
6243 net->ipv6.ip6_null_entry->rt6i_idev = in6_dev_get(dev); in ip6_route_dev_notify()
6245 net->ipv6.ip6_prohibit_entry->dst.dev = dev; in ip6_route_dev_notify()
6246 net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev); in ip6_route_dev_notify()
6247 net->ipv6.ip6_blk_hole_entry->dst.dev = dev; in ip6_route_dev_notify()
6248 net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev); in ip6_route_dev_notify()
6255 in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev); in ip6_route_dev_notify()
6257 in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev); in ip6_route_dev_notify()
6258 in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev); in ip6_route_dev_notify()
6274 net->ipv6.rt6_stats->fib_nodes, in rt6_stats_seq_show()
6275 net->ipv6.rt6_stats->fib_route_nodes, in rt6_stats_seq_show()
6276 atomic_read(&net->ipv6.rt6_stats->fib_rt_alloc), in rt6_stats_seq_show()
6277 net->ipv6.rt6_stats->fib_rt_entries, in rt6_stats_seq_show()
6278 net->ipv6.rt6_stats->fib_rt_cache, in rt6_stats_seq_show()
6279 dst_entries_get_slow(&net->ipv6.ip6_dst_ops), in rt6_stats_seq_show()
6280 net->ipv6.rt6_stats->fib_discarded_routes); in rt6_stats_seq_show()
6298 delay = net->ipv6.sysctl.flush_delay; in ipv6_sysctl_rtcache_flush()
6310 .data = &init_net.ipv6.sysctl.flush_delay,
6324 .data = &init_net.ipv6.sysctl.ip6_rt_max_size,
6331 .data = &init_net.ipv6.sysctl.ip6_rt_gc_min_interval,
6338 .data = &init_net.ipv6.sysctl.ip6_rt_gc_timeout,
6345 .data = &init_net.ipv6.sysctl.ip6_rt_gc_interval,
6352 .data = &init_net.ipv6.sysctl.ip6_rt_gc_elasticity,
6359 .data = &init_net.ipv6.sysctl.ip6_rt_mtu_expires,
6366 .data = &init_net.ipv6.sysctl.ip6_rt_min_advmss,
6373 .data = &init_net.ipv6.sysctl.ip6_rt_gc_min_interval,
6380 .data = &init_net.ipv6.sysctl.skip_notify_on_dev_down,
6399 table[0].data = &net->ipv6.sysctl.flush_delay; in ipv6_route_sysctl_init()
6401 table[1].data = &net->ipv6.ip6_dst_ops.gc_thresh; in ipv6_route_sysctl_init()
6402 table[2].data = &net->ipv6.sysctl.ip6_rt_max_size; in ipv6_route_sysctl_init()
6403 table[3].data = &net->ipv6.sysctl.ip6_rt_gc_min_interval; in ipv6_route_sysctl_init()
6404 table[4].data = &net->ipv6.sysctl.ip6_rt_gc_timeout; in ipv6_route_sysctl_init()
6405 table[5].data = &net->ipv6.sysctl.ip6_rt_gc_interval; in ipv6_route_sysctl_init()
6406 table[6].data = &net->ipv6.sysctl.ip6_rt_gc_elasticity; in ipv6_route_sysctl_init()
6407 table[7].data = &net->ipv6.sysctl.ip6_rt_mtu_expires; in ipv6_route_sysctl_init()
6408 table[8].data = &net->ipv6.sysctl.ip6_rt_min_advmss; in ipv6_route_sysctl_init()
6409 table[9].data = &net->ipv6.sysctl.ip6_rt_gc_min_interval; in ipv6_route_sysctl_init()
6410 table[10].data = &net->ipv6.sysctl.skip_notify_on_dev_down; in ipv6_route_sysctl_init()
6425 memcpy(&net->ipv6.ip6_dst_ops, &ip6_dst_ops_template, in ip6_route_net_init()
6426 sizeof(net->ipv6.ip6_dst_ops)); in ip6_route_net_init()
6428 if (dst_entries_init(&net->ipv6.ip6_dst_ops) < 0) in ip6_route_net_init()
6431 net->ipv6.fib6_null_entry = fib6_info_alloc(GFP_KERNEL, true); in ip6_route_net_init()
6432 if (!net->ipv6.fib6_null_entry) in ip6_route_net_init()
6434 memcpy(net->ipv6.fib6_null_entry, &fib6_null_entry_template, in ip6_route_net_init()
6435 sizeof(*net->ipv6.fib6_null_entry)); in ip6_route_net_init()
6437 net->ipv6.ip6_null_entry = kmemdup(&ip6_null_entry_template, in ip6_route_net_init()
6438 sizeof(*net->ipv6.ip6_null_entry), in ip6_route_net_init()
6440 if (!net->ipv6.ip6_null_entry) in ip6_route_net_init()
6442 net->ipv6.ip6_null_entry->dst.ops = &net->ipv6.ip6_dst_ops; in ip6_route_net_init()
6443 dst_init_metrics(&net->ipv6.ip6_null_entry->dst, in ip6_route_net_init()
6445 INIT_LIST_HEAD(&net->ipv6.ip6_null_entry->rt6i_uncached); in ip6_route_net_init()
6448 net->ipv6.fib6_has_custom_rules = false; in ip6_route_net_init()
6449 net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template, in ip6_route_net_init()
6450 sizeof(*net->ipv6.ip6_prohibit_entry), in ip6_route_net_init()
6452 if (!net->ipv6.ip6_prohibit_entry) in ip6_route_net_init()
6454 net->ipv6.ip6_prohibit_entry->dst.ops = &net->ipv6.ip6_dst_ops; in ip6_route_net_init()
6455 dst_init_metrics(&net->ipv6.ip6_prohibit_entry->dst, in ip6_route_net_init()
6457 INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->rt6i_uncached); in ip6_route_net_init()
6459 net->ipv6.ip6_blk_hole_entry = kmemdup(&ip6_blk_hole_entry_template, in ip6_route_net_init()
6460 sizeof(*net->ipv6.ip6_blk_hole_entry), in ip6_route_net_init()
6462 if (!net->ipv6.ip6_blk_hole_entry) in ip6_route_net_init()
6464 net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops; in ip6_route_net_init()
6465 dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst, in ip6_route_net_init()
6467 INIT_LIST_HEAD(&net->ipv6.ip6_blk_hole_entry->rt6i_uncached); in ip6_route_net_init()
6469 net->ipv6.fib6_routes_require_src = 0; in ip6_route_net_init()
6473 net->ipv6.sysctl.flush_delay = 0; in ip6_route_net_init()
6474 net->ipv6.sysctl.ip6_rt_max_size = 4096; in ip6_route_net_init()
6475 net->ipv6.sysctl.ip6_rt_gc_min_interval = HZ / 2; in ip6_route_net_init()
6476 net->ipv6.sysctl.ip6_rt_gc_timeout = 60*HZ; in ip6_route_net_init()
6477 net->ipv6.sysctl.ip6_rt_gc_interval = 30*HZ; in ip6_route_net_init()
6478 net->ipv6.sysctl.ip6_rt_gc_elasticity = 9; in ip6_route_net_init()
6479 net->ipv6.sysctl.ip6_rt_mtu_expires = 10*60*HZ; in ip6_route_net_init()
6480 net->ipv6.sysctl.ip6_rt_min_advmss = IPV6_MIN_MTU - 20 - 40; in ip6_route_net_init()
6481 net->ipv6.sysctl.skip_notify_on_dev_down = 0; in ip6_route_net_init()
6483 net->ipv6.ip6_rt_gc_expire = 30*HZ; in ip6_route_net_init()
6491 kfree(net->ipv6.ip6_prohibit_entry); in ip6_route_net_init()
6493 kfree(net->ipv6.ip6_null_entry); in ip6_route_net_init()
6496 kfree(net->ipv6.fib6_null_entry); in ip6_route_net_init()
6498 dst_entries_destroy(&net->ipv6.ip6_dst_ops); in ip6_route_net_init()
6505 kfree(net->ipv6.fib6_null_entry); in ip6_route_net_exit()
6506 kfree(net->ipv6.ip6_null_entry); in ip6_route_net_exit()
6508 kfree(net->ipv6.ip6_prohibit_entry); in ip6_route_net_exit()
6509 kfree(net->ipv6.ip6_blk_hole_entry); in ip6_route_net_exit()
6511 dst_entries_destroy(&net->ipv6.ip6_dst_ops); in ip6_route_net_exit()
6545 net->ipv6.peers = bp; in ipv6_inetpeer_init()
6551 struct inet_peer_base *bp = net->ipv6.peers; in ipv6_inetpeer_exit()
6553 net->ipv6.peers = NULL; in ipv6_inetpeer_exit()
6578 init_net.ipv6.fib6_null_entry->fib6_nh->fib_nh_dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6579 init_net.ipv6.ip6_null_entry->dst.dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6580 init_net.ipv6.ip6_null_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); in ip6_route_init_special_entries()
6582 init_net.ipv6.ip6_prohibit_entry->dst.dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6583 init_net.ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); in ip6_route_init_special_entries()
6584 init_net.ipv6.ip6_blk_hole_entry->dst.dev = init_net.loopback_dev; in ip6_route_init_special_entries()
6585 init_net.ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); in ip6_route_init_special_entries()