/Linux-v6.6/tools/usb/usbip/src/ |
D | usbip_network.c | 95 static ssize_t usbip_net_xmit(int sockfd, void *buff, size_t bufflen, in usbip_net_xmit() argument 106 nbytes = send(sockfd, buff, bufflen, 0); in usbip_net_xmit() 108 nbytes = recv(sockfd, buff, bufflen, MSG_WAITALL); in usbip_net_xmit() 122 ssize_t usbip_net_recv(int sockfd, void *buff, size_t bufflen) in usbip_net_recv() argument 124 return usbip_net_xmit(sockfd, buff, bufflen, 0); in usbip_net_recv() 127 ssize_t usbip_net_send(int sockfd, void *buff, size_t bufflen) in usbip_net_send() argument 129 return usbip_net_xmit(sockfd, buff, bufflen, 1); in usbip_net_send() 140 int usbip_net_send_op_common(int sockfd, uint32_t code, uint32_t status) in usbip_net_send_op_common() argument 153 rc = usbip_net_send(sockfd, &op_common, sizeof(op_common)); in usbip_net_send_op_common() 162 int usbip_net_recv_op_common(int sockfd, uint16_t *code, int *status) in usbip_net_recv_op_common() argument [all …]
|
D | usbip_attach.c | 81 static int import_device(int sockfd, struct usbip_usb_device *udev) in import_device() argument 102 rc = usbip_vhci_attach_device(port, sockfd, udev->busnum, in import_device() 120 static int query_import_device(int sockfd, char *busid) in query_import_device() argument 132 rc = usbip_net_send_op_common(sockfd, OP_REQ_IMPORT, 0); in query_import_device() 142 rc = usbip_net_send(sockfd, (void *) &request, sizeof(request)); in query_import_device() 149 rc = usbip_net_recv_op_common(sockfd, &code, &status); in query_import_device() 156 rc = usbip_net_recv(sockfd, (void *) &reply, sizeof(reply)); in query_import_device() 171 return import_device(sockfd, &reply.udev); in query_import_device() 176 int sockfd; in attach_device() local 180 sockfd = usbip_net_tcp_connect(host, usbip_port_string); in attach_device() [all …]
|
D | usbip_network.h | 168 ssize_t usbip_net_recv(int sockfd, void *buff, size_t bufflen); 169 ssize_t usbip_net_send(int sockfd, void *buff, size_t bufflen); 170 int usbip_net_send_op_common(int sockfd, uint32_t code, uint32_t status); 171 int usbip_net_recv_op_common(int sockfd, uint16_t *code, int *status); 172 int usbip_net_set_reuseaddr(int sockfd); 173 int usbip_net_set_nodelay(int sockfd); 174 int usbip_net_set_keepalive(int sockfd); 175 int usbip_net_set_v6only(int sockfd);
|
D | usbip_list.c | 44 static int get_exported_devices(char *host, int sockfd) in get_exported_devices() argument 56 rc = usbip_net_send_op_common(sockfd, OP_REQ_DEVLIST, 0); in get_exported_devices() 62 rc = usbip_net_recv_op_common(sockfd, &code, &status); in get_exported_devices() 70 rc = usbip_net_recv(sockfd, &reply, sizeof(reply)); in get_exported_devices() 89 rc = usbip_net_recv(sockfd, &udev, sizeof(udev)); in get_exported_devices() 106 rc = usbip_net_recv(sockfd, &uintf, sizeof(uintf)); in get_exported_devices() 131 int sockfd; in list_exported_devices() local 133 sockfd = usbip_net_tcp_connect(host, usbip_port_string); in list_exported_devices() 134 if (sockfd < 0) { in list_exported_devices() 136 usbip_port_string, gai_strerror(sockfd)); in list_exported_devices() [all …]
|
D | usbipd.c | 91 static int recv_request_import(int sockfd) in recv_request_import() argument 103 rc = usbip_net_recv(sockfd, &req, sizeof(req)); in recv_request_import() 121 usbip_net_set_nodelay(sockfd); in recv_request_import() 124 status = usbip_export_device(edev, sockfd); in recv_request_import() 132 rc = usbip_net_send_op_common(sockfd, OP_REP_IMPORT, status); in recv_request_import() 146 rc = usbip_net_send(sockfd, &pdu_udev, sizeof(pdu_udev)); in recv_request_import()
|
/Linux-v6.6/tools/testing/selftests/bpf/ |
D | xdp_features.c | 226 int sockfd = *(int *)arg; in dut_echo_thread() local 234 n = recvfrom(sockfd, buf, sizeof(buf), MSG_WAITALL, in dut_echo_thread() 242 sendto(sockfd, buf, sizeof(buf), MSG_NOSIGNAL | MSG_CONFIRM, in dut_echo_thread() 247 close(sockfd); in dut_echo_thread() 252 static int dut_run_echo_thread(pthread_t *t, int *sockfd) in dut_run_echo_thread() argument 256 sockfd = start_reuseport_server(AF_INET6, SOCK_DGRAM, NULL, in dut_run_echo_thread() 258 if (!sockfd) { in dut_run_echo_thread() 266 err = pthread_create(t, NULL, dut_echo_thread, sockfd); in dut_run_echo_thread() 271 free_fds(sockfd, 1); in dut_run_echo_thread() 339 static int recv_msg(int sockfd, void *buf, size_t bufsize, void *val, in recv_msg() argument [all …]
|
D | test_sock.c | 419 int sockfd = -1; in bind_sock() local 423 sockfd = socket(domain, type, 0); in bind_sock() 424 if (sockfd < 0) in bind_sock() 447 if (bind(sockfd, (const struct sockaddr *)&addr, len) == -1) { in bind_sock() 465 if (bind(sockfd, (const struct sockaddr *)&addr, len) == -1) { in bind_sock() 476 close(sockfd); in bind_sock()
|
D | test_sock_addr.c | 1112 static int recvmsg_from_client(int sockfd, struct sockaddr_storage *src_addr) in recvmsg_from_client() argument 1121 FD_SET(sockfd, &rfds); in recvmsg_from_client() 1126 if (select(sockfd + 1, &rfds, NULL, NULL, &tv) <= 0 || in recvmsg_from_client() 1127 !FD_ISSET(sockfd, &rfds)) in recvmsg_from_client() 1140 return recvmsg(sockfd, &hdr, 0); in recvmsg_from_client()
|
/Linux-v6.6/tools/testing/selftests/bpf/prog_tests/ |
D | skc_to_unix_sock.c | 14 int err, sockfd = 0; in test_skc_to_unix_sock() local 31 sockfd = socket(AF_UNIX, SOCK_STREAM, 0); in test_skc_to_unix_sock() 32 if (!ASSERT_GT(sockfd, 0, "socket failed")) in test_skc_to_unix_sock() 40 err = bind(sockfd, (struct sockaddr *)&sockaddr, sizeof(sockaddr)); in test_skc_to_unix_sock() 44 err = listen(sockfd, 1); in test_skc_to_unix_sock() 51 if (sockfd) in test_skc_to_unix_sock() 52 close(sockfd); in test_skc_to_unix_sock()
|
D | decap_sanity.c | 26 int sockfd, err; in test_decap_sanity() local 58 sockfd = socket(AF_INET6, SOCK_DGRAM, 0); in test_decap_sanity() 59 if (!ASSERT_NEQ(sockfd, -1, "socket")) in test_decap_sanity() 61 err = sendto(sockfd, buf, sizeof(buf), 0, (void *)&addr, addrlen); in test_decap_sanity() 62 close(sockfd); in test_decap_sanity()
|
D | d_path.c | 43 int sockfd = -1, procfd = -1, devfd = -1; in trigger_fstat_events() local 53 sockfd = socket(AF_INET, SOCK_STREAM, 0); in trigger_fstat_events() 54 if (CHECK(sockfd < 0, "trigger", "socket failed\n")) in trigger_fstat_events() 78 ret = set_pathname(sockfd, pid); in trigger_fstat_events() 97 fstat(sockfd, &fileStat); in trigger_fstat_events() 111 close(sockfd); in trigger_fstat_events()
|
D | sockmap_listen.c | 473 int sockfd; member 491 s = ctx->sockfd; in connect_accept_thread() 555 ctx.sockfd = s; in test_syn_recv_insert_delete() 584 s = ctx->sockfd; in listen_thread() 617 ctx.sockfd = s; in test_race_insert_listen()
|
/Linux-v6.6/tools/net/ynl/generated/ |
D | handshake-user.h | 61 __u32 sockfd:1; member 68 __u32 sockfd; member 103 __u32 sockfd:1; member 107 __u32 sockfd; member 125 handshake_done_req_set_sockfd(struct handshake_done_req *req, __u32 sockfd) in handshake_done_req_set_sockfd() argument 127 req->_present.sockfd = 1; in handshake_done_req_set_sockfd() 128 req->sockfd = sockfd; in handshake_done_req_set_sockfd()
|
D | handshake-user.c | 180 dst->_present.sockfd = 1; in handshake_accept_rsp_parse() 181 dst->sockfd = mnl_attr_get_u32(attr); in handshake_accept_rsp_parse() 306 if (req->_present.sockfd) in handshake_done() 307 mnl_attr_put_u32(nlh, HANDSHAKE_A_DONE_SOCKFD, req->sockfd); in handshake_done()
|
/Linux-v6.6/drivers/usb/usbip/ |
D | stub_dev.c | 46 int sockfd = 0; in usbip_sockfd_store() local 57 rv = sscanf(buf, "%d", &sockfd); in usbip_sockfd_store() 61 if (sockfd != -1) { in usbip_sockfd_store() 74 socket = sockfd_lookup(sockfd, &err); in usbip_sockfd_store() 107 sdev->ud.sockfd = sockfd; in usbip_sockfd_store() 164 dev_dbg(&sdev->udev->dev, "shutdown sockfd %d\n", ud->sockfd); in stub_shutdown_connection() 187 ud->sockfd = -1; in stub_shutdown_connection() 283 sdev->ud.sockfd = -1; in stub_device_alloc()
|
D | vhci_sysfs.c | 51 vdev->ud.sockfd, in port_show_vhci() 312 int sockfd = 0; in attach_store() local 329 if (sscanf(buf, "%u %u %u %u", &port, &sockfd, &devid, &speed) != 4) in attach_store() 337 sockfd, devid, speed); in attach_store() 360 socket = sockfd_lookup(sockfd, &err); in attach_store() 416 pdev_nr, rhport, sockfd); in attach_store() 422 vdev->ud.sockfd = sockfd; in attach_store()
|
D | vudc_sysfs.c | 99 int sockfd = 0; in usbip_sockfd_store() local 107 rv = kstrtoint(in, 0, &sockfd); in usbip_sockfd_store() 124 if (sockfd != -1) { in usbip_sockfd_store() 138 socket = sockfd_lookup(sockfd, &err); in usbip_sockfd_store()
|
D | usbip_common.h | 270 int sockfd; member
|
D | vhci_hcd.c | 1017 pr_debug("shutdown tcp_socket %d\n", ud->sockfd); in vhci_shutdown_connection() 1036 vdev->ud.sockfd = -1; in vhci_shutdown_connection() 1083 ud->sockfd = -1; in vhci_device_reset()
|
/Linux-v6.6/tools/usb/usbip/libsrc/ |
D | vhci_driver.c | 53 int sockfd; in parse_status() local 60 &devid, &sockfd, lbusid); in parse_status() 69 dbg("sockfd %u lbusid %s", sockfd, lbusid); in parse_status() 357 int usbip_vhci_attach_device2(uint8_t port, int sockfd, uint32_t devid, in usbip_vhci_attach_device2() argument 366 port, sockfd, devid, speed); in usbip_vhci_attach_device2() 391 int usbip_vhci_attach_device(uint8_t port, int sockfd, uint8_t busnum, in usbip_vhci_attach_device() argument 396 return usbip_vhci_attach_device2(port, sockfd, devid, speed); in usbip_vhci_attach_device()
|
D | vhci_driver.h | 56 int usbip_vhci_attach_device2(uint8_t port, int sockfd, uint32_t devid, 60 int usbip_vhci_attach_device(uint8_t port, int sockfd, uint8_t busnum,
|
D | usbip_host_common.c | 212 int usbip_export_device(struct usbip_exported_device *edev, int sockfd) in usbip_export_device() argument 247 size = snprintf(sockfd_buff, sizeof(sockfd_buff), "%d\n", sockfd); in usbip_export_device()
|
D | usbip_host_common.h | 88 int usbip_export_device(struct usbip_exported_device *edev, int sockfd);
|
/Linux-v6.6/tools/testing/selftests/net/ |
D | io_uring_zerocopy_tx.c | 271 static inline void io_uring_prep_send(struct io_uring_sqe *sqe, int sockfd, in io_uring_prep_send() argument 276 sqe->fd = sockfd; in io_uring_prep_send() 282 static inline void io_uring_prep_sendzc(struct io_uring_sqe *sqe, int sockfd, in io_uring_prep_sendzc() argument 286 io_uring_prep_send(sqe, sockfd, buf, len, flags); in io_uring_prep_sendzc()
|
/Linux-v6.6/Documentation/networking/ |
D | udplite.rst | 148 setsockopt(sockfd, SOL_SOCKET, SO_NO_CHECK, ... ); 152 getsockopt(sockfd, SOL_SOCKET, SO_NO_CHECK, &value, ...);
|