/openbmc/linux/kernel/bpf/ |
H A D | reuseport_array.c | 189 const struct sock *nsk, in reuseport_array_update_check() argument 200 if (nsk->sk_protocol != IPPROTO_UDP && nsk->sk_protocol != IPPROTO_TCP) in reuseport_array_update_check() 203 if (nsk->sk_family != AF_INET && nsk->sk_family != AF_INET6) in reuseport_array_update_check() 206 if (nsk->sk_type != SOCK_STREAM && nsk->sk_type != SOCK_DGRAM) in reuseport_array_update_check() 217 if (!sock_flag(nsk, SOCK_RCU_FREE) || !sk_hashed(nsk) || !nsk_reuse) in reuseport_array_update_check() 221 if (READ_ONCE(nsk->sk_user_data)) in reuseport_array_update_check() 236 struct sock *free_osk = NULL, *osk, *nsk; in bpf_fd_reuseport_array_update_elem() local 263 nsk = socket->sk; in bpf_fd_reuseport_array_update_elem() 264 if (!nsk) { in bpf_fd_reuseport_array_update_elem() 283 write_lock_bh(&nsk->sk_callback_lock); in bpf_fd_reuseport_array_update_elem() [all …]
|
/openbmc/linux/net/core/ |
H A D | sock_reuseport.c | 626 struct sock *nsk = NULL; in reuseport_migrate_sock() local 660 nsk = bpf_run_sk_reuseport(reuse, sk, prog, skb, migrating_sk, hash); in reuseport_migrate_sock() 666 if (!nsk) in reuseport_migrate_sock() 667 nsk = reuseport_select_sock_by_hash(reuse, hash, socks); in reuseport_migrate_sock() 669 if (IS_ERR_OR_NULL(nsk) || unlikely(!refcount_inc_not_zero(&nsk->sk_refcnt))) { in reuseport_migrate_sock() 670 nsk = NULL; in reuseport_migrate_sock() 676 return nsk; in reuseport_migrate_sock()
|
H A D | sock.c | 2050 static void sock_copy(struct sock *nsk, const struct sock *osk) in sock_copy() argument 2054 void *sptr = nsk->sk_security; in sock_copy() 2066 memcpy(nsk, osk, offsetof(struct sock, sk_dontcopy_begin)); in sock_copy() 2068 memcpy(&nsk->sk_dontcopy_end, &osk->sk_dontcopy_end, in sock_copy() 2072 nsk->sk_security = sptr; in sock_copy() 2073 security_sk_clone(osk, nsk); in sock_copy()
|
/openbmc/linux/net/iucv/ |
H A D | af_iucv.c | 1584 struct sock *sk, *nsk; in iucv_callback_connreq() local 1630 if (!nsk) { in iucv_callback_connreq() 1636 niucv = iucv_sk(nsk); in iucv_callback_connreq() 1637 iucv_sock_init(nsk, sk); in iucv_callback_connreq() 1660 iucv_sock_kill(nsk); in iucv_callback_connreq() 1838 struct sock *nsk; in afiucv_hs_callback_syn() local 1855 !nsk) { in afiucv_hs_callback_syn() 1860 iucv_sock_kill(nsk); in afiucv_hs_callback_syn() 1865 niucv = iucv_sk(nsk); in afiucv_hs_callback_syn() 1866 iucv_sock_init(nsk, sk); in afiucv_hs_callback_syn() [all …]
|
/openbmc/linux/net/ipv4/ |
H A D | inet_connection_sock.c | 1028 struct sock *nsk; in reqsk_timer_handler() local 1031 if (!nsk) in reqsk_timer_handler() 1034 nreq = inet_reqsk_clone(req, nsk); in reqsk_timer_handler() 1048 sk_listener = nsk; in reqsk_timer_handler() 1426 struct sock *child = req->sk, *nsk; in inet_csk_listen_stop() local 1434 nsk = reuseport_migrate_sock(sk, child, NULL); in inet_csk_listen_stop() 1435 if (nsk) { in inet_csk_listen_stop() 1436 nreq = inet_reqsk_clone(req, nsk); in inet_csk_listen_stop() 1440 if (inet_csk_reqsk_queue_add(nsk, nreq, child)) { in inet_csk_listen_stop() 1441 __NET_INC_STATS(sock_net(nsk), in inet_csk_listen_stop() [all …]
|
H A D | esp4.c | 140 struct sock *nsk; in esp_find_tcp_sk() local 150 nsk = rcu_dereference_protected(x->encap_sk, in esp_find_tcp_sk() 152 if (sk && sk == nsk) { in esp_find_tcp_sk() 175 nsk = rcu_dereference_protected(x->encap_sk, in esp_find_tcp_sk() 180 sk = nsk ?: ERR_PTR(-EREMCHG); in esp_find_tcp_sk() 181 } else if (sk == nsk) { in esp_find_tcp_sk()
|
H A D | tcp_ipv4.c | 1745 if (!nsk) in tcp_v4_do_rcv() 1747 if (nsk != sk) { in tcp_v4_do_rcv() 1748 if (tcp_child_process(sk, nsk, skb)) { in tcp_v4_do_rcv() 1749 rsk = nsk; in tcp_v4_do_rcv() 2053 struct sock *nsk; in tcp_v4_rcv() local 2073 if (!nsk) { in tcp_v4_rcv() 2077 sk = nsk; in tcp_v4_rcv() 2088 nsk = NULL; in tcp_v4_rcv() 2097 if (!nsk) { in tcp_v4_rcv() 2112 if (nsk == sk) { in tcp_v4_rcv() [all …]
|
/openbmc/linux/net/smc/ |
H A D | af_smc.c | 465 nsk->sk_sndbuf = osk->sk_sndbuf; in smc_adjust_sock_bufsizes() 467 nsk->sk_rcvbuf = osk->sk_rcvbuf; in smc_adjust_sock_bufsizes() 474 nsk->sk_type = osk->sk_type; in smc_copy_sock_settings() 475 nsk->sk_sndtimeo = osk->sk_sndtimeo; in smc_copy_sock_settings() 481 nsk->sk_err = osk->sk_err; in smc_copy_sock_settings() 483 nsk->sk_flags &= ~mask; in smc_copy_sock_settings() 2638 struct sock *sk = sock->sk, *nsk; in smc_accept() local 2677 rc = sock_error(nsk); in smc_accept() 2686 if (smc_sk(nsk)->use_fallback) { in smc_accept() 2694 lock_sock(nsk); in smc_accept() [all …]
|
/openbmc/linux/net/ipv6/ |
H A D | tcp_ipv6.c | 1494 if (!nsk) in tcp_v6_do_rcv() 1497 if (nsk != sk) { in tcp_v6_do_rcv() 1498 if (tcp_child_process(sk, nsk, skb)) in tcp_v6_do_rcv() 1637 struct sock *nsk; in tcp_v6_rcv() local 1657 if (!nsk) { in tcp_v6_rcv() 1661 sk = nsk; in tcp_v6_rcv() 1669 nsk = NULL; in tcp_v6_rcv() 1678 if (!nsk) { in tcp_v6_rcv() 1693 if (nsk == sk) { in tcp_v6_rcv() 1696 } else if (tcp_child_process(sk, nsk, skb)) { in tcp_v6_rcv() [all …]
|
H A D | esp6.c | 157 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()
|
/openbmc/linux/net/dccp/ |
H A D | ipv4.c | 858 struct sock *nsk; in dccp_v4_rcv() local 867 nsk = dccp_check_req(sk, skb, req); in dccp_v4_rcv() 868 if (!nsk) { in dccp_v4_rcv() 872 if (nsk == sk) { in dccp_v4_rcv() 874 } else if (dccp_child_process(sk, nsk, skb)) { in dccp_v4_rcv()
|
H A D | ipv6.c | 751 struct sock *nsk; in dccp_v6_rcv() local 760 nsk = dccp_check_req(sk, skb, req); in dccp_v6_rcv() 761 if (!nsk) { in dccp_v6_rcv() 765 if (nsk == sk) { in dccp_v6_rcv() 767 } else if (dccp_child_process(sk, nsk, skb)) { in dccp_v6_rcv()
|
/openbmc/linux/net/mptcp/ |
H A D | protocol.c | 3262 if (!nsk) in mptcp_sk_clone_init() 3266 if (nsk->sk_family == AF_INET6) in mptcp_sk_clone_init() 3267 inet_sk(nsk)->pinet6 = mptcp_inet6_sk(nsk); in mptcp_sk_clone_init() 3270 __mptcp_init_sock(nsk); in mptcp_sk_clone_init() 3273 if (nsk->sk_family == AF_INET6) in mptcp_sk_clone_init() 3274 mptcp_copy_ip6_options(nsk, sk); in mptcp_sk_clone_init() 3277 mptcp_copy_ip_options(nsk, sk); in mptcp_sk_clone_init() 3279 msk = mptcp_sk(nsk); in mptcp_sk_clone_init() 3319 mptcp_copy_inaddrs(nsk, ssk); in mptcp_sk_clone_init() 3326 bh_unlock_sock(nsk); in mptcp_sk_clone_init() [all …]
|
/openbmc/linux/net/bluetooth/rfcomm/ |
H A D | sock.c | 475 struct sock *sk = sock->sk, *nsk; in rfcomm_sock_accept() local 498 nsk = bt_accept_dequeue(sk, newsock); in rfcomm_sock_accept() 499 if (nsk) in rfcomm_sock_accept() 525 BT_DBG("new socket %p", nsk); in rfcomm_sock_accept()
|
/openbmc/linux/net/bluetooth/ |
H A D | l2cap_sock.c | 332 struct sock *sk = sock->sk, *nsk; in l2cap_sock_accept() local 350 nsk = bt_accept_dequeue(sk, newsock); in l2cap_sock_accept() 351 if (nsk) in l2cap_sock_accept() 377 BT_DBG("new socket %p", nsk); in l2cap_sock_accept()
|
/openbmc/linux/include/net/ |
H A D | sock.h | 968 static inline void sock_copy_flags(struct sock *nsk, const struct sock *osk) in sock_copy_flags() argument 970 nsk->sk_flags = osk->sk_flags; in sock_copy_flags()
|
/openbmc/qemu/target/arm/ |
H A D | helper.c | 1189 bool e, p, u, nsk, nsu, nsh, m; in pmu_counter_enabled() local 1249 nsk = arm_feature(env, ARM_FEATURE_EL3) && (filter & PMXEVTYPER_NSK); in pmu_counter_enabled() 1258 filtered = secure ? p : p != nsk; in pmu_counter_enabled()
|