Home
last modified time | relevance | path

Searched refs:PP_HTONS (Results 1 – 18 of 18) sorted by relevance

/third_party/lwip/src/apps/netbiosns/
Dnetbiosns.c373 if (netbios_question_hdr->type == PP_HTONS(NETB_QTYPE_NB)) { in netbiosns_recv()
385 resp->resp_hdr.flags = PP_HTONS(NETB_HFLAG_RESPONSE | in netbiosns_recv()
390 resp->resp_hdr.answerRRs = PP_HTONS(1); in netbiosns_recv()
400 …resp->resp_name.datalen = PP_HTONS(sizeof(resp->resp_name.flags) + sizeof(resp->resp_name.add… in netbiosns_recv()
401 resp->resp_name.flags = PP_HTONS(NETB_NFLAG_NODETYPE_BNODE); in netbiosns_recv()
412 } else if (netbios_question_hdr->type == PP_HTONS(NETB_QTYPE_NBSTAT)) { in netbiosns_recv()
431 …resp->answer_hdr.flags = PP_HTONS(NETB_HFLAG_RESPONSE | NETB_HFLAG_OPCODE_NAME_QUERY | N… in netbiosns_recv()
434 resp->answer_hdr.answerRRs = PP_HTONS(1); in netbiosns_recv()
442 resp->packet_type = PP_HTONS(0x21); in netbiosns_recv()
444 resp->cls = PP_HTONS(1); in netbiosns_recv()
[all …]
/third_party/lwip/src/apps/tftp/
Dtftp_server.c130 payload[0] = PP_HTONS(TFTP_ERROR); in send_error()
150 payload[0] = PP_HTONS(TFTP_ACK); in send_ack()
189 payload[0] = PP_HTONS(TFTP_DATA); in send_data()
225 case PP_HTONS(TFTP_RRQ): /* fall through */ in recv()
226 case PP_HTONS(TFTP_WRQ): { in recv()
256 tftp_state.handle = tftp_state.ctx->open(filename, mode, opcode == PP_HTONS(TFTP_WRQ)); in recv()
264 …LWIP_DEBUGF(TFTP_DEBUG | LWIP_DBG_STATE, ("tftp: %s request from ", (opcode == PP_HTONS(TFTP_WRQ))… in recv()
271 if (opcode == PP_HTONS(TFTP_WRQ)) { in recv()
282 case PP_HTONS(TFTP_DATA): { in recv()
322 case PP_HTONS(TFTP_ACK): { in recv()
/third_party/lwip/src/netif/
Dethernet.c115 if (type == PP_HTONS(ETHTYPE_VLAN)) {
173 case PP_HTONS(ETHTYPE_IP):
190 case PP_HTONS(ETHTYPE_ARP):
210 case PP_HTONS(ETHTYPE_PPPOEDISC): /* PPP Over Ethernet Discovery Stage */
214 case PP_HTONS(ETHTYPE_PPPOE): /* PPP Over Ethernet Session Stage */
220 case PP_HTONS(ETHTYPE_IPV6): /* IPv6 */
290 eth_type_be = PP_HTONS(ETHTYPE_VLAN);
/third_party/lwip/src/include/lwip/
Ddef.h90 #define PP_HTONS(x) ((u16_t)(x)) macro
108 #define PP_HTONS(x) ((u16_t)((((x) & (u16_t)0x00ffU) << 8) | (((x) & (u16_t)0xff00U) >> 8)))
109 #define PP_NTOHS(x) PP_HTONS(x)
/third_party/lwip/src/core/
Ddns.c830 hdr.numquestions = PP_HTONS(1); in dns_send()
886 qry.type = PP_HTONS(DNS_RRTYPE_AAAA); in dns_send()
888 qry.type = PP_HTONS(DNS_RRTYPE_A); in dns_send()
890 qry.cls = PP_HTONS(DNS_RRCLASS_IN); in dns_send()
1350 if ((qry.cls != PP_HTONS(DNS_RRCLASS_IN)) || in dns_recv()
1351 … (LWIP_DNS_ADDRTYPE_IS_IPV6(entry->reqaddrtype) && (qry.type != PP_HTONS(DNS_RRTYPE_AAAA))) || in dns_recv()
1352 … (!LWIP_DNS_ADDRTYPE_IS_IPV6(entry->reqaddrtype) && (qry.type != PP_HTONS(DNS_RRTYPE_A)))) { in dns_recv()
1396 if (ans.cls == PP_HTONS(DNS_RRCLASS_IN)) { in dns_recv()
1398 … if ((ans.type == PP_HTONS(DNS_RRTYPE_A)) && (ans.len == PP_HTONS(sizeof(ip4_addr_t)))) { in dns_recv()
1417 … if ((ans.type == PP_HTONS(DNS_RRTYPE_AAAA)) && (ans.len == PP_HTONS(sizeof(ip6_addr_p_t)))) { in dns_recv()
Ddef.c78 return PP_HTONS(n); in lwip_htons()
Dtcp_out.c2007 wnd = PP_HTONS(((TCP_WND >> TCP_RCV_SCALE) & 0xFFFF)); in tcp_rst()
2009 wnd = PP_HTONS(TCP_WND); in tcp_rst()
/third_party/lwip/src/core/ipv4/
Dicmp.c219 if (iecho->chksum > PP_HTONS(0xffffU - (ICMP_ECHO << 8))) { in icmp_input()
220 iecho->chksum = (u16_t)(iecho->chksum + PP_HTONS((u16_t)(ICMP_ECHO << 8)) + 1); in icmp_input()
222 iecho->chksum = (u16_t)(iecho->chksum + PP_HTONS(ICMP_ECHO << 8)); in icmp_input()
Detharp.c687 if ((hdr->hwtype != PP_HTONS(LWIP_IANA_HWTYPE_ETHERNET)) ||
690 (hdr->proto != PP_HTONS(ETHTYPE_IP))) {
732 case PP_HTONS(ARP_REQUEST):
756 case PP_HTONS(ARP_REPLY):
1180 hdr->hwtype = PP_HTONS(LWIP_IANA_HWTYPE_ETHERNET);
1181 hdr->proto = PP_HTONS(ETHTYPE_IP);
Dip4.c366 if (IPH_CHKSUM(iphdr) >= PP_HTONS(0xffffU - 0x100)) {
367 IPH_CHKSUM_SET(iphdr, (u16_t)(IPH_CHKSUM(iphdr) + PP_HTONS(0x100) + 1));
369 IPH_CHKSUM_SET(iphdr, (u16_t)(IPH_CHKSUM(iphdr) + PP_HTONS(0x100)));
678 if ((IPH_OFFSET(iphdr) & PP_HTONS(IP_OFFMASK | IP_MF)) != 0) {
681 …, p->tot_len, lwip_ntohs(IPH_LEN(iphdr)), (u16_t)!!(IPH_OFFSET(iphdr) & PP_HTONS(IP_MF)), (u16_t)(…
Digmp.c782 ra[0] = PP_HTONS(ROUTER_ALERT);
/third_party/lwip/
Dbackport-fix-compiling-ETHARP_SUPPORT_VLAN.patch26 eth_type_be = PP_HTONS(ETHTYPE_VLAN);
/third_party/lwip/src/include/lwip/prot/
Dtcp.h90 …hdr, flags) (phdr)->_hdrlen_rsvd_flags = (((phdr)->_hdrlen_rsvd_flags & PP_HTONS(~TCP_FLAGS)) | lw…
/third_party/lwip/src/netif/ppp/
Dvj.c187 if ((IPH_OFFSET(ip) & PP_HTONS(0x3fff)) || np->tot_len < 40) { in vj_compress_tcp()
Dpppoe.c1051 ethhdr->type = PP_HTONS(ETHTYPE_PPPOEDISC); in pppoe_send_padt()
/third_party/lwip/test/unit/api/
Dtest_sockets.c706 sa_listen.sin_port = PP_HTONS(port); in START_TEST()
/third_party/lwip/test/unit/tcp/
Dtest_tcp.c370 EXPECT(tcphdr.dest == PP_HTONS(TEST_REMOTE_PORT)); in START_TEST()
371 EXPECT(tcphdr.src == PP_HTONS(TEST_LOCAL_PORT)); in START_TEST()
/third_party/lwip/src/core/ipv6/
Dip6.c1057 PP_HTONS(IP6_FRAG_OFFSET_MASK | IP6_FRAG_MORE_FLAG)) == 0) {