Home
last modified time | relevance | path

Searched refs:nsk (Results 1 – 17 of 17) sorted by relevance

/linux/kernel/bpf/
A Dreuseport_array.c198 const struct sock *nsk, in reuseport_array_update_check() argument
209 if (nsk->sk_protocol != IPPROTO_UDP && nsk->sk_protocol != IPPROTO_TCP) in reuseport_array_update_check()
212 if (nsk->sk_family != AF_INET && nsk->sk_family != AF_INET6) in reuseport_array_update_check()
215 if (nsk->sk_type != SOCK_STREAM && nsk->sk_type != SOCK_DGRAM) in reuseport_array_update_check()
226 if (!sock_flag(nsk, SOCK_RCU_FREE) || !sk_hashed(nsk) || !nsk_reuse) in reuseport_array_update_check()
230 if (READ_ONCE(nsk->sk_user_data)) in reuseport_array_update_check()
245 struct sock *free_osk = NULL, *osk, *nsk; in bpf_fd_reuseport_array_update_elem() local
272 nsk = socket->sk; in bpf_fd_reuseport_array_update_elem()
273 if (!nsk) { in bpf_fd_reuseport_array_update_elem()
292 write_lock_bh(&nsk->sk_callback_lock); in bpf_fd_reuseport_array_update_elem()
[all …]
/linux/net/core/
A Dsock_reuseport.c526 struct sock *nsk = NULL; in reuseport_migrate_sock() local
560 nsk = bpf_run_sk_reuseport(reuse, sk, prog, skb, migrating_sk, hash); in reuseport_migrate_sock()
566 if (!nsk) in reuseport_migrate_sock()
567 nsk = reuseport_select_sock_by_hash(reuse, hash, socks); in reuseport_migrate_sock()
569 if (IS_ERR_OR_NULL(nsk) || unlikely(!refcount_inc_not_zero(&nsk->sk_refcnt))) { in reuseport_migrate_sock()
570 nsk = NULL; in reuseport_migrate_sock()
576 return nsk; in reuseport_migrate_sock()
A Dsock.c1879 static void sock_copy(struct sock *nsk, const struct sock *osk) in sock_copy() argument
1883 void *sptr = nsk->sk_security; in sock_copy()
1895 memcpy(nsk, osk, offsetof(struct sock, sk_dontcopy_begin)); in sock_copy()
1897 memcpy(&nsk->sk_dontcopy_end, &osk->sk_dontcopy_end, in sock_copy()
1901 nsk->sk_security = sptr; in sock_copy()
1902 security_sk_clone(osk, nsk); in sock_copy()
/linux/net/iucv/
A Daf_iucv.c1586 struct sock *sk, *nsk; in iucv_callback_connreq() local
1632 if (!nsk) { in iucv_callback_connreq()
1638 niucv = iucv_sk(nsk); in iucv_callback_connreq()
1639 iucv_sock_init(nsk, sk); in iucv_callback_connreq()
1662 iucv_sock_kill(nsk); in iucv_callback_connreq()
1840 struct sock *nsk; in afiucv_hs_callback_syn() local
1857 !nsk) { in afiucv_hs_callback_syn()
1862 iucv_sock_kill(nsk); in afiucv_hs_callback_syn()
1867 niucv = iucv_sk(nsk); in afiucv_hs_callback_syn()
1868 iucv_sock_init(nsk, sk); in afiucv_hs_callback_syn()
[all …]
/linux/net/ipv4/
A Dinet_connection_sock.c807 struct sock *nsk; in reqsk_timer_handler() local
810 if (!nsk) in reqsk_timer_handler()
813 nreq = inet_reqsk_clone(req, nsk); in reqsk_timer_handler()
827 sk_listener = nsk; in reqsk_timer_handler()
1184 struct sock *child = req->sk, *nsk; in inet_csk_listen_stop() local
1192 nsk = reuseport_migrate_sock(sk, child, NULL); in inet_csk_listen_stop()
1193 if (nsk) { in inet_csk_listen_stop()
1194 nreq = inet_reqsk_clone(req, nsk); in inet_csk_listen_stop()
1198 if (inet_csk_reqsk_queue_add(nsk, nreq, child)) { in inet_csk_listen_stop()
1199 __NET_INC_STATS(sock_net(nsk), in inet_csk_listen_stop()
[all …]
A Dtcp_ipv4.c1729 if (!nsk) in tcp_v4_do_rcv()
1731 if (nsk != sk) { in tcp_v4_do_rcv()
1732 if (tcp_child_process(sk, nsk, skb)) { in tcp_v4_do_rcv()
1733 rsk = nsk; in tcp_v4_do_rcv()
2016 struct sock *nsk; in tcp_v4_rcv() local
2030 if (!nsk) { in tcp_v4_rcv()
2034 sk = nsk; in tcp_v4_rcv()
2045 nsk = NULL; in tcp_v4_rcv()
2052 if (!nsk) { in tcp_v4_rcv()
2066 if (nsk == sk) { in tcp_v4_rcv()
[all …]
A Desp4.c139 struct sock *nsk; in esp_find_tcp_sk() local
149 nsk = rcu_dereference_protected(x->encap_sk, in esp_find_tcp_sk()
151 if (sk && sk == nsk) { in esp_find_tcp_sk()
174 nsk = rcu_dereference_protected(x->encap_sk, in esp_find_tcp_sk()
179 sk = nsk ?: ERR_PTR(-EREMCHG); in esp_find_tcp_sk()
180 } else if (sk == nsk) { in esp_find_tcp_sk()
/linux/net/smc/
A Daf_smc.c307 nsk->sk_type = osk->sk_type; in smc_copy_sock_settings()
308 nsk->sk_sndbuf = osk->sk_sndbuf; in smc_copy_sock_settings()
309 nsk->sk_rcvbuf = osk->sk_rcvbuf; in smc_copy_sock_settings()
310 nsk->sk_sndtimeo = osk->sk_sndtimeo; in smc_copy_sock_settings()
311 nsk->sk_rcvtimeo = osk->sk_rcvtimeo; in smc_copy_sock_settings()
312 nsk->sk_mark = osk->sk_mark; in smc_copy_sock_settings()
316 nsk->sk_err = osk->sk_err; in smc_copy_sock_settings()
318 nsk->sk_flags &= ~mask; in smc_copy_sock_settings()
2194 rc = sock_error(nsk); in smc_accept()
2211 lock_sock(nsk); in smc_accept()
[all …]
/linux/net/ipv6/
A Dtcp_ipv6.c1536 if (!nsk) in tcp_v6_do_rcv()
1539 if (nsk != sk) { in tcp_v6_do_rcv()
1540 if (tcp_child_process(sk, nsk, skb)) in tcp_v6_do_rcv()
1675 struct sock *nsk; in tcp_v6_rcv() local
1689 if (!nsk) { in tcp_v6_rcv()
1693 sk = nsk; in tcp_v6_rcv()
1701 nsk = NULL; in tcp_v6_rcv()
1708 if (!nsk) { in tcp_v6_rcv()
1722 if (nsk == sk) { in tcp_v6_rcv()
1725 } else if (tcp_child_process(sk, nsk, skb)) { in tcp_v6_rcv()
[all …]
A Desp6.c157 struct sock *nsk; in esp6_find_tcp_sk() local
167 nsk = rcu_dereference_protected(x->encap_sk, in esp6_find_tcp_sk()
169 if (sk && sk == nsk) { in esp6_find_tcp_sk()
192 nsk = rcu_dereference_protected(x->encap_sk, in esp6_find_tcp_sk()
197 sk = nsk ?: ERR_PTR(-EREMCHG); in esp6_find_tcp_sk()
198 } else if (sk == nsk) { in esp6_find_tcp_sk()
/linux/net/dccp/
A Dipv4.c847 struct sock *nsk; in dccp_v4_rcv() local
856 nsk = dccp_check_req(sk, skb, req); in dccp_v4_rcv()
857 if (!nsk) { in dccp_v4_rcv()
861 if (nsk == sk) { in dccp_v4_rcv()
863 } else if (dccp_child_process(sk, nsk, skb)) { in dccp_v4_rcv()
A Dipv6.c750 struct sock *nsk; in dccp_v6_rcv() local
759 nsk = dccp_check_req(sk, skb, req); in dccp_v6_rcv()
760 if (!nsk) { in dccp_v6_rcv()
764 if (nsk == sk) { in dccp_v6_rcv()
766 } else if (dccp_child_process(sk, nsk, skb)) { in dccp_v6_rcv()
/linux/net/mptcp/
A Dprotocol.c2788 if (!nsk) in mptcp_sk_clone()
2792 if (nsk->sk_family == AF_INET6) in mptcp_sk_clone()
2793 inet_sk(nsk)->pinet6 = mptcp_inet6_sk(nsk); in mptcp_sk_clone()
2796 __mptcp_init_sock(nsk); in mptcp_sk_clone()
2798 msk = mptcp_sk(nsk); in mptcp_sk_clone()
2821 sock_reset_flag(nsk, SOCK_RCU_FREE); in mptcp_sk_clone()
2823 inet_sk_state_store(nsk, TCP_SYN_RECV); in mptcp_sk_clone()
2825 security_inet_csk_clone(nsk, req); in mptcp_sk_clone()
2826 bh_unlock_sock(nsk); in mptcp_sk_clone()
2829 __sock_put(nsk); in mptcp_sk_clone()
[all …]
/linux/net/bluetooth/rfcomm/
A Dsock.c477 struct sock *sk = sock->sk, *nsk; in rfcomm_sock_accept() local
500 nsk = bt_accept_dequeue(sk, newsock); in rfcomm_sock_accept()
501 if (nsk) in rfcomm_sock_accept()
527 BT_DBG("new socket %p", nsk); in rfcomm_sock_accept()
/linux/net/bluetooth/
A Dl2cap_sock.c322 struct sock *sk = sock->sk, *nsk; in l2cap_sock_accept() local
340 nsk = bt_accept_dequeue(sk, newsock); in l2cap_sock_accept()
341 if (nsk) in l2cap_sock_accept()
367 BT_DBG("new socket %p", nsk); in l2cap_sock_accept()
/linux/drivers/gpu/drm/bridge/
A Dtc358768.c619 static u32 tc358768_to_ns(u32 nsk) in tc358768_to_ns() argument
621 return (nsk / TC358768_PRECISION); in tc358768_to_ns()
/linux/include/net/
A Dsock.h884 static inline void sock_copy_flags(struct sock *nsk, struct sock *osk) in sock_copy_flags() argument
886 nsk->sk_flags = osk->sk_flags; in sock_copy_flags()

Completed in 58 milliseconds