Lines Matching refs:sockets
236 static void add_vsock_stat(struct list_head *sockets, in add_vsock_stat() argument
248 list_add_tail(&st->list, sockets); in add_vsock_stat()
254 static void read_vsock_stat(struct list_head *sockets) in read_vsock_stat() argument
309 add_vsock_stat(sockets, NLMSG_DATA(h)); in read_vsock_stat()
319 static void free_sock_stat(struct list_head *sockets) in free_sock_stat() argument
324 list_for_each_entry_safe(st, next, sockets, list) in free_sock_stat()
330 LIST_HEAD(sockets); in test_no_sockets()
332 read_vsock_stat(&sockets); in test_no_sockets()
334 check_no_sockets(&sockets); in test_no_sockets()
349 LIST_HEAD(sockets); in test_listen_socket_server()
365 read_vsock_stat(&sockets); in test_listen_socket_server()
367 check_num_sockets(&sockets, 1); in test_listen_socket_server()
368 st = find_vsock_stat(&sockets, fd); in test_listen_socket_server()
372 free_sock_stat(&sockets); in test_listen_socket_server()
378 LIST_HEAD(sockets); in test_connect_client()
387 read_vsock_stat(&sockets); in test_connect_client()
389 check_num_sockets(&sockets, 1); in test_connect_client()
390 st = find_vsock_stat(&sockets, fd); in test_connect_client()
397 free_sock_stat(&sockets); in test_connect_client()
403 LIST_HEAD(sockets); in test_connect_server()
412 read_vsock_stat(&sockets); in test_connect_server()
414 check_num_sockets(&sockets, 1); in test_connect_server()
415 st = find_vsock_stat(&sockets, client_fd); in test_connect_server()
422 free_sock_stat(&sockets); in test_connect_server()