Lines Matching full:socket
3 * NET An implementation of the SOCKET network access protocol.
47 * enum sock_type - Socket types
48 * @SOCK_STREAM: stream (connection) socket
49 * @SOCK_DGRAM: datagram (conn.less) socket
50 * @SOCK_RAW: raw socket
52 * @SOCK_SEQPACKET: sequential packet socket
53 * @SOCK_DCCP: Datagram Congestion Control Protocol socket
57 * When adding some new socket type please
58 * grep ARCH_HAS_SOCKET_TYPE include/asm-* /socket.h, at least MIPS
76 /* Flags for socket, socketpair, accept4 */
105 * struct socket - general BSD socket
106 * @state: socket state (%SS_CONNECTED, etc)
107 * @type: socket type (%SOCK_STREAM, etc)
108 * @flags: socket flags (%SOCK_NOSPACE, etc)
109 * @ops: protocol specific socket operations
111 * @sk: internal networking protocol agnostic socket representation
114 struct socket { struct
140 int (*release) (struct socket *sock); argument
141 int (*bind) (struct socket *sock,
144 int (*connect) (struct socket *sock,
147 int (*socketpair)(struct socket *sock1,
148 struct socket *sock2);
149 int (*accept) (struct socket *sock,
150 struct socket *newsock, int flags, bool kern);
151 int (*getname) (struct socket *sock,
154 __poll_t (*poll) (struct file *file, struct socket *sock,
156 int (*ioctl) (struct socket *sock, unsigned int cmd,
159 int (*compat_ioctl) (struct socket *sock, unsigned int cmd,
162 int (*gettstamp) (struct socket *sock, void __user *userstamp,
164 int (*listen) (struct socket *sock, int len);
165 int (*shutdown) (struct socket *sock, int flags);
166 int (*setsockopt)(struct socket *sock, int level,
169 int (*getsockopt)(struct socket *sock, int level,
171 void (*show_fdinfo)(struct seq_file *m, struct socket *sock);
172 int (*sendmsg) (struct socket *sock, struct msghdr *m,
182 int (*recvmsg) (struct socket *sock, struct msghdr *m,
184 int (*mmap) (struct file *file, struct socket *sock,
186 ssize_t (*sendpage) (struct socket *sock, struct page *page,
188 ssize_t (*splice_read)(struct socket *sock, loff_t *ppos,
191 int (*peek_len)(struct socket *sock);
210 int (*create)(struct net *net, struct socket *sock,
230 struct socket **res, int kern);
231 int sock_create(int family, int type, int proto, struct socket **res);
232 int sock_create_kern(struct net *net, int family, int type, int proto, struct socket **res);
233 int sock_create_lite(int family, int type, int proto, struct socket **res);
234 struct socket *sock_alloc(void);
235 void sock_release(struct socket *sock);
236 int sock_sendmsg(struct socket *sock, struct msghdr *msg);
237 int sock_recvmsg(struct socket *sock, struct msghdr *msg, int flags);
238 struct file *sock_alloc_file(struct socket *sock, int flags, const char *dname);
239 struct socket *sockfd_lookup(int fd, int *err);
240 struct socket *sock_from_file(struct file *file);
305 int kernel_sendmsg(struct socket *sock, struct msghdr *msg, struct kvec *vec,
309 int kernel_recvmsg(struct socket *sock, struct msghdr *msg, struct kvec *vec,
312 int kernel_bind(struct socket *sock, struct sockaddr *addr, int addrlen);
313 int kernel_listen(struct socket *sock, int backlog);
314 int kernel_accept(struct socket *sock, struct socket **newsock, int flags);
315 int kernel_connect(struct socket *sock, struct sockaddr *addr, int addrlen,
317 int kernel_getsockname(struct socket *sock, struct sockaddr *addr);
318 int kernel_getpeername(struct socket *sock, struct sockaddr *addr);
319 int kernel_sendpage(struct socket *sock, struct page *page, int offset,
323 int kernel_sock_shutdown(struct socket *sock, enum sock_shutdown_cmd how);
325 /* Routine returns the IP overhead imposed by a (caller-protected) socket. */