/system/connectivity/dhcp_client/ |
D | dhcpv4.cc | 168 htons(ETHERTYPE_IP)); in CreateRawSocket() 199 local.sll_protocol = htons(ETHERTYPE_IP); in CreateRawSocket() 243 udp->uh_sport = htons(kDHCPClientPort); in MakeRawPacket() 244 udp->uh_dport = htons(kDHCPServerPort); in MakeRawPacket() 246 htons(static_cast<uint16_t>(sizeof(*udp) + payload.GetLength())); in MakeRawPacket() 259 udp->uh_sum = htons(DHCPMessage::ComputeChecksum( in MakeRawPacket() 278 ip->tot_len = htons(static_cast<uint16_t>(header_len+ payload.GetLength())); in MakeRawPacket() 280 ip->check = htons(DHCPMessage::ComputeChecksum( in MakeRawPacket() 292 remote.sll_protocol = htons(ETHERTYPE_IP); in SendRawPacket() 294 remote.sll_hatype = htons(ARPHRD_ETHER); in SendRawPacket() [all …]
|
D | dhcp_options_writer.cc | 59 uint16_t value_net = htons(value); in WriteUInt16Option() 115 uint16_t element_net = htons(element); in WriteUInt16ListOption()
|
D | dhcp_message.cc | 281 raw_message.secs = htons(seconds_); in Serialize() 282 raw_message.flags = htons(flags_); in Serialize()
|
/system/core/libnetutils/ |
D | packet.c | 48 if((s = socket(PF_PACKET, SOCK_DGRAM, htons(ETH_P_IP))) < 0) { in open_raw_socket() 54 bindaddr.sll_protocol = htons(ETH_P_IP); in open_raw_socket() 104 ip.tot_len = htons(sizeof(ip) + sizeof(udp) + size); in send_packet() 114 udp.source = htons(sport); in send_packet() 115 udp.dest = htons(dport); in send_packet() 116 udp.len = htons(sizeof(udp) + size); in send_packet() 122 temp = htons(IPPROTO_UDP); in send_packet() 142 destaddr.sll_protocol = htons(ETH_P_IP); in send_packet() 197 } else if (packet.udp.dest != htons(PORT_BOOTP_CLIENT)) { in receive_packet()
|
D | dhcpmsg.c | 35 msg->flags = htons(FLAGS_BROADCAST); in init_dhcp_msg()
|
/system/netd/server/ |
D | SockDiagTest.cpp | 35 sockaddr_in6 sin6 = { .sin6_family = AF_INET6, .sin6_port = htons(port) }; in bindAndListen() 76 sockaddr_in server4 = { .sin_family = AF_INET, .sin_port = htons(port) }; in TEST_F() 77 sockaddr_in6 server6 = { .sin6_family = AF_INET6, .sin6_port = htons(port) }; in TEST_F() 110 src, htons(msg->id.idiag_sport), in TEST_F() 111 dst, htons(msg->id.idiag_dport), in TEST_F() 131 seenServer46 |= (msg->id.idiag_sport == htons(port)); in TEST_F() 132 seenServer6 |= (msg->id.idiag_sport == htons(port)); in TEST_F() 136 src, htons(msg->id.idiag_sport), in TEST_F() 137 dst, htons(msg->id.idiag_dport), in TEST_F() 301 sockaddr_in6 server = { .sin6_family = AF_INET6, .sin6_port = htons(port) }; in TEST_P()
|
/system/connectivity/shill/ |
D | arp_client.cc | 69 int socket = sockets_->Socket(PF_PACKET, SOCK_DGRAM, htons(ETHERTYPE_ARP)); in CreateSocket() 104 socket_address.sll_protocol = htons(ETHERTYPE_ARP); in CreateSocket() 160 socket_address.sll_protocol = htons(ETHERTYPE_ARP); in TransmitRequest()
|
D | arp_packet.cc | 164 header.ar_hrd = htons(ARPHRD_ETHER); in FormatRequest() 165 header.ar_pro = htons(protocol); in FormatRequest() 168 header.ar_op = htons(ARPOP_REQUEST); in FormatRequest()
|
D | eap_listener.cc | 69 int socket = sockets_->Socket(PF_PACKET, SOCK_DGRAM, htons(ETH_P_PAE)); in CreateSocket() 85 socket_address.sll_protocol = htons(ETH_P_PAE); in CreateSocket()
|
D | async_connection.cc | 138 iaddr.sin_port = htons(port); in ConnectTo() 149 iaddr6.sin6_port = htons(port); in ConnectTo()
|
D | eap_listener_unittest.cc | 118 socket_address->sll_protocol == htons(ETH_P_PAE) && 123 EXPECT_CALL(*sockets_, Socket(PF_PACKET, SOCK_DGRAM, htons(ETH_P_PAE))) in StartListenerWithFD() 146 EXPECT_CALL(*sockets_, Socket(PF_PACKET, SOCK_DGRAM, htons(ETH_P_PAE))) in TEST_F()
|
D | arp_client_unittest.cc | 106 socket_address->sll_protocol == htons(ETHERTYPE_ARP) && 139 EXPECT_CALL(*sockets_, Socket(PF_PACKET, SOCK_DGRAM, htons(ETHERTYPE_ARP))) in StartClientWithFD() 161 EXPECT_CALL(*sockets_, Socket(PF_PACKET, SOCK_DGRAM, htons(ETHERTYPE_ARP))) in TEST_F()
|
D | async_connection_unittest.cc | 210 return address.Equals(arg_addr) && arg_saddr->sin_port == htons(port); 220 return ipv6_address.Equals(arg_addr) && arg_saddr->sin6_port == htons(port);
|
/system/netd/tests/ |
D | dns_responder.cpp | 260 *reinterpret_cast<uint16_t*>(buffer_cur) = htons(qtype); in write() 262 htons(qclass); in write() 356 intfields.rtype = htons(rtype); in writeIntFields() 357 intfields.rclass = htons(rclass); in writeIntFields() 359 intfields.rdlen = htons(rdlen); in writeIntFields() 457 header.id = htons(id); in write() 463 header.qdcount = htons(questions.size()); in write() 464 header.ancount = htons(answers.size()); in write() 465 header.nscount = htons(authorities.size()); in write() 466 header.arcount = htons(additionals.size()); in write()
|
/system/core/libcutils/ |
D | socket_loopback_client_unix.c | 43 addr.sin_port = htons(port); in socket_loopback_client()
|
D | socket_inaddr_any_server_unix.c | 40 addr.sin6_port = htons(port); in socket_inaddr_any_server()
|
D | socket_loopback_server_unix.c | 42 addr.sin_port = htons(port); in socket_loopback_server()
|
D | socket_inaddr_any_server_windows.c | 65 addr.sin6_port = htons(port); in socket_inaddr_any_server()
|
/system/bt/btif/src/ |
D | btif_util.c | 130 uuid1 = htons(uuid1); in string_to_uuid() 131 uuid2 = htons(uuid2); in string_to_uuid() 132 uuid3 = htons(uuid3); in string_to_uuid() 134 uuid5 = htons(uuid5); in string_to_uuid()
|
/system/core/adb/ |
D | test_track_devices.cpp | 34 server.sin_port = htons(5037); in main()
|
/system/bt/hci/src/ |
D | btsnoop_net.c | 110 addr.sin_port = htons(LISTEN_PORT_); in listen_fn_()
|
/system/bt/vendor_libs/test_vendor_lib/src/ |
D | test_channel_transport.cc | 52 listen_address.sin_port = htons(port_); in SetUp()
|
/system/bt/tools/hci/ |
D | main.c | 178 addr.sin_port = htons(8873); in write_hci_command()
|
/system/core/libutils/ |
D | Unicode.cpp | 25 # undef htons 30 # define htons(x) ntohs(x) macro
|
/system/bt/osi/src/ |
D | socket.c | 99 addr.sin_port = htons(port); in socket_listen()
|