Home
last modified time | relevance | path

Searched refs:sin_port (Results 1 – 25 of 109) sorted by relevance

12345

/Zephyr-Core-3.7.0/samples/net/mdns_responder/src/
Dservice.c56 &((struct sockaddr_in *)&server_addr)->sin_port); in service()
71 net_sin(&server_addr)->sin_port = sys_cpu_to_be16(DEFAULT_PORT); in service()
97 portp = &net_sin(&server_addr)->sin_port; in service()
/Zephyr-Core-3.7.0/tests/net/socket/
Dsocket_helpers.h70 sockaddr->sin_port = htons(port); in prepare_sock_udp_v4()
107 sockaddr->sin_port = htons(port); in prepare_sock_tcp_v4()
144 sockaddr->sin_port = htons(port); in prepare_sock_tls_v4()
182 sockaddr->sin_port = htons(port); in prepare_sock_dtls_v4()
/Zephyr-Core-3.7.0/subsys/net/lib/dns/
Ddispatcher.c190 if (net_sin(&entry->local_addr)->sin_port == in dns_dispatcher_register()
191 net_sin(&ctx->local_addr)->sin_port) { in dns_dispatcher_register()
205 if (net_sin(&entry->local_addr)->sin_port == in dns_dispatcher_register()
206 net_sin(&ctx->local_addr)->sin_port) { in dns_dispatcher_register()
/Zephyr-Core-3.7.0/subsys/net/lib/shell/
Dtcp.c57 net_sin(myaddr)->sin_port = 0U; /* let the IP stack to select */ in get_my_ipv4_addr()
71 ntohs(net_sin(myaddr)->sin_port)); in print_connect_info()
74 ntohs(net_sin(addr)->sin_port)); in print_connect_info()
142 net_sin(&addr)->sin_port = htons(port); in tcp_connect()
157 net_sin(&addr)->sin_port = htons(port); in tcp_connect()
Dnet_shell.c103 ntohs(net_sin_ptr(&context->local)->sin_port)); in get_addresses()
117 ntohs(net_sin(&context->remote)->sin_port)); in get_addresses()
Dconn.c85 ntohs(net_sin(&conn->local_addr)->sin_port)); in conn_handler_cb()
89 ntohs(net_sin(&conn->remote_addr)->sin_port)); in conn_handler_cb()
Dudp.c114 net_sin(&addr)->sin_port = htons(port); in cmd_net_udp_bind()
241 net_sin(&addr)->sin_port = htons(port); in cmd_net_udp_send()
/Zephyr-Core-3.7.0/subsys/net/lib/sockets/
Dgetnameinfo.c28 snprintk(serv, servlen, "%hu", ntohs(a->sin_port)); in zsock_getnameinfo()
Dgetaddrinfo.c86 net_sin(&ai->_ai_addr)->sin_port = state->port; in dns_resolve_cb()
193 addr->sin_port = htons(port); in getaddrinfo_null_host()
291 net_sin(ai_addr)->sin_port = htons(port); in z_impl_z_zsock_getaddrinfo_internal()
408 addr->sin_port = htons(port); in try_resolve_literal_addr()
/Zephyr-Core-3.7.0/tests/net/utils/src/
Dmain.c440 .sin_port = htons(80), in ZTEST()
455 .sin_port = 0, in ZTEST()
470 .sin_port = 0, in ZTEST()
485 .sin_port = 0, in ZTEST()
500 .sin_port = htons(65535), in ZTEST()
525 .sin_port = 0, in ZTEST()
555 .sin_port = 0, in ZTEST()
811 zassert_true(net_sin(&addr)->sin_port == in ZTEST()
812 parse_ipv4_entries[i].result.sin_port, in ZTEST()
/Zephyr-Core-3.7.0/subsys/net/lib/zperf/
Dzperf_session.c44 ptr->port == addr4->sin_port && in get_session()
75 active->port = addr4->sin_port; in get_session()
/Zephyr-Core-3.7.0/drivers/wifi/esp_at/
Desp_offload.c62 ntohs(net_sin(&dst)->sin_port)); in _sock_connect()
64 if (src.sa_family == AF_INET && net_sin(&src)->sin_port != 0) { in _sock_connect()
71 ntohs(net_sin(&dst)->sin_port), ntohs(net_sin(&src)->sin_port), in _sock_connect()
77 ntohs(net_sin(&dst)->sin_port)); in _sock_connect()
270 ntohs(net_sin(&dst)->sin_port)); in _sock_send()
547 recv_addr->sin_port = htons(port); in MODEM_CMD_DIRECT_DEFINE()
643 net_sin(&sock->src)->sin_port != 0) { in esp_recv()
/Zephyr-Core-3.7.0/tests/net/socket/tls_ext/src/
Dmain.c177 addrstr, ntohs(sa.sin_port), client_fd); in server_thread_fn()
277 sa.sin_port = htons(PORT); in test_common()
291 addrstr, ntohs(sa.sin_port), server_fd); in test_common()
365 addrstr, ntohs(sa.sin_port), client_fd); in test_common()
/Zephyr-Core-3.7.0/samples/net/sockets/tcp/src/
Dmain.c57 sin.sin_port = htons(UDP_PORT); in udp()
/Zephyr-Core-3.7.0/subsys/net/ip/
Dnet_context.c184 contexts[i].local)->sin_port == local_port)) { in check_used_port()
516 addr->sin_port = in net_context_get()
519 if (!addr->sin_port) { in net_context_get()
670 addr4.sin_port = in bind_default()
906 if (addr4->sin_port) { in net_context_bind()
909 addr4->sin_port, in net_context_bind()
915 ntohs(addr4->sin_port)); in net_context_bind()
921 net_sin_ptr(&context->local)->sin_port = in net_context_bind()
922 addr4->sin_port; in net_context_bind()
925 addr4->sin_port = in net_context_bind()
[all …]
Dconnection.c211 if (net_sin(&conn->local_addr)->sin_port != in conn_find_handler()
251 if (net_sin(&conn->remote_addr)->sin_port != in conn_find_handler()
320 net_sin(&conn->remote_addr)->sin_port = htons(remote_port); in net_conn_change_remote()
404 net_sin(&conn->local_addr)->sin_port = htons(local_port); in net_conn_register()
801 if (net_sin(&conn->remote_addr)->sin_port && in net_conn_input()
802 net_sin(&conn->remote_addr)->sin_port != src_port) { in net_conn_input()
806 if (net_sin(&conn->local_addr)->sin_port && in net_conn_input()
807 net_sin(&conn->local_addr)->sin_port != dst_port) { in net_conn_input()
/Zephyr-Core-3.7.0/tests/posix/headers/src/
Dnetinet_in_h.c30 zassert_not_equal(-1, offsetof(struct sockaddr_in, sin_port)); in ZTEST()
/Zephyr-Core-3.7.0/subsys/net/lib/capture/
Dcapture.c412 if (net_sin(&ctx->peer)->sin_port == 0) { in net_capture_setup()
413 net_sin(&ctx->peer)->sin_port = htons(DEFAULT_PORT); in net_capture_setup()
416 if (net_sin(&ctx->local)->sin_port == 0) { in net_capture_setup()
417 net_sin(&ctx->local)->sin_port = htons(DEFAULT_PORT); in net_capture_setup()
662 (void)net_udp_create(ip, net_sin(&ctx->local)->sin_port, in capture_send()
663 net_sin(&ctx->peer)->sin_port); in capture_send()
/Zephyr-Core-3.7.0/samples/net/sockets/sntp_client/src/
Dmain.c31 addr.sin_port = htons(SNTP_PORT); in main()
/Zephyr-Core-3.7.0/tests/net/socket/misc/src/
Dmain.c302 .sin_port = htons(DST_PORT), in test_ipv4_so_bindtodevice()
307 .sin_port = htons(DST_PORT), in test_ipv4_so_bindtodevice()
312 .sin_port = htons(DST_PORT), in test_ipv4_so_bindtodevice()
373 net_sin(&srv_addr)->sin_port = htons(DST_PORT); in test_getpeername()
462 net_sin(&srv_addr)->sin_port = htons(DST_PORT); in test_getsockname_tcp()
531 net_sin(&srv_addr)->sin_port = htons(DST_PORT); in test_getsockname_udp()
598 net_sin(&srv_addr4)->sin_port = htons(MAPPING_PORT); in test_ipv4_mapped_to_ipv6_disabled()
647 net_sin(&srv_addr4)->sin_port = htons(MAPPING_PORT); in test_ipv4_mapped_to_ipv6_enabled()
731 net_sin(&srv_addr)->sin_port = htons(MAPPING_PORT); in test_ipv4_mapped_to_ipv6_server()
/Zephyr-Core-3.7.0/drivers/modem/
Dmodem_context.c69 *port = ntohs(net_sin(addr)->sin_port); in modem_context_get_addr_port()
/Zephyr-Core-3.7.0/tests/net/socket/getnameinfo/src/
Dmain.c33 saddr.sin_port = htons(1234); in ZTEST_USER()
/Zephyr-Core-3.7.0/samples/net/sockets/http_get/src/
Dhttp_get.c55 ((struct sockaddr_in *)ai->ai_addr)->sin_port); in dump_addrinfo()
/Zephyr-Core-3.7.0/samples/net/sockets/dumb_http_server/src/
Dsocket_dumb_http.c70 bind_addr.sin_port = htons(BIND_PORT); in main()
/Zephyr-Core-3.7.0/samples/net/sockets/echo_client/src/
Dtcp.c116 proxy4->sin_port = htons(SOCKS5_PROXY_PORT); in start_tcp_proto()
255 addr4.sin_port = htons(PEER_PORT); in start_tcp()

12345