tag | line | file | source code |
sock | 216 | drivers/net/d_link.c | static unsigned long d_link_rspace(struct sock *sk); |
sock | 749 | drivers/net/d_link.c | d_link_rspace(struct sock *sk) |
sock | 38 | fs/nfs/sock.c | struct socket *sock; |
sock | 60 | fs/nfs/sock.c | sock = socki_lookup(inode); |
sock | 61 | fs/nfs/sock.c | if (!sock) { |
sock | 84 | fs/nfs/sock.c | result = sock->ops->send(sock, (void *) start, len, 0, 0); |
sock | 132 | fs/nfs/sock.c | result = sock->ops->recvfrom(sock, (void *) start, PAGE_SIZE, 1, 0, |
sock | 89 | include/linux/net.h | int (*create) (struct socket *sock, int protocol); |
sock | 91 | include/linux/net.h | int (*release) (struct socket *sock, struct socket *peer); |
sock | 92 | include/linux/net.h | int (*bind) (struct socket *sock, struct sockaddr *umyaddr, |
sock | 94 | include/linux/net.h | int (*connect) (struct socket *sock, struct sockaddr *uservaddr, |
sock | 97 | include/linux/net.h | int (*accept) (struct socket *sock, struct socket *newsock, |
sock | 99 | include/linux/net.h | int (*getname) (struct socket *sock, struct sockaddr *uaddr, |
sock | 101 | include/linux/net.h | int (*read) (struct socket *sock, char *ubuf, int size, |
sock | 103 | include/linux/net.h | int (*write) (struct socket *sock, char *ubuf, int size, |
sock | 105 | include/linux/net.h | int (*select) (struct socket *sock, int sel_type, |
sock | 107 | include/linux/net.h | int (*ioctl) (struct socket *sock, unsigned int cmd, |
sock | 109 | include/linux/net.h | int (*listen) (struct socket *sock, int len); |
sock | 110 | include/linux/net.h | int (*send) (struct socket *sock, void *buff, int len, int nonblock, |
sock | 112 | include/linux/net.h | int (*recv) (struct socket *sock, void *buff, int len, int nonblock, |
sock | 114 | include/linux/net.h | int (*sendto) (struct socket *sock, void *buff, int len, int nonblock, |
sock | 116 | include/linux/net.h | int (*recvfrom) (struct socket *sock, void *buff, int len, int nonblock, |
sock | 118 | include/linux/net.h | int (*shutdown) (struct socket *sock, int flags); |
sock | 119 | include/linux/net.h | int (*setsockopt) (struct socket *sock, int level, int optname, |
sock | 121 | include/linux/net.h | int (*getsockopt) (struct socket *sock, int level, int optname, |
sock | 123 | include/linux/net.h | int (*fcntl) (struct socket *sock, unsigned int cmd, |
sock | 46 | net/inet/datagram.c | struct sk_buff *skb_recv_datagram(struct sock *sk, unsigned flags, int noblock, int *err) |
sock | 150 | net/inet/datagram.c | int datagram_select(struct sock *sk, int sel_type, select_table *wait) |
sock | 278 | net/inet/icmp.c | ip_queue_xmit((struct sock *)NULL, dev, skb2, 1); |
sock | 345 | net/inet/icmp.c | ip_queue_xmit((struct sock *)NULL, dev, skb2, 1); |
sock | 431 | net/inet/icmp.c | icmp_ioctl(struct sock *sk, int cmd, unsigned long arg) |
sock | 33 | net/inet/icmp.h | extern int icmp_ioctl(struct sock *sk, int cmd, |
sock | 68 | net/inet/ip.c | extern void sort_send(struct sock *sk); |
sock | 115 | net/inet/ip.c | ip_ioctl(struct sock *sk, int cmd, unsigned long arg) |
sock | 950 | net/inet/ip.c | void ip_fragment(struct sock *sk, struct sk_buff *skb, struct device *dev, int is_frag) |
sock | 1329 | net/inet/ip.c | ip_queue_xmit(struct sock *sk, struct device *dev, |
sock | 1405 | net/inet/ip.c | ip_retransmit(struct sock *sk, int all) |
sock | 65 | net/inet/ip.h | extern int ip_ioctl(struct sock *sk, int cmd, |
sock | 76 | net/inet/ip.h | extern void ip_queue_xmit(struct sock *sk, |
sock | 79 | net/inet/ip.h | extern void ip_retransmit(struct sock *sk, int all); |
sock | 60 | net/inet/packet.c | struct sock *sk; |
sock | 62 | net/inet/packet.c | sk = (struct sock *) pt->data; |
sock | 84 | net/inet/packet.c | packet_sendto(struct sock *sk, unsigned char *from, int len, |
sock | 143 | net/inet/packet.c | packet_write(struct sock *sk, unsigned char *buff, |
sock | 151 | net/inet/packet.c | packet_close(struct sock *sk, int timeout) |
sock | 163 | net/inet/packet.c | packet_init(struct sock *sk) |
sock | 176 | net/inet/packet.c | sk->pair = (struct sock *)p; |
sock | 187 | net/inet/packet.c | packet_recvfrom(struct sock *sk, unsigned char *to, int len, |
sock | 236 | net/inet/packet.c | packet_read(struct sock *sk, unsigned char *buff, |
sock | 58 | net/inet/proc.c | struct sock **s_array; |
sock | 59 | net/inet/proc.c | struct sock *sp; |
sock | 62 | net/inet/raw.c | struct sock *sk; |
sock | 68 | net/inet/raw.c | sk = (struct sock *) protocol->data; |
sock | 93 | net/inet/raw.c | struct sock *sk; |
sock | 104 | net/inet/raw.c | sk = (struct sock *) protocol->data; |
sock | 133 | net/inet/raw.c | raw_sendto(struct sock *sk, unsigned char *from, int len, |
sock | 256 | net/inet/raw.c | raw_write(struct sock *sk, unsigned char *buff, int len, int noblock, |
sock | 264 | net/inet/raw.c | raw_close(struct sock *sk, int timeout) |
sock | 281 | net/inet/raw.c | raw_init(struct sock *sk) |
sock | 297 | net/inet/raw.c | sk->pair = (struct sock *)p; |
sock | 310 | net/inet/raw.c | raw_recvfrom(struct sock *sk, unsigned char *to, int len, |
sock | 361 | net/inet/raw.c | raw_read (struct sock *sk, unsigned char *buff, int len, int noblock, |
sock | 30 | net/inet/raw.h | extern int raw_recvfrom(struct sock *sk, unsigned char *to, |
sock | 33 | net/inet/raw.h | extern int raw_read(struct sock *sk, unsigned char *buff, |
sock | 47 | net/inet/skbuff.h | struct sock *sk; |
sock | 103 | net/inet/skbuff.h | extern struct sk_buff * skb_recv_datagram(struct sock *sk,unsigned flags,int noblock, int *err); |
sock | 104 | net/inet/skbuff.h | extern int datagram_select(struct sock *sk, int sel_type, select_table *wait); |
sock | 101 | net/inet/sock.c | print_sk(struct sock *sk) |
sock | 149 | net/inet/sock.c | struct sock *sk; |
sock | 172 | net/inet/sock.c | struct sock *sk; |
sock | 210 | net/inet/sock.c | put_sock(unsigned short num, struct sock *sk) |
sock | 212 | net/inet/sock.c | struct sock *sk1; |
sock | 213 | net/inet/sock.c | struct sock *sk2; |
sock | 264 | net/inet/sock.c | remove_sock(struct sock *sk1) |
sock | 266 | net/inet/sock.c | struct sock *sk2; |
sock | 304 | net/inet/sock.c | destroy_sock(struct sock *sk) |
sock | 444 | net/inet/sock.c | inet_fcntl(struct socket *sock, unsigned int cmd, unsigned long arg) |
sock | 446 | net/inet/sock.c | struct sock *sk; |
sock | 448 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 474 | net/inet/sock.c | inet_setsockopt(struct socket *sock, int level, int optname, |
sock | 477 | net/inet/sock.c | struct sock *sk; |
sock | 485 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 572 | net/inet/sock.c | inet_getsockopt(struct socket *sock, int level, int optname, |
sock | 575 | net/inet/sock.c | struct sock *sk; |
sock | 583 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 672 | net/inet/sock.c | inet_listen(struct socket *sock, int backlog) |
sock | 674 | net/inet/sock.c | struct sock *sk; |
sock | 676 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 701 | net/inet/sock.c | inet_create(struct socket *sock, int protocol) |
sock | 703 | net/inet/sock.c | struct sock *sk; |
sock | 707 | net/inet/sock.c | sk = (struct sock *) kmalloc(sizeof(*sk), GFP_KERNEL); |
sock | 712 | net/inet/sock.c | switch(sock->type) { |
sock | 773 | net/inet/sock.c | sk->socket = sock; |
sock | 827 | net/inet/sock.c | sk->sleep = sock->wait; |
sock | 841 | net/inet/sock.c | sock->data =(void *) sk; |
sock | 880 | net/inet/sock.c | ((struct sock *)(oldsock->data))->protocol)); |
sock | 886 | net/inet/sock.c | inet_release(struct socket *sock, struct socket *peer) |
sock | 888 | net/inet/sock.c | struct sock *sk; |
sock | 890 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 893 | net/inet/sock.c | DPRINTF((DBG_INET, "inet_release(sock = %X, peer = %X)\n", sock, peer)); |
sock | 927 | net/inet/sock.c | sock->data = NULL; |
sock | 938 | net/inet/sock.c | inet_bind(struct socket *sock, struct sockaddr *uaddr, |
sock | 942 | net/inet/sock.c | struct sock *sk, *sk2; |
sock | 946 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 963 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1020 | net/inet/sock.c | inet_connect(struct socket *sock, struct sockaddr * uaddr, |
sock | 1023 | net/inet/sock.c | struct sock *sk; |
sock | 1026 | net/inet/sock.c | sock->conn = NULL; |
sock | 1027 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1033 | net/inet/sock.c | if (sock->state == SS_CONNECTING && sk->state == TCP_ESTABLISHED) |
sock | 1035 | net/inet/sock.c | sock->state = SS_CONNECTED; |
sock | 1040 | net/inet/sock.c | if (sock->state == SS_CONNECTING && sk->protocol == IPPROTO_TCP && |
sock | 1044 | net/inet/sock.c | if (sock->state != SS_CONNECTING) { |
sock | 1060 | net/inet/sock.c | sock->state = SS_CONNECTING; |
sock | 1079 | net/inet/sock.c | sock->state = SS_UNCONNECTED; |
sock | 1084 | net/inet/sock.c | sock->state = SS_CONNECTED; |
sock | 1087 | net/inet/sock.c | sock->state = SS_UNCONNECTED; |
sock | 1102 | net/inet/sock.c | inet_accept(struct socket *sock, struct socket *newsock, int flags) |
sock | 1104 | net/inet/sock.c | struct sock *sk1, *sk2; |
sock | 1107 | net/inet/sock.c | sk1 = (struct sock *) sock->data; |
sock | 1118 | net/inet/sock.c | if (newsock->data) kfree_s(newsock->data, sizeof(struct sock)); |
sock | 1169 | net/inet/sock.c | inet_getname(struct socket *sock, struct sockaddr *uaddr, |
sock | 1173 | net/inet/sock.c | struct sock *sk; |
sock | 1192 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1216 | net/inet/sock.c | inet_read(struct socket *sock, char *ubuf, int size, int noblock) |
sock | 1218 | net/inet/sock.c | struct sock *sk; |
sock | 1220 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1238 | net/inet/sock.c | inet_recv(struct socket *sock, void *ubuf, int size, int noblock, |
sock | 1241 | net/inet/sock.c | struct sock *sk; |
sock | 1243 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1261 | net/inet/sock.c | inet_write(struct socket *sock, char *ubuf, int size, int noblock) |
sock | 1263 | net/inet/sock.c | struct sock *sk; |
sock | 1265 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1288 | net/inet/sock.c | inet_send(struct socket *sock, void *ubuf, int size, int noblock, |
sock | 1291 | net/inet/sock.c | struct sock *sk; |
sock | 1293 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1316 | net/inet/sock.c | inet_sendto(struct socket *sock, void *ubuf, int size, int noblock, |
sock | 1319 | net/inet/sock.c | struct sock *sk; |
sock | 1321 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1347 | net/inet/sock.c | inet_recvfrom(struct socket *sock, void *ubuf, int size, int noblock, |
sock | 1350 | net/inet/sock.c | struct sock *sk; |
sock | 1352 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1374 | net/inet/sock.c | inet_shutdown(struct socket *sock, int how) |
sock | 1376 | net/inet/sock.c | struct sock *sk; |
sock | 1386 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1391 | net/inet/sock.c | if (sock->state == SS_CONNECTING && sk->state == TCP_ESTABLISHED) |
sock | 1392 | net/inet/sock.c | sock->state = SS_CONNECTED; |
sock | 1402 | net/inet/sock.c | inet_select(struct socket *sock, int sel_type, select_table *wait ) |
sock | 1404 | net/inet/sock.c | struct sock *sk; |
sock | 1406 | net/inet/sock.c | sk = (struct sock *) sock->data; |
sock | 1421 | net/inet/sock.c | inet_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg) |
sock | 1423 | net/inet/sock.c | struct sock *sk; |
sock | 1428 | net/inet/sock.c | if (sock && (sk = (struct sock *) sock->data) == NULL) { |
sock | 1501 | net/inet/sock.c | sock_wmalloc(struct sock *sk, unsigned long size, int force, |
sock | 1520 | net/inet/sock.c | sock_rmalloc(struct sock *sk, unsigned long size, int force, int priority) |
sock | 1539 | net/inet/sock.c | sock_rspace(struct sock *sk) |
sock | 1554 | net/inet/sock.c | sock_wspace(struct sock *sk) |
sock | 1566 | net/inet/sock.c | sock_wfree(struct sock *sk, void *mem, unsigned long size) |
sock | 1587 | net/inet/sock.c | sock_rfree(struct sock *sk, void *mem, unsigned long size) |
sock | 1606 | net/inet/sock.c | struct sock *get_sock(struct proto *prot, unsigned short num, |
sock | 1610 | net/inet/sock.c | struct sock *s; |
sock | 1646 | net/inet/sock.c | void release_sock(struct sock *sk) |
sock | 81 | net/inet/sock.h | struct sock *next; |
sock | 82 | net/inet/sock.h | struct sock *pair; |
sock | 129 | net/inet/sock.h | void *(*wmalloc)(struct sock *sk, |
sock | 132 | net/inet/sock.h | void *(*rmalloc)(struct sock *sk, |
sock | 135 | net/inet/sock.h | void (*wfree)(struct sock *sk, void *mem, |
sock | 137 | net/inet/sock.h | void (*rfree)(struct sock *sk, void *mem, |
sock | 139 | net/inet/sock.h | unsigned long (*rspace)(struct sock *sk); |
sock | 140 | net/inet/sock.h | unsigned long (*wspace)(struct sock *sk); |
sock | 141 | net/inet/sock.h | void (*close)(struct sock *sk, int timeout); |
sock | 142 | net/inet/sock.h | int (*read)(struct sock *sk, unsigned char *to, |
sock | 144 | net/inet/sock.h | int (*write)(struct sock *sk, unsigned char *to, |
sock | 146 | net/inet/sock.h | int (*sendto)(struct sock *sk, |
sock | 150 | net/inet/sock.h | int (*recvfrom)(struct sock *sk, |
sock | 159 | net/inet/sock.h | int (*connect)(struct sock *sk, |
sock | 161 | net/inet/sock.h | struct sock *(*accept) (struct sock *sk, int flags); |
sock | 162 | net/inet/sock.h | void (*queue_xmit)(struct sock *sk, |
sock | 165 | net/inet/sock.h | void (*retransmit)(struct sock *sk, int all); |
sock | 166 | net/inet/sock.h | void (*write_wakeup)(struct sock *sk); |
sock | 167 | net/inet/sock.h | void (*read_wakeup)(struct sock *sk); |
sock | 172 | net/inet/sock.h | int (*select)(struct sock *sk, int which, |
sock | 174 | net/inet/sock.h | int (*ioctl)(struct sock *sk, int cmd, |
sock | 176 | net/inet/sock.h | int (*init)(struct sock *sk); |
sock | 177 | net/inet/sock.h | void (*shutdown)(struct sock *sk, int how); |
sock | 180 | net/inet/sock.h | struct sock *sock_array[SOCK_ARRAY_SIZE]; |
sock | 198 | net/inet/sock.h | extern void destroy_sock(struct sock *sk); |
sock | 200 | net/inet/sock.h | extern void put_sock(unsigned short, struct sock *); |
sock | 201 | net/inet/sock.h | extern void release_sock(struct sock *sk); |
sock | 202 | net/inet/sock.h | extern struct sock *get_sock(struct proto *, unsigned short, |
sock | 205 | net/inet/sock.h | extern void print_sk(struct sock *); |
sock | 206 | net/inet/sock.h | extern void *sock_wmalloc(struct sock *sk, |
sock | 209 | net/inet/sock.h | extern void *sock_rmalloc(struct sock *sk, |
sock | 212 | net/inet/sock.h | extern void sock_wfree(struct sock *sk, void *mem, |
sock | 214 | net/inet/sock.h | extern void sock_rfree(struct sock *sk, void *mem, |
sock | 216 | net/inet/sock.h | extern unsigned long sock_rspace(struct sock *sk); |
sock | 217 | net/inet/sock.h | extern unsigned long sock_wspace(struct sock *sk); |
sock | 221 | net/inet/sock.h | extern struct sock *timer_base; |
sock | 223 | net/inet/sock.h | void delete_timer (struct sock *); |
sock | 224 | net/inet/sock.h | void reset_timer (struct sock *, int, unsigned long); |
sock | 129 | net/inet/tcp.c | get_firstr(struct sock *sk) |
sock | 153 | net/inet/tcp.c | static void tcp_time_wait(struct sock *sk) |
sock | 170 | net/inet/tcp.c | tcp_retransmit(struct sock *sk, int all) |
sock | 199 | net/inet/tcp.c | struct sock *sk; |
sock | 253 | net/inet/tcp.c | tcp_readable(struct sock *sk) |
sock | 321 | net/inet/tcp.c | tcp_select(struct sock *sk, int sel_type, select_table *wait) |
sock | 410 | net/inet/tcp.c | tcp_ioctl(struct sock *sk, int cmd, unsigned long arg) |
sock | 545 | net/inet/tcp.c | unsigned long daddr, int len, struct sock *sk) |
sock | 554 | net/inet/tcp.c | tcp_send_partial(struct sock *sk) |
sock | 592 | net/inet/tcp.c | struct sock *sk, |
sock | 671 | net/inet/tcp.c | tcp_build_header(struct tcphdr *th, struct sock *sk, int push) |
sock | 697 | net/inet/tcp.c | tcp_write(struct sock *sk, unsigned char *from, |
sock | 961 | net/inet/tcp.c | tcp_sendto(struct sock *sk, unsigned char *from, |
sock | 977 | net/inet/tcp.c | tcp_read_wakeup(struct sock *sk) |
sock | 1048 | net/inet/tcp.c | cleanup_rbuf(struct sock *sk) |
sock | 1119 | net/inet/tcp.c | tcp_read_urg(struct sock * sk, int nonblock, |
sock | 1216 | net/inet/tcp.c | tcp_read(struct sock *sk, unsigned char *to, |
sock | 1447 | net/inet/tcp.c | tcp_shutdown(struct sock *sk, int how) |
sock | 1533 | net/inet/tcp.c | tcp_recvfrom(struct sock *sk, unsigned char *to, |
sock | 1644 | net/inet/tcp.c | tcp_options(struct sock *sk, struct tcphdr *th) |
sock | 1698 | net/inet/tcp.c | tcp_conn_request(struct sock *sk, struct sk_buff *skb, |
sock | 1705 | net/inet/tcp.c | struct sock *newsk; |
sock | 1741 | net/inet/tcp.c | newsk = (struct sock *) kmalloc(sizeof(struct sock), GFP_ATOMIC); |
sock | 1897 | net/inet/tcp.c | tcp_close(struct sock *sk, int timeout) |
sock | 2058 | net/inet/tcp.c | tcp_write_xmit(struct sock *sk) |
sock | 2104 | net/inet/tcp.c | sort_send(struct sock *sk) |
sock | 2133 | net/inet/tcp.c | tcp_ack(struct sock *sk, struct tcphdr *th, unsigned long saddr, int len) |
sock | 2400 | net/inet/tcp.c | tcp_data(struct sk_buff *skb, struct sock *sk, |
sock | 2637 | net/inet/tcp.c | tcp_urg(struct sock *sk, struct tcphdr *th, unsigned long saddr) |
sock | 2667 | net/inet/tcp.c | tcp_fin(struct sock *sk, struct tcphdr *th, |
sock | 2712 | net/inet/tcp.c | static struct sock * |
sock | 2713 | net/inet/tcp.c | tcp_accept(struct sock *sk, int flags) |
sock | 2715 | net/inet/tcp.c | struct sock *newsk; |
sock | 2764 | net/inet/tcp.c | tcp_connect(struct sock *sk, struct sockaddr_in *usin, int addr_len) |
sock | 2864 | net/inet/tcp.c | tcp_sequence(struct sock *sk, struct tcphdr *th, short len, |
sock | 2917 | net/inet/tcp.c | struct sock *sk; |
sock | 3332 | net/inet/tcp.c | tcp_write_wakeup(struct sock *sk) |
sock | 139 | net/inet/tcp.h | extern void tcp_shutdown (struct sock *sk, int how); |
sock | 145 | net/inet/tcp.h | extern int tcp_ioctl(struct sock *sk, int cmd, unsigned long arg); |
sock | 53 | net/inet/timer.c | delete_timer (struct sock *t) |
sock | 67 | net/inet/timer.c | reset_timer (struct sock *t, int timeout, unsigned long len) |
sock | 92 | net/inet/timer.c | struct sock *sk = (struct sock*)data; |
sock | 99 | net/inet/udp.c | struct sock *sk; |
sock | 204 | net/inet/udp.c | unsigned long daddr, int len, struct sock *sk) |
sock | 215 | net/inet/udp.c | udp_send(struct sock *sk, struct sockaddr_in *sin, |
sock | 302 | net/inet/udp.c | udp_sendto(struct sock *sk, unsigned char *from, int len, int noblock, |
sock | 351 | net/inet/udp.c | udp_write(struct sock *sk, unsigned char *buff, int len, int noblock, |
sock | 359 | net/inet/udp.c | udp_ioctl(struct sock *sk, int cmd, unsigned long arg) |
sock | 434 | net/inet/udp.c | udp_recvfrom(struct sock *sk, unsigned char *to, int len, |
sock | 500 | net/inet/udp.c | udp_read(struct sock *sk, unsigned char *buff, int len, int noblock, |
sock | 508 | net/inet/udp.c | udp_connect(struct sock *sk, struct sockaddr_in *usin, int addr_len) |
sock | 535 | net/inet/udp.c | udp_close(struct sock *sk, int timeout) |
sock | 550 | net/inet/udp.c | struct sock *sk; |
sock | 36 | net/inet/udp.h | extern int udp_recvfrom(struct sock *sk, unsigned char *to, |
sock | 39 | net/inet/udp.h | extern int udp_read(struct sock *sk, unsigned char *buff, |
sock | 41 | net/inet/udp.h | extern int udp_connect(struct sock *sk, |
sock | 47 | net/inet/udp.h | extern int udp_ioctl(struct sock *sk, int cmd, unsigned long arg); |
sock | 139 | net/socket.c | struct socket *sock; |
sock | 141 | net/socket.c | for (sock = sockets; sock <= last_socket; ++sock) |
sock | 142 | net/socket.c | if (sock->state != SS_FREE && SOCK_INODE(sock) == inode) return(sock); |
sock | 161 | net/socket.c | struct socket *sock; |
sock | 165 | net/socket.c | for (sock = sockets; sock <= last_socket; ++sock) { |
sock | 166 | net/socket.c | if (sock->state == SS_FREE) { |
sock | 167 | net/socket.c | sock->state = SS_UNCONNECTED; |
sock | 169 | net/socket.c | sock->flags = 0; |
sock | 170 | net/socket.c | sock->ops = NULL; |
sock | 171 | net/socket.c | sock->data = NULL; |
sock | 172 | net/socket.c | sock->conn = NULL; |
sock | 173 | net/socket.c | sock->iconn = NULL; |
sock | 182 | net/socket.c | if (!(SOCK_INODE(sock) = get_empty_inode())) { |
sock | 184 | net/socket.c | sock->state = SS_FREE; |
sock | 187 | net/socket.c | SOCK_INODE(sock)->i_mode = S_IFSOCK; |
sock | 188 | net/socket.c | SOCK_INODE(sock)->i_uid = current->euid; |
sock | 189 | net/socket.c | SOCK_INODE(sock)->i_gid = current->egid; |
sock | 191 | net/socket.c | sock->wait = &SOCK_INODE(sock)->i_wait; |
sock | 194 | net/socket.c | sock, SOCK_INODE(sock))); |
sock | 195 | net/socket.c | return(sock); |
sock | 220 | net/socket.c | sock_release(struct socket *sock) |
sock | 226 | net/socket.c | sock, SOCK_INODE(sock))); |
sock | 227 | net/socket.c | if ((oldstate = sock->state) != SS_UNCONNECTED) |
sock | 228 | net/socket.c | sock->state = SS_DISCONNECTING; |
sock | 231 | net/socket.c | for (peersock = sock->iconn; peersock; peersock = nextsock) { |
sock | 240 | net/socket.c | peersock = (oldstate == SS_CONNECTED) ? sock->conn : NULL; |
sock | 241 | net/socket.c | if (sock->ops) sock->ops->release(sock, peersock); |
sock | 243 | net/socket.c | sock->state = SS_FREE; /* this really releases us */ |
sock | 247 | net/socket.c | iput(SOCK_INODE(sock)); |
sock | 262 | net/socket.c | struct socket *sock; |
sock | 265 | net/socket.c | if (!(sock = socki_lookup(inode))) { |
sock | 269 | net/socket.c | if (sock->flags & SO_ACCEPTCON) return(-EINVAL); |
sock | 270 | net/socket.c | return(sock->ops->read(sock, ubuf, size, (file->f_flags & O_NONBLOCK))); |
sock | 277 | net/socket.c | struct socket *sock; |
sock | 280 | net/socket.c | if (!(sock = socki_lookup(inode))) { |
sock | 284 | net/socket.c | if (sock->flags & SO_ACCEPTCON) return(-EINVAL); |
sock | 285 | net/socket.c | return(sock->ops->write(sock, ubuf, size,(file->f_flags & O_NONBLOCK))); |
sock | 302 | net/socket.c | struct socket *sock; |
sock | 306 | net/socket.c | if (!(sock = socki_lookup(inode))) { |
sock | 310 | net/socket.c | return(sock->ops->ioctl(sock, cmd, arg)); |
sock | 317 | net/socket.c | struct socket *sock; |
sock | 322 | net/socket.c | if (!(sock = socki_lookup(inode))) { |
sock | 328 | net/socket.c | if (sock->ops && sock->ops->select) |
sock | 329 | net/socket.c | return(sock->ops->select(sock, sel_type, wait)); |
sock | 337 | net/socket.c | struct socket *sock; |
sock | 344 | net/socket.c | if (!(sock = socki_lookup(inode))) { |
sock | 348 | net/socket.c | sock_release(sock); |
sock | 419 | net/socket.c | struct socket *sock; |
sock | 452 | net/socket.c | if (!(sock = sock_alloc(1))) { |
sock | 456 | net/socket.c | sock->type = type; |
sock | 457 | net/socket.c | sock->ops = ops; |
sock | 458 | net/socket.c | if ((i = sock->ops->create(sock, protocol)) < 0) { |
sock | 459 | net/socket.c | sock_release(sock); |
sock | 463 | net/socket.c | if ((fd = get_fd(SOCK_INODE(sock))) < 0) { |
sock | 464 | net/socket.c | sock_release(sock); |
sock | 527 | net/socket.c | struct socket *sock; |
sock | 533 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 534 | net/socket.c | if ((i = sock->ops->bind(sock, umyaddr, addrlen)) < 0) { |
sock | 550 | net/socket.c | struct socket *sock; |
sock | 555 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 556 | net/socket.c | if (sock->state != SS_UNCONNECTED) { |
sock | 560 | net/socket.c | if (sock->ops && sock->ops->listen) sock->ops->listen(sock, backlog); |
sock | 561 | net/socket.c | sock->flags |= SO_ACCEPTCON; |
sock | 575 | net/socket.c | struct socket *sock, *newsock; |
sock | 582 | net/socket.c | if (!(sock = sockfd_lookup(fd, &file))) return(-ENOTSOCK); |
sock | 583 | net/socket.c | if (sock->state != SS_UNCONNECTED) { |
sock | 587 | net/socket.c | if (!(sock->flags & SO_ACCEPTCON)) { |
sock | 597 | net/socket.c | newsock->type = sock->type; |
sock | 598 | net/socket.c | newsock->ops = sock->ops; |
sock | 599 | net/socket.c | if ((i = sock->ops->dup(newsock, sock)) < 0) { |
sock | 604 | net/socket.c | i = newsock->ops->accept(sock, newsock, file->f_flags); |
sock | 616 | net/socket.c | sock, newsock)); |
sock | 629 | net/socket.c | struct socket *sock; |
sock | 637 | net/socket.c | if (!(sock = sockfd_lookup(fd, &file))) return(-ENOTSOCK); |
sock | 638 | net/socket.c | switch(sock->state) { |
sock | 647 | net/socket.c | return(sock->ops->connect(sock, uservaddr, |
sock | 654 | net/socket.c | i = sock->ops->connect(sock, uservaddr, addrlen, file->f_flags); |
sock | 666 | net/socket.c | struct socket *sock; |
sock | 671 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 672 | net/socket.c | return(sock->ops->getname(sock, usockaddr, usockaddr_len, 0)); |
sock | 679 | net/socket.c | struct socket *sock; |
sock | 684 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 685 | net/socket.c | return(sock->ops->getname(sock, usockaddr, usockaddr_len, 1)); |
sock | 692 | net/socket.c | struct socket *sock; |
sock | 701 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 703 | net/socket.c | return(sock->ops->send(sock, buff, len, (file->f_flags & O_NONBLOCK), flags)); |
sock | 711 | net/socket.c | struct socket *sock; |
sock | 720 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 722 | net/socket.c | return(sock->ops->sendto(sock, buff, len, (file->f_flags & O_NONBLOCK), |
sock | 730 | net/socket.c | struct socket *sock; |
sock | 739 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 741 | net/socket.c | return(sock->ops->recv(sock, buff, len,(file->f_flags & O_NONBLOCK), flags)); |
sock | 749 | net/socket.c | struct socket *sock; |
sock | 758 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 760 | net/socket.c | return(sock->ops->recvfrom(sock, buff, len, (file->f_flags & O_NONBLOCK), |
sock | 768 | net/socket.c | struct socket *sock; |
sock | 778 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 780 | net/socket.c | return(sock->ops->setsockopt(sock, level, optname, optval, optlen)); |
sock | 787 | net/socket.c | struct socket *sock; |
sock | 797 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 799 | net/socket.c | if (!sock->ops || !sock->ops->getsockopt) return(0); |
sock | 800 | net/socket.c | return(sock->ops->getsockopt(sock, level, optname, optval, optlen)); |
sock | 807 | net/socket.c | struct socket *sock; |
sock | 815 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) return(-ENOTSOCK); |
sock | 817 | net/socket.c | return(sock->ops->shutdown(sock, how)); |
sock | 824 | net/socket.c | struct socket *sock; |
sock | 826 | net/socket.c | sock = socki_lookup (filp->f_inode); |
sock | 827 | net/socket.c | if (sock != NULL && sock->ops != NULL && sock->ops->fcntl != NULL) |
sock | 828 | net/socket.c | return(sock->ops->fcntl(sock, cmd, arg)); |
sock | 1060 | net/socket.c | struct socket *sock; |
sock | 1070 | net/socket.c | for (sock = sockets; sock <= last_socket; ++sock) sock->state = SS_FREE; |
sock | 57 | net/unix/sock.c | static int unix_proto_create(struct socket *sock, int protocol); |
sock | 59 | net/unix/sock.c | static int unix_proto_release(struct socket *sock, struct socket *peer); |
sock | 60 | net/unix/sock.c | static int unix_proto_bind(struct socket *sock, struct sockaddr *umyaddr, |
sock | 62 | net/unix/sock.c | static int unix_proto_connect(struct socket *sock, struct sockaddr *uservaddr, |
sock | 65 | net/unix/sock.c | static int unix_proto_accept(struct socket *sock, struct socket *newsock, |
sock | 67 | net/unix/sock.c | static int unix_proto_getname(struct socket *sock, struct sockaddr *usockaddr, |
sock | 69 | net/unix/sock.c | static int unix_proto_read(struct socket *sock, char *ubuf, int size, |
sock | 71 | net/unix/sock.c | static int unix_proto_write(struct socket *sock, char *ubuf, int size, |
sock | 73 | net/unix/sock.c | static int unix_proto_select(struct socket *sock, int sel_type, select_table * wait); |
sock | 74 | net/unix/sock.c | static int unix_proto_ioctl(struct socket *sock, unsigned int cmd, |
sock | 76 | net/unix/sock.c | static int unix_proto_listen(struct socket *sock, int backlog); |
sock | 77 | net/unix/sock.c | static int unix_proto_send(struct socket *sock, void *buff, int len, |
sock | 79 | net/unix/sock.c | static int unix_proto_recv(struct socket *sock, void *buff, int len, |
sock | 81 | net/unix/sock.c | static int unix_proto_sendto(struct socket *sock, void *buff, int len, |
sock | 84 | net/unix/sock.c | static int unix_proto_recvfrom(struct socket *sock, void *buff, int len, |
sock | 88 | net/unix/sock.c | static int unix_proto_shutdown(struct socket *sock, int how); |
sock | 90 | net/unix/sock.c | static int unix_proto_setsockopt(struct socket *sock, int level, int optname, |
sock | 92 | net/unix/sock.c | static int unix_proto_getsockopt(struct socket *sock, int level, int optname, |
sock | 146 | net/unix/sock.c | unix_proto_listen(struct socket *sock, int backlog) |
sock | 153 | net/unix/sock.c | unix_proto_setsockopt(struct socket *sock, int level, int optname, |
sock | 161 | net/unix/sock.c | unix_proto_getsockopt(struct socket *sock, int level, int optname, |
sock | 168 | net/unix/sock.c | unix_proto_sendto(struct socket *sock, void *buff, int len, int nonblock, |
sock | 175 | net/unix/sock.c | unix_proto_recvfrom(struct socket *sock, void *buff, int len, int nonblock, |
sock | 183 | net/unix/sock.c | unix_proto_shutdown(struct socket *sock, int how) |
sock | 191 | net/unix/sock.c | unix_proto_send(struct socket *sock, void *buff, int len, int nonblock, |
sock | 195 | net/unix/sock.c | return(unix_proto_write(sock, (char *) buff, len, nonblock)); |
sock | 201 | net/unix/sock.c | unix_proto_recv(struct socket *sock, void *buff, int len, int nonblock, |
sock | 205 | net/unix/sock.c | return(unix_proto_read(sock, (char *) buff, len, nonblock)); |
sock | 286 | net/unix/sock.c | unix_proto_create(struct socket *sock, int protocol) |
sock | 290 | net/unix/sock.c | dprintf(1, "UNIX: create: socket 0x%x, proto %d\n", sock, protocol); |
sock | 305 | net/unix/sock.c | upd->socket = sock; |
sock | 306 | net/unix/sock.c | UN_DATA(sock) = upd; |
sock | 322 | net/unix/sock.c | unix_proto_release(struct socket *sock, struct socket *peer) |
sock | 324 | net/unix/sock.c | struct unix_proto_data *upd = UN_DATA(sock); |
sock | 326 | net/unix/sock.c | dprintf(1, "UNIX: release: socket 0x%x, unix_data 0x%x\n", sock, upd); |
sock | 328 | net/unix/sock.c | if (upd->socket != sock) { |
sock | 337 | net/unix/sock.c | UN_DATA(sock) = NULL; |
sock | 355 | net/unix/sock.c | unix_proto_bind(struct socket *sock, struct sockaddr *umyaddr, |
sock | 359 | net/unix/sock.c | struct unix_proto_data *upd = UN_DATA(sock); |
sock | 364 | net/unix/sock.c | dprintf(1, "UNIX: bind: socket 0x%x, len=%d\n", sock, sockaddr_len); |
sock | 411 | net/unix/sock.c | unix_proto_connect(struct socket *sock, struct sockaddr *uservaddr, |
sock | 422 | net/unix/sock.c | dprintf(1, "UNIX: connect: socket 0x%x, servlen=%d\n", sock, sockaddr_len); |
sock | 429 | net/unix/sock.c | if (sock->state == SS_CONNECTING) return(-EINPROGRESS); |
sock | 430 | net/unix/sock.c | if (sock->state == SS_CONNECTED) return(-EISCONN); |
sock | 466 | net/unix/sock.c | if ((i = sock_awaitconn(sock, serv_upd->socket)) < 0) { |
sock | 470 | net/unix/sock.c | if (sock->conn) { |
sock | 471 | net/unix/sock.c | unix_data_ref(UN_DATA(sock->conn)); |
sock | 472 | net/unix/sock.c | UN_DATA(sock)->peerupd = UN_DATA(sock->conn); /* ref server */ |
sock | 499 | net/unix/sock.c | unix_proto_accept(struct socket *sock, struct socket *newsock, int flags) |
sock | 504 | net/unix/sock.c | sock, newsock); |
sock | 510 | net/unix/sock.c | while(!(clientsock = sock->iconn)) { |
sock | 512 | net/unix/sock.c | interruptible_sleep_on(sock->wait); |
sock | 523 | net/unix/sock.c | sock->iconn = clientsock->next; |
sock | 531 | net/unix/sock.c | UN_DATA(newsock)->sockaddr_un = UN_DATA(sock)->sockaddr_un; |
sock | 532 | net/unix/sock.c | UN_DATA(newsock)->sockaddr_len = UN_DATA(sock)->sockaddr_len; |
sock | 540 | net/unix/sock.c | unix_proto_getname(struct socket *sock, struct sockaddr *usockaddr, |
sock | 547 | net/unix/sock.c | dprintf(1, "UNIX: getname: socket 0x%x for %s\n", sock, peer?"peer":"self"); |
sock | 549 | net/unix/sock.c | if (sock->state != SS_CONNECTED) { |
sock | 553 | net/unix/sock.c | upd = UN_DATA(sock->conn); |
sock | 555 | net/unix/sock.c | upd = UN_DATA(sock); |
sock | 575 | net/unix/sock.c | unix_proto_read(struct socket *sock, char *ubuf, int size, int nonblock) |
sock | 582 | net/unix/sock.c | upd = UN_DATA(sock); |
sock | 584 | net/unix/sock.c | if (sock->state != SS_CONNECTED) { |
sock | 586 | net/unix/sock.c | return((sock->state == SS_DISCONNECTING) ? 0 : -EINVAL); |
sock | 590 | net/unix/sock.c | interruptible_sleep_on(sock->wait); |
sock | 620 | net/unix/sock.c | if (sock->state == SS_CONNECTED) wake_up(sock->conn->wait); |
sock | 633 | net/unix/sock.c | unix_proto_write(struct socket *sock, char *ubuf, int size, int nonblock) |
sock | 640 | net/unix/sock.c | if (sock->state != SS_CONNECTED) { |
sock | 642 | net/unix/sock.c | if (sock->state == SS_DISCONNECTING) { |
sock | 648 | net/unix/sock.c | pupd = UN_DATA(sock)->peerupd; /* safer than sock->conn */ |
sock | 653 | net/unix/sock.c | interruptible_sleep_on(sock->wait); |
sock | 658 | net/unix/sock.c | if (sock->state == SS_DISCONNECTING) { |
sock | 682 | net/unix/sock.c | if (sock->state == SS_DISCONNECTING) { |
sock | 697 | net/unix/sock.c | if (sock->state == SS_CONNECTED) wake_up(sock->conn->wait); |
sock | 705 | net/unix/sock.c | unix_proto_select(struct socket *sock, int sel_type, select_table * wait) |
sock | 710 | net/unix/sock.c | if (sock->flags & SO_ACCEPTCON) { |
sock | 713 | net/unix/sock.c | sock->iconn ? "" : "no "); |
sock | 714 | net/unix/sock.c | if (sock->iconn) return(1); |
sock | 715 | net/unix/sock.c | select_wait(sock->wait, wait); |
sock | 716 | net/unix/sock.c | return(sock->iconn ? 1 : 0); |
sock | 719 | net/unix/sock.c | select_wait(sock->wait, wait); |
sock | 724 | net/unix/sock.c | upd = UN_DATA(sock); |
sock | 729 | net/unix/sock.c | else if (sock->state != SS_CONNECTED) { |
sock | 733 | net/unix/sock.c | select_wait(sock->wait,wait); |
sock | 737 | net/unix/sock.c | if (sock->state != SS_CONNECTED) { |
sock | 741 | net/unix/sock.c | peerupd = UN_DATA(sock->conn); |
sock | 745 | net/unix/sock.c | select_wait(sock->wait,wait); |
sock | 756 | net/unix/sock.c | unix_proto_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg) |
sock | 761 | net/unix/sock.c | upd = UN_DATA(sock); |
sock | 762 | net/unix/sock.c | peerupd = (sock->state == SS_CONNECTED) ? UN_DATA(sock->conn) : NULL; |
sock | 766 | net/unix/sock.c | if (sock->flags & SO_ACCEPTCON) return(-EINVAL); |
sock | 776 | net/unix/sock.c | if (sock->flags & SO_ACCEPTCON) return(-EINVAL); |