/net/ |
D | socket.c | 391 struct file *sock_alloc_file(struct socket *sock, int flags, const char *dname) in sock_alloc_file() argument 396 dname = sock->sk ? sock->sk->sk_prot_creator->name : ""; in sock_alloc_file() 398 file = alloc_file_pseudo(SOCK_INODE(sock), sock_mnt, dname, in sock_alloc_file() 402 sock_release(sock); in sock_alloc_file() 406 sock->file = file; in sock_alloc_file() 407 file->private_data = sock; in sock_alloc_file() 412 static int sock_map_fd(struct socket *sock, int flags) in sock_map_fd() argument 417 sock_release(sock); in sock_map_fd() 421 newfile = sock_alloc_file(sock, flags, NULL); in sock_map_fd() 465 struct socket *sock; in sockfd_lookup() local [all …]
|
/net/dccp/ |
D | dccp.h | 53 void dccp_time_wait(struct sock *sk, int state, int timeo); 224 void dccp_v4_send_check(struct sock *sk, struct sk_buff *skb); 226 int dccp_retransmit_skb(struct sock *sk); 228 void dccp_send_ack(struct sock *sk); 229 void dccp_reqsk_send_ack(const struct sock *sk, struct sk_buff *skb, 232 void dccp_send_sync(struct sock *sk, const u64 seq, 238 void dccp_qpolicy_push(struct sock *sk, struct sk_buff *skb); 239 bool dccp_qpolicy_full(struct sock *sk); 240 void dccp_qpolicy_drop(struct sock *sk, struct sk_buff *skb); 241 struct sk_buff *dccp_qpolicy_top(struct sock *sk); [all …]
|
D | ccid.h | 56 int (*ccid_hc_rx_init)(struct ccid *ccid, struct sock *sk); 57 int (*ccid_hc_tx_init)(struct ccid *ccid, struct sock *sk); 58 void (*ccid_hc_rx_exit)(struct sock *sk); 59 void (*ccid_hc_tx_exit)(struct sock *sk); 60 void (*ccid_hc_rx_packet_recv)(struct sock *sk, 62 int (*ccid_hc_rx_parse_options)(struct sock *sk, u8 pkt, 64 int (*ccid_hc_rx_insert_options)(struct sock *sk, 66 void (*ccid_hc_tx_packet_recv)(struct sock *sk, 68 int (*ccid_hc_tx_parse_options)(struct sock *sk, u8 pkt, 70 int (*ccid_hc_tx_send_packet)(struct sock *sk, [all …]
|
/net/rds/ |
D | tcp_listen.c | 41 int rds_tcp_keepalive(struct socket *sock) in rds_tcp_keepalive() argument 49 ret = kernel_setsockopt(sock, SOL_SOCKET, SO_KEEPALIVE, in rds_tcp_keepalive() 54 ret = kernel_setsockopt(sock, IPPROTO_TCP, TCP_KEEPCNT, in rds_tcp_keepalive() 59 ret = kernel_setsockopt(sock, IPPROTO_TCP, TCP_KEEPIDLE, in rds_tcp_keepalive() 67 ret = kernel_setsockopt(sock, IPPROTO_TCP, TCP_KEEPINTVL, in rds_tcp_keepalive() 114 void rds_tcp_set_linger(struct socket *sock) in rds_tcp_set_linger() argument 121 kernel_setsockopt(sock, SOL_SOCKET, SO_LINGER, in rds_tcp_set_linger() 125 int rds_tcp_accept_one(struct socket *sock) in rds_tcp_accept_one() argument 140 if (!sock) /* module unload or netns delete in progress */ in rds_tcp_accept_one() 143 ret = sock_create_lite(sock->sk->sk_family, in rds_tcp_accept_one() [all …]
|
D | tcp_connect.c | 40 void rds_tcp_state_change(struct sock *sk) in rds_tcp_state_change() 42 void (*state_change)(struct sock *sk); in rds_tcp_state_change() 91 struct socket *sock = NULL; in rds_tcp_conn_path_connect() local 115 SOCK_STREAM, IPPROTO_TCP, &sock); in rds_tcp_conn_path_connect() 119 SOCK_STREAM, IPPROTO_TCP, &sock); in rds_tcp_conn_path_connect() 126 rds_tcp_tune(sock); in rds_tcp_conn_path_connect() 144 ret = sock->ops->bind(sock, addr, addrlen); in rds_tcp_conn_path_connect() 171 rds_tcp_set_callbacks(sock, cp); in rds_tcp_conn_path_connect() 172 ret = sock->ops->connect(sock, addr, addrlen, O_NONBLOCK); in rds_tcp_conn_path_connect() 178 rds_tcp_keepalive(sock); in rds_tcp_conn_path_connect() [all …]
|
/net/llc/ |
D | llc_c_ev.c | 75 static u16 llc_util_nr_inside_tx_window(struct sock *sk, u8 nr) in llc_util_nr_inside_tx_window() 99 int llc_conn_ev_conn_req(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_conn_req() 107 int llc_conn_ev_data_req(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_data_req() 115 int llc_conn_ev_disc_req(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_disc_req() 123 int llc_conn_ev_rst_req(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_rst_req() 131 int llc_conn_ev_local_busy_detected(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_local_busy_detected() 139 int llc_conn_ev_local_busy_cleared(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_local_busy_cleared() 147 int llc_conn_ev_rx_bad_pdu(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_rx_bad_pdu() 152 int llc_conn_ev_rx_disc_cmd_pbit_set_x(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_rx_disc_cmd_pbit_set_x() 160 int llc_conn_ev_rx_dm_rsp_fbit_set_x(struct sock *sk, struct sk_buff *skb) in llc_conn_ev_rx_dm_rsp_fbit_set_x() [all …]
|
D | llc_c_ac.c | 32 static int llc_conn_ac_inc_vs_by_1(struct sock *sk, struct sk_buff *skb); 33 static void llc_process_tmr_ev(struct sock *sk, struct sk_buff *skb); 34 static int llc_conn_ac_data_confirm(struct sock *sk, struct sk_buff *ev); 36 static int llc_conn_ac_inc_npta_value(struct sock *sk, struct sk_buff *skb); 38 static int llc_conn_ac_send_rr_rsp_f_set_ackpf(struct sock *sk, 41 static int llc_conn_ac_set_p_flag_1(struct sock *sk, struct sk_buff *skb); 45 int llc_conn_ac_clear_remote_busy(struct sock *sk, struct sk_buff *skb) in llc_conn_ac_clear_remote_busy() 61 int llc_conn_ac_conn_ind(struct sock *sk, struct sk_buff *skb) in llc_conn_ac_conn_ind() 69 int llc_conn_ac_conn_confirm(struct sock *sk, struct sk_buff *skb) in llc_conn_ac_conn_confirm() 77 static int llc_conn_ac_data_confirm(struct sock *sk, struct sk_buff *skb) in llc_conn_ac_data_confirm() [all …]
|
D | af_llc.c | 43 static bool llc_ui_wait_for_conn(struct sock *sk, long timeout); 44 static int llc_ui_wait_for_disc(struct sock *sk, long timeout); 45 static int llc_ui_wait_for_busy_core(struct sock *sk, long timeout); 97 static inline u8 llc_ui_header_len(struct sock *sk, struct sockaddr_llc *addr) in llc_ui_header_len() 119 static int llc_ui_send_data(struct sock* sk, struct sk_buff *skb, int noblock) in llc_ui_send_data() 138 static void llc_ui_sk_init(struct socket *sock, struct sock *sk) in llc_ui_sk_init() argument 140 sock_graft(sk, sock); in llc_ui_sk_init() 141 sk->sk_type = sock->type; in llc_ui_sk_init() 142 sock->ops = &llc_ui_ops; in llc_ui_sk_init() 163 static int llc_ui_create(struct net *net, struct socket *sock, int protocol, in llc_ui_create() argument [all …]
|
/net/bluetooth/rfcomm/ |
D | sock.c | 43 static void rfcomm_sock_close(struct sock *sk); 44 static void rfcomm_sock_kill(struct sock *sk); 52 struct sock *sk = d->owner; in rfcomm_sk_data_ready() 66 struct sock *sk = d->owner, *parent; in rfcomm_sk_state_change() 109 static struct sock *__rfcomm_get_listen_sock_by_addr(u8 channel, bdaddr_t *src) in __rfcomm_get_listen_sock_by_addr() 111 struct sock *sk = NULL; in __rfcomm_get_listen_sock_by_addr() 130 static struct sock *rfcomm_get_sock_by_channel(int state, u8 channel, bdaddr_t *src) in rfcomm_get_sock_by_channel() 132 struct sock *sk = NULL, *sk1 = NULL; in rfcomm_get_sock_by_channel() 156 static void rfcomm_sock_destruct(struct sock *sk) in rfcomm_sock_destruct() 176 static void rfcomm_sock_cleanup_listen(struct sock *parent) in rfcomm_sock_cleanup_listen() [all …]
|
/net/atm/ |
D | svc.c | 31 static int svc_create(struct net *net, struct socket *sock, int protocol, 41 static int svc_shutdown(struct socket *sock, int how) in svc_shutdown() argument 50 struct sock *sk = sk_atm(vcc); in svc_disconnect() 75 static int svc_release(struct socket *sock) in svc_release() argument 77 struct sock *sk = sock->sk; in svc_release() 81 vcc = ATM_SD(sock); in svc_release() 90 vcc_release(sock); in svc_release() 95 static int svc_bind(struct socket *sock, struct sockaddr *sockaddr, in svc_bind() argument 99 struct sock *sk = sock->sk; in svc_bind() 107 if (sock->state == SS_CONNECTED) { in svc_bind() [all …]
|
D | pvc.c | 22 static int pvc_shutdown(struct socket *sock, int how) in pvc_shutdown() argument 27 static int pvc_bind(struct socket *sock, struct sockaddr *sockaddr, in pvc_bind() argument 30 struct sock *sk = sock->sk; in pvc_bind() 41 vcc = ATM_SD(sock); in pvc_bind() 52 error = vcc_connect(sock, addr->sap_addr.itf, addr->sap_addr.vpi, in pvc_bind() 59 static int pvc_connect(struct socket *sock, struct sockaddr *sockaddr, in pvc_connect() argument 62 return pvc_bind(sock, sockaddr, sockaddr_len); in pvc_connect() 65 static int pvc_setsockopt(struct socket *sock, int level, int optname, in pvc_setsockopt() argument 68 struct sock *sk = sock->sk; in pvc_setsockopt() 72 error = vcc_setsockopt(sock, level, optname, optval, optlen); in pvc_setsockopt() [all …]
|
/net/phonet/ |
D | socket.c | 28 static int pn_socket_release(struct socket *sock) in pn_socket_release() argument 30 struct sock *sk = sock->sk; in pn_socket_release() 33 sock->sk = NULL; in pn_socket_release() 66 struct sock *pn_find_sock_by_sa(struct net *net, const struct sockaddr_pn *spn) in pn_find_sock_by_sa() 68 struct sock *sknode; in pn_find_sock_by_sa() 69 struct sock *rval = NULL; in pn_find_sock_by_sa() 111 struct sock *sknode; in pn_deliver_sock_broadcast() 132 int pn_sock_hash(struct sock *sk) in pn_sock_hash() 144 void pn_sock_unhash(struct sock *sk) in pn_sock_unhash() 156 static int pn_socket_bind(struct socket *sock, struct sockaddr *addr, int len) in pn_socket_bind() argument [all …]
|
/net/nfc/ |
D | llcp_commands.c | 241 int nfc_llcp_parse_connection_tlv(struct nfc_llcp_sock *sock, in nfc_llcp_parse_connection_tlv() argument 248 if (sock == NULL) in nfc_llcp_parse_connection_tlv() 259 sock->remote_miu = llcp_tlv_miux(tlv) + 128; in nfc_llcp_parse_connection_tlv() 262 sock->remote_rw = llcp_tlv_rw(tlv); in nfc_llcp_parse_connection_tlv() 275 pr_debug("sock %p rw %d miu %d\n", sock, in nfc_llcp_parse_connection_tlv() 276 sock->remote_rw, sock->remote_miu); in nfc_llcp_parse_connection_tlv() 311 static struct sk_buff *llcp_allocate_pdu(struct nfc_llcp_sock *sock, in llcp_allocate_pdu() argument 317 if (sock->ssap == 0) in llcp_allocate_pdu() 320 skb = nfc_alloc_send_skb(sock->dev, &sock->sk, MSG_DONTWAIT, in llcp_allocate_pdu() 327 skb = llcp_add_header(skb, sock->dsap, sock->ssap, cmd); in llcp_allocate_pdu() [all …]
|
D | llcp_sock.c | 17 static int sock_wait_state(struct sock *sk, int state, unsigned long timeo) in sock_wait_state() 59 static int llcp_sock_bind(struct socket *sock, struct sockaddr *addr, int alen) in llcp_sock_bind() argument 61 struct sock *sk = sock->sk; in llcp_sock_bind() 138 static int llcp_raw_sock_bind(struct socket *sock, struct sockaddr *addr, in llcp_raw_sock_bind() argument 141 struct sock *sk = sock->sk; in llcp_raw_sock_bind() 193 static int llcp_sock_listen(struct socket *sock, int backlog) in llcp_sock_listen() argument 195 struct sock *sk = sock->sk; in llcp_sock_listen() 202 if ((sock->type != SOCK_SEQPACKET && sock->type != SOCK_STREAM) || in llcp_sock_listen() 220 static int nfc_llcp_setsockopt(struct socket *sock, int level, int optname, in nfc_llcp_setsockopt() argument 223 struct sock *sk = sock->sk; in nfc_llcp_setsockopt() [all …]
|
D | rawsock.c | 22 static void nfc_sock_link(struct nfc_sock_list *l, struct sock *sk) in nfc_sock_link() 29 static void nfc_sock_unlink(struct nfc_sock_list *l, struct sock *sk) in nfc_sock_unlink() 36 static void rawsock_write_queue_purge(struct sock *sk) in rawsock_write_queue_purge() 46 static void rawsock_report_error(struct sock *sk, int err) in rawsock_report_error() 57 static int rawsock_release(struct socket *sock) in rawsock_release() argument 59 struct sock *sk = sock->sk; in rawsock_release() 61 pr_debug("sock=%p sk=%p\n", sock, sk); in rawsock_release() 66 if (sock->type == SOCK_RAW) in rawsock_release() 75 static int rawsock_connect(struct socket *sock, struct sockaddr *_addr, in rawsock_connect() argument 78 struct sock *sk = sock->sk; in rawsock_connect() [all …]
|
D | llcp_core.c | 23 void nfc_llcp_sock_link(struct llcp_sock_list *l, struct sock *sk) in nfc_llcp_sock_link() 30 void nfc_llcp_sock_unlink(struct llcp_sock_list *l, struct sock *sk) in nfc_llcp_sock_unlink() 37 void nfc_llcp_socket_remote_param_init(struct nfc_llcp_sock *sock) in nfc_llcp_socket_remote_param_init() argument 39 sock->remote_rw = LLCP_DEFAULT_RW; in nfc_llcp_socket_remote_param_init() 40 sock->remote_miu = LLCP_MAX_MIU + 1; in nfc_llcp_socket_remote_param_init() 43 static void nfc_llcp_socket_purge(struct nfc_llcp_sock *sock) in nfc_llcp_socket_purge() argument 45 struct nfc_llcp_local *local = sock->local; in nfc_llcp_socket_purge() 48 pr_debug("%p\n", &sock->sk); in nfc_llcp_socket_purge() 50 skb_queue_purge(&sock->tx_queue); in nfc_llcp_socket_purge() 51 skb_queue_purge(&sock->tx_pending_queue); in nfc_llcp_socket_purge() [all …]
|
D | llcp.h | 104 struct sock sk; 139 struct sock *parent; 201 void nfc_llcp_sock_link(struct llcp_sock_list *l, struct sock *s); 202 void nfc_llcp_sock_unlink(struct llcp_sock_list *l, struct sock *s); 203 void nfc_llcp_socket_remote_param_init(struct nfc_llcp_sock *sock); 208 struct nfc_llcp_sock *sock); 211 int nfc_llcp_queue_i_frames(struct nfc_llcp_sock *sock); 216 struct sock *nfc_llcp_sock_alloc(struct socket *sock, int type, gfp_t gfp, int kern); 217 void nfc_llcp_sock_free(struct nfc_llcp_sock *sock); 218 void nfc_llcp_accept_unlink(struct sock *sk); [all …]
|
/net/ipv4/ |
D | udp_tunnel.c | 17 struct socket *sock = NULL; in udp_sock_create4() local 20 err = sock_create_kern(net, AF_INET, SOCK_DGRAM, 0, &sock); in udp_sock_create4() 25 err = kernel_setsockopt(sock, SOL_SOCKET, SO_BINDTOIFINDEX, in udp_sock_create4() 35 err = kernel_bind(sock, (struct sockaddr *)&udp_addr, in udp_sock_create4() 44 err = kernel_connect(sock, (struct sockaddr *)&udp_addr, in udp_sock_create4() 50 sock->sk->sk_no_check_tx = !cfg->use_udp_checksums; in udp_sock_create4() 52 *sockp = sock; in udp_sock_create4() 56 if (sock) { in udp_sock_create4() 57 kernel_sock_shutdown(sock, SHUT_RDWR); in udp_sock_create4() 58 sock_release(sock); in udp_sock_create4() [all …]
|
/net/bluetooth/ |
D | sco.c | 49 struct sock *sk; 57 static void sco_sock_close(struct sock *sk); 58 static void sco_sock_kill(struct sock *sk); 78 struct sock *sk = from_timer(sk, t, sk_timer); in sco_sock_timeout() 91 static void sco_sock_set_timer(struct sock *sk, long timeout) in sco_sock_set_timer() 97 static void sco_sock_clear_timer(struct sock *sk) in sco_sock_clear_timer() 133 static void sco_chan_del(struct sock *sk, int err) in sco_chan_del() 161 struct sock *sk; in sco_conn_del() 187 static void __sco_chan_add(struct sco_conn *conn, struct sock *sk, in __sco_chan_add() 188 struct sock *parent) in __sco_chan_add() [all …]
|
D | l2cap_sock.c | 45 static void l2cap_sock_init(struct sock *sk, struct sock *parent); 46 static struct sock *l2cap_sock_alloc(struct net *net, struct socket *sock, 49 bool l2cap_is_socket(struct socket *sock) in l2cap_is_socket() argument 51 return sock && sock->ops == &l2cap_sock_ops; in l2cap_is_socket() 81 static int l2cap_sock_bind(struct socket *sock, struct sockaddr *addr, int alen) in l2cap_sock_bind() argument 83 struct sock *sk = sock->sk; in l2cap_sock_bind() 175 static int l2cap_sock_connect(struct socket *sock, struct sockaddr *addr, in l2cap_sock_connect() argument 178 struct sock *sk = sock->sk; in l2cap_sock_connect() 253 static int l2cap_sock_listen(struct socket *sock, int backlog) in l2cap_sock_listen() argument 255 struct sock *sk = sock->sk; in l2cap_sock_listen() [all …]
|
/net/unix/ |
D | af_unix.c | 182 static inline int unix_our_peer(struct sock *sk, struct sock *osk) in unix_our_peer() 187 static inline int unix_may_send(struct sock *sk, struct sock *osk) in unix_may_send() 192 static inline int unix_recvq_full(struct sock const *sk) in unix_recvq_full() 197 struct sock *unix_peer_get(struct sock *s) in unix_peer_get() 199 struct sock *peer; in unix_peer_get() 248 static void __unix_remove_socket(struct sock *sk) in __unix_remove_socket() 253 static void __unix_insert_socket(struct hlist_head *list, struct sock *sk) in __unix_insert_socket() 259 static inline void unix_remove_socket(struct sock *sk) in unix_remove_socket() 266 static inline void unix_insert_socket(struct hlist_head *list, struct sock *sk) in unix_insert_socket() 273 static struct sock *__unix_find_socket_byname(struct net *net, in __unix_find_socket_byname() [all …]
|
/net/vmw_vsock/ |
D | af_vsock.c | 113 static int __vsock_bind(struct sock *sk, struct sockaddr_vm *addr); 114 static void vsock_sk_destruct(struct sock *sk); 115 static int vsock_queue_rcv_skb(struct sock *sk, struct sk_buff *skb); 182 struct sock *sk = sk_vsock(vsk); in vsock_auto_bind() 229 static struct sock *__vsock_find_bound_socket(struct sockaddr_vm *addr) in __vsock_find_bound_socket() 240 static struct sock *__vsock_find_connected_socket(struct sockaddr_vm *src, in __vsock_find_connected_socket() 292 struct sock *vsock_find_bound_socket(struct sockaddr_vm *addr) in vsock_find_bound_socket() 294 struct sock *sk; in vsock_find_bound_socket() 307 struct sock *vsock_find_connected_socket(struct sockaddr_vm *src, in vsock_find_connected_socket() 310 struct sock *sk; in vsock_find_connected_socket() [all …]
|
D | vmci_transport_notify.h | 40 void (*socket_init) (struct sock *sk); 42 int (*poll_in) (struct sock *sk, size_t target, 44 int (*poll_out) (struct sock *sk, size_t target, 46 void (*handle_notify_pkt) (struct sock *sk, 51 int (*recv_init) (struct sock *sk, size_t target, 53 int (*recv_pre_block) (struct sock *sk, size_t target, 55 int (*recv_pre_dequeue) (struct sock *sk, size_t target, 57 int (*recv_post_dequeue) (struct sock *sk, size_t target, 60 int (*send_init) (struct sock *sk, 62 int (*send_pre_block) (struct sock *sk, [all …]
|
/net/netrom/ |
D | nr_timer.c | 35 void nr_init_timers(struct sock *sk) in nr_init_timers() 48 void nr_start_t1timer(struct sock *sk) in nr_start_t1timer() 55 void nr_start_t2timer(struct sock *sk) in nr_start_t2timer() 62 void nr_start_t4timer(struct sock *sk) in nr_start_t4timer() 69 void nr_start_idletimer(struct sock *sk) in nr_start_idletimer() 77 void nr_start_heartbeat(struct sock *sk) in nr_start_heartbeat() 82 void nr_stop_t1timer(struct sock *sk) in nr_stop_t1timer() 87 void nr_stop_t2timer(struct sock *sk) in nr_stop_t2timer() 92 void nr_stop_t4timer(struct sock *sk) in nr_stop_t4timer() 97 void nr_stop_idletimer(struct sock *sk) in nr_stop_idletimer() [all …]
|
/net/decnet/ |
D | af_decnet.c | 136 struct sock sk; 140 static void dn_keepalive(struct sock *sk); 153 static int __dn_setsockopt(struct socket *sock, int level, int optname, char __user *optval, unsign… 154 static int __dn_getsockopt(struct socket *sock, int level, int optname, char __user *optval, int __… 156 static struct hlist_head *dn_find_list(struct sock *sk) in dn_find_list() 171 struct sock *sk; in check_port() 184 static unsigned short port_alloc(struct sock *sk) in port_alloc() 205 static int dn_hash_sock(struct sock *sk) in dn_hash_sock() 229 static void dn_unhash_sock(struct sock *sk) in dn_unhash_sock() 236 static void dn_unhash_sock_bh(struct sock *sk) in dn_unhash_sock_bh() [all …]
|