Lines Matching refs:socket

31  *					if the max backlog of the listen socket
51 * ECONNREFUSED is not returned from one end of a connected() socket to the
54 * and a fake inode identifier (nor the BSD first socket fstat twice bug).
56 * accept() returns a path name even if the connecting socket has closed
66 * - client shutdown killed server socket.
72 * - "Abstract" (not FS based) socket bindings.
89 #include <linux/socket.h>
127 * each socket state is protected by separate spinlock.
271 * Check unix socket name:
418 * If a datagram socket is connected to a socket not itself connected
419 * to the first socket (eg, /dev/log), clients may only enqueue more
420 * messages if the present receive queue of the server socket is not
423 * up on the peer_wait wait queue of a socket upon reception of a
427 * socket might be less than that of its clients if these break their
428 * association with it or if the server socket is closed while clients
433 * socket is enqueued on the peer_wait queue of the server socket
434 * whose wake function does a wake_up on the ordinary client socket
437 * association to the server socket is dissolved or after a wake up
554 /* When dgram socket disconnects (or changes its peer), we clear its receive
586 pr_info("Attempt to release alive unix socket: %p\n", sk);
652 /* Try to flush out this socket. Throw out buffers at least */
724 static int unix_listen(struct socket *sock, int backlog)
735 goto out; /* No listens on an unbound socket */
753 static int unix_release(struct socket *);
754 static int unix_bind(struct socket *, struct sockaddr *, int);
755 static int unix_stream_connect(struct socket *, struct sockaddr *,
757 static int unix_socketpair(struct socket *, struct socket *);
758 static int unix_accept(struct socket *, struct socket *, struct proto_accept_arg *arg);
759 static int unix_getname(struct socket *, struct sockaddr *, int);
760 static __poll_t unix_poll(struct file *, struct socket *, poll_table *);
761 static __poll_t unix_dgram_poll(struct file *, struct socket *,
763 static int unix_ioctl(struct socket *, unsigned int, unsigned long);
765 static int unix_compat_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg);
767 static int unix_shutdown(struct socket *, int);
768 static int unix_stream_sendmsg(struct socket *, struct msghdr *, size_t);
769 static int unix_stream_recvmsg(struct socket *, struct msghdr *, size_t, int);
770 static ssize_t unix_stream_splice_read(struct socket *, loff_t *ppos,
773 static int unix_dgram_sendmsg(struct socket *, struct msghdr *, size_t);
774 static int unix_dgram_recvmsg(struct socket *, struct msghdr *, size_t, int);
777 static int unix_dgram_connect(struct socket *, struct sockaddr *,
779 static int unix_seqpacket_sendmsg(struct socket *, struct msghdr *, size_t);
780 static int unix_seqpacket_recvmsg(struct socket *, struct msghdr *, size_t,
802 static void unix_show_fdinfo(struct seq_file *m, struct socket *sock)
903 /* Nothing to do here, unix socket does not need a ->close().
910 /* Nothing to do here, unix socket does not need a ->unhash().
952 static struct sock *unix_create1(struct net *net, struct socket *sock, int kern, int type)
1003 static int unix_create(struct net *net, struct socket *sock, int protocol,
1041 static int unix_release(struct socket *sock)
1304 static int unix_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
1349 static int unix_dgram_connect(struct socket *sock, struct sockaddr *addr,
1387 /* Apparently VFS overslept socket death. Retry. */
1463 static int unix_stream_connect(struct socket *sock, struct sockaddr *uaddr,
1524 /* Apparently VFS overslept socket death. Retry. */
1556 attempt to connect are eliminated by checking socket
1560 Well, and we have to recheck the state after socket locked.
1662 static int unix_socketpair(struct socket *socka, struct socket *sockb)
1681 static void unix_sock_inherit_flags(const struct socket *old,
1682 struct socket *new)
1692 static int unix_accept(struct socket *sock, struct socket *newsock,
1707 /* If socket state is TCP_LISTEN it cannot change (for now...),
1724 /* attach accepted sock to socket */
1738 static int unix_getname(struct socket *sock, struct sockaddr *uaddr, int peer)
1849 static bool unix_passcred_enabled(const struct socket *sock,
1861 * We include credentials if source or destination socket
1864 static void maybe_add_creds(struct sk_buff *skb, const struct socket *sock,
1910 static int unix_dgram_sendmsg(struct socket *sock, struct msghdr *msg,
2136 static int queue_oob(struct socket *sock, struct msghdr *msg, struct sock *other,
2190 static int unix_stream_sendmsg(struct socket *sock, struct msghdr *msg,
2323 static int unix_seqpacket_sendmsg(struct socket *sock, struct msghdr *msg,
2342 static int unix_seqpacket_recvmsg(struct socket *sock, struct msghdr *msg,
2367 struct socket *sock = sk->sk_socket;
2402 /* Signal EOF on disconnected non-blocking SEQPACKET socket. */
2475 static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size,
2553 struct socket *socket;
2564 struct socket *sock = state->socket;
2662 struct socket *sock = state->socket;
2694 /* Lock the socket to prevent queue disordering
2817 * sure it was dropped from the socket queue
2892 .socket = sk->sk_socket,
2901 static int unix_stream_recvmsg(struct socket *sock, struct msghdr *msg,
2906 .socket = sock,
2926 return skb_splice_bits(skb, state->socket->sk,
2931 static ssize_t unix_stream_splice_read(struct socket *sock, loff_t *ppos,
2937 .socket = sock,
2953 static int unix_shutdown(struct socket *sock, int mode)
3068 static int unix_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
3110 static int unix_compat_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
3116 static __poll_t unix_poll(struct file *file, struct socket *sock, poll_table *wait)
3159 static __poll_t unix_dgram_poll(struct file *file, struct socket *sock,