Lines Matching refs:net

316 int rds_tcp_laddr_check(struct net *net, const struct in6_addr *addr,  in rds_tcp_laddr_check()  argument
325 if (inet_addr_type(net, addr->s6_addr32[3]) == RTN_LOCAL) in rds_tcp_laddr_check()
335 dev = dev_get_by_index_rcu(net, scope_id); in rds_tcp_laddr_check()
344 ret = ipv6_chk_addr(net, addr, dev, 0); in rds_tcp_laddr_check()
493 struct net *net = sock_net(sk); in rds_tcp_tune() local
502 if (!maybe_get_net(net)) { in rds_tcp_tune()
507 __netns_tracker_free(net, &sk->ns_tracker, false); in rds_tcp_tune()
510 netns_tracker_alloc(net, &sk->ns_tracker, GFP_KERNEL); in rds_tcp_tune()
511 sock_inuse_add(net, 1); in rds_tcp_tune()
513 rtn = net_generic(net, rds_tcp_netid); in rds_tcp_tune()
538 struct net *net = sock_net(sk); in rds_tcp_accept_work() local
539 struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid); in rds_tcp_accept_work()
544 static __net_init int rds_tcp_init_net(struct net *net) in rds_tcp_init_net() argument
546 struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid); in rds_tcp_init_net()
555 if (net == &init_net) { in rds_tcp_init_net()
568 rtn->rds_tcp_sysctl = register_net_sysctl_sz(net, "net/rds/tcp", tbl, in rds_tcp_init_net()
577 rtn->rds_tcp_listen_sock = rds_tcp_listen_init(net, true); in rds_tcp_init_net()
579 rtn->rds_tcp_listen_sock = rds_tcp_listen_init(net, false); in rds_tcp_init_net()
586 rtn->rds_tcp_listen_sock = rds_tcp_listen_init(net, false); in rds_tcp_init_net()
601 if (net != &init_net) in rds_tcp_init_net()
606 static void rds_tcp_kill_sock(struct net *net) in rds_tcp_kill_sock() argument
610 struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid); in rds_tcp_kill_sock()
617 struct net *c_net = read_pnet(&tc->t_cpath->cp_conn->c_net); in rds_tcp_kill_sock()
619 if (net != c_net) in rds_tcp_kill_sock()
633 static void __net_exit rds_tcp_exit_net(struct net *net) in rds_tcp_exit_net() argument
635 struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid); in rds_tcp_exit_net()
637 rds_tcp_kill_sock(net); in rds_tcp_exit_net()
642 if (net != &init_net) in rds_tcp_exit_net()
653 void *rds_tcp_listen_sock_def_readable(struct net *net) in rds_tcp_listen_sock_def_readable() argument
655 struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid); in rds_tcp_listen_sock_def_readable()
669 static void rds_tcp_sysctl_reset(struct net *net) in rds_tcp_sysctl_reset() argument
675 struct net *c_net = read_pnet(&tc->t_cpath->cp_conn->c_net); in rds_tcp_sysctl_reset()
677 if (net != c_net || !tc->t_sock) in rds_tcp_sysctl_reset()
689 struct net *net = current->nsproxy->net_ns; in rds_tcp_skbuf_handler() local
699 rds_tcp_sysctl_reset(net); in rds_tcp_skbuf_handler()