Home
last modified time | relevance | path

Searched refs:htons (Results 1 – 25 of 30) sorted by relevance

12

/include/net/
Dtun_proto.h19 return htons(ETH_P_IP); in tun_p_to_eth_p()
21 return htons(ETH_P_IPV6); in tun_p_to_eth_p()
23 return htons(ETH_P_TEB); in tun_p_to_eth_p()
25 return htons(ETH_P_NSH); in tun_p_to_eth_p()
27 return htons(ETH_P_MPLS_UC); in tun_p_to_eth_p()
35 case htons(ETH_P_IP): in tun_p_from_eth_p()
37 case htons(ETH_P_IPV6): in tun_p_from_eth_p()
39 case htons(ETH_P_TEB): in tun_p_from_eth_p()
41 case htons(ETH_P_NSH): in tun_p_from_eth_p()
43 case htons(ETH_P_MPLS_UC): in tun_p_from_eth_p()
Ddsfield.h39 iph->check = (__force __sum16)htons(check); in ipv4_change_dsfield()
49 *p = (*p & htons((((u16)mask << 4) | 0xf00f))) | htons((u16)value << 4); in ipv6_change_dsfield()
Dmpls.h21 return eth_type == htons(ETH_P_MPLS_UC) || in eth_p_mpls()
22 eth_type == htons(ETH_P_MPLS_MC); in eth_p_mpls()
Dinet_ecn.h96 check += (__force u16)htons(0xFFFB) + (__force u16)htons(ecn); in IP_ECN_set_ce()
110 check += (__force u16)htons(0x1); in IP_ECN_set_ect1()
277 case htons(ETH_P_IP): in IP_ECN_decapsulate()
280 case htons(ETH_P_IPV6): in IP_ECN_decapsulate()
296 case htons(ETH_P_IP): in IP6_ECN_decapsulate()
299 case htons(ETH_P_IPV6): in IP6_ECN_decapsulate()
Dx25device.h16 return htons(ETH_P_X25); in x25_type_trans()
Dnsh.h287 = (nsh->ver_flags_ttl_len & ~htons(xmask)) | htons(xflag); in __nsh_set_xflag()
Dudplite.h80 udp_hdr(skb)->len = htons(up->pcslen); in udplite_csum_outgoing()
118 udp_hdr(skb)->len = htons(up->pcslen); in udplite_csum()
Dgue.h56 #define GUE_FLAG_PRIV htons(1<<0) /* Private flags are in options */
Dip_tunnels.h322 case htons(ETH_P_IPV6): in pskb_inet_may_pull()
326 case htons(ETH_P_IP): in pskb_inet_may_pull()
383 if (payload_protocol == htons(ETH_P_IP)) in ip_tunnel_get_dsfield()
385 else if (payload_protocol == htons(ETH_P_IPV6)) in ip_tunnel_get_dsfield()
396 if (payload_protocol == htons(ETH_P_IP)) in ip_tunnel_get_ttl()
398 else if (payload_protocol == htons(ETH_P_IPV6)) in ip_tunnel_get_ttl()
Derspan.h194 if (eth->h_proto == htons(ETH_P_8021Q)) { in erspan_build_header()
288 if (eth->h_proto == htons(ETH_P_8021Q)) { in erspan_build_header_v2()
309 md2->sgt = htons(sgt); in erspan_build_header_v2()
Dvxlan.h308 case htons(ETH_P_IP): in vxlan_features_check()
311 case htons(ETH_P_IPV6): in vxlan_features_check()
320 skb->inner_protocol != htons(ETH_P_TEB) || in vxlan_features_check()
Dipv6_frag.h122 if (offset < 0 || (frag_off & htons(IP6_OFFSET))) in ipv6frag_thdr_truncated()
Dip.h402 return (iph->frag_off & htons(IP_MF | IP_OFFSET)) != 0; in ip_is_fragment()
414 check += (__force u32)htons(0x0100); in ip_decrease_ttl()
530 iph->id = htons(inet_sk(sk)->inet_id); in ip_select_ident_segs()
534 if ((iph->frag_off & htons(IP_DF)) && !skb->ignore_df) { in ip_select_ident_segs()
Dxfrm.h854 port = htons(uli->icmpt.type); in xfrm_flowi_sport()
857 port = htons(uli->mht.type); in xfrm_flowi_sport()
860 port = htons(ntohl(uli->gre_key) >> 16); in xfrm_flowi_sport()
881 port = htons(uli->icmpt.code); in xfrm_flowi_dport()
884 port = htons(ntohl(uli->gre_key) & 0xffff); in xfrm_flowi_dport()
/include/scsi/
Dfc_encode.h106 ct->hdr.ct_cmd = htons((u16) op); in fc_ct_hdr_fill()
537 csp->sp_bb_cred = htons(10); /* this gets set by gateway */ in fc_plogi_fill()
538 csp->sp_bb_data = htons((u16) lport->mfs); in fc_plogi_fill()
540 cp->cp_class = htons(FC_CPC_VALID | FC_CPC_SEQ); in fc_plogi_fill()
541 csp->sp_features = htons(FC_SP_FT_CIRO); in fc_plogi_fill()
542 csp->sp_tot_seq = htons(255); /* seq. we accept */ in fc_plogi_fill()
543 csp->sp_rel_off = htons(0x1f); in fc_plogi_fill()
546 cp->cp_rdfs = htons((u16) lport->mfs); in fc_plogi_fill()
547 cp->cp_con_seq = htons(255); in fc_plogi_fill()
568 sp->sp_bb_cred = htons(10); /* this gets set by gateway */ in fc_flogi_fill()
[all …]
/include/uapi/linux/
Dtipc_config.h288 tlv->tlv_len = htons(len); in TLV_SET_LEN()
298 tlv->tlv_type = htons(type); in TLV_SET_TYPE()
308 tlv_ptr->tlv_type = htons(type); in TLV_SET()
309 tlv_ptr->tlv_len = htons(tlv_len); in TLV_SET()
408 tcm_hdr->tcm_type = htons(cmd); in TCM_SET()
409 tcm_hdr->tcm_flags = htons(flags); in TCM_SET()
/include/linux/
Dif_vlan.h313 case htons(ETH_P_8021Q): in eth_type_vlan()
314 case htons(ETH_P_8021AD): in eth_type_vlan()
324 if (proto == htons(ETH_P_8021Q) && features & NETIF_F_HW_VLAN_CTAG_TX) in vlan_hw_offload_capable()
326 if (proto == htons(ETH_P_8021AD) && features & NETIF_F_HW_VLAN_STAG_TX) in vlan_hw_offload_capable()
375 veth->h_vlan_TCI = htons(vlan_tci); in __vlan_insert_inner_tag()
694 skb->protocol = htons(ETH_P_802_3); in vlan_set_encap_proto()
699 skb->protocol = htons(ETH_P_802_2); in vlan_set_encap_proto()
Dvirtio_net.h122 skb->protocol == htons(ETH_P_IP)) { in virtio_net_hdr_to_skb()
123 skb->protocol = htons(ETH_P_IPV6); in virtio_net_hdr_to_skb()
Dhdlc.h112 return htons(ETH_P_HDLC); in hdlc_type_trans()
Detherdevice.h210 proto &= htons(0xFF00); in eth_proto_is_802_3()
213 return (__force u16)proto >= (__force u16)htons(ETH_P_802_3_MIN); in eth_proto_is_802_3()
/include/linux/byteorder/
Dgeneric.h132 #undef htons
141 #define htons(x) ___htons(x) macro
/include/linux/sunrpc/
Daddr.h39 ((struct sockaddr_in *)sap)->sin_port = htons(port); in rpc_set_port()
42 ((struct sockaddr_in6 *)sap)->sin6_port = htons(port); in rpc_set_port()
/include/net/netfilter/
Dnf_queue.h88 case htons(ETH_P_IP): in hash_bridge()
94 case htons(ETH_P_IPV6): in hash_bridge()
/include/linux/can/
Ddev.h146 if (skb->protocol == htons(ETH_P_CAN)) { in can_dropped_invalid_skb()
150 } else if (skb->protocol == htons(ETH_P_CANFD)) { in can_dropped_invalid_skb()
/include/rdma/
Dib_sa.h237 ib->ib.dlid = htons(ntohl(opa->opa.dlid)); in path_conv_opa_to_ib()
238 ib->ib.slid = htons(ntohl(opa->opa.slid)); in path_conv_opa_to_ib()

12