/linux/net/ipv6/netfilter/ |
A D | ip6t_frag.c | 57 pr_debug("OFFSET %04X ", ntohs(fh->frag_off) & ~0x7); in frag_mt6() 69 ntohs(fh->frag_off) & 0x6, in frag_mt6() 74 ntohs(fh->frag_off) & ~0x7, in frag_mt6() 76 (ntohs(fh->frag_off) & ~0x7))); in frag_mt6() 79 ntohs(fh->frag_off) & IP6_MF, in frag_mt6() 81 !((ntohs(fh->frag_off) & IP6_MF)))); in frag_mt6() 84 ntohs(fh->frag_off) & IP6_MF, in frag_mt6() 86 (ntohs(fh->frag_off) & IP6_MF))); in frag_mt6() 94 (ntohs(fh->frag_off) & ~0x7)) && in frag_mt6() 96 !(ntohs(fh->frag_off) & IP6_MF)) && in frag_mt6() [all …]
|
/linux/net/6lowpan/ |
A D | nhc_udp.c | 72 ntohs(uh.source), ntohs(uh.dest)); in udp_uncompress() 101 pr_debug("uncompressed UDP length: src = %d", ntohs(uh.len)); in udp_uncompress() 121 if (((ntohs(uh->source) & LOWPAN_NHC_UDP_4BIT_MASK) == in udp_compress() 123 ((ntohs(uh->dest) & LOWPAN_NHC_UDP_4BIT_MASK) == in udp_compress() 130 tmp = ntohs(uh->dest) - LOWPAN_NHC_UDP_4BIT_PORT + in udp_compress() 131 ((ntohs(uh->source) - LOWPAN_NHC_UDP_4BIT_PORT) << 4); in udp_compress() 133 } else if ((ntohs(uh->dest) & LOWPAN_NHC_UDP_8BIT_MASK) == in udp_compress() 142 tmp = ntohs(uh->dest) - LOWPAN_NHC_UDP_8BIT_PORT; in udp_compress() 144 } else if ((ntohs(uh->source) & LOWPAN_NHC_UDP_8BIT_MASK) == in udp_compress() 151 tmp = ntohs(uh->source) - LOWPAN_NHC_UDP_8BIT_PORT; in udp_compress()
|
/linux/net/netfilter/ |
A D | nf_log_syslog.c | 80 ntohs(eth_hdr(skb)->h_proto)); in dump_arp_packet() 84 ntohs(ah->ar_hrd), ntohs(ah->ar_pro), ntohs(ah->ar_op)); in dump_arp_packet() 201 ntohs(th->source), ntohs(th->dest)); in nf_log_dump_tcp_header() 285 ntohs(uh->source), ntohs(uh->dest), ntohs(uh->len)); in nf_log_dump_udp_header() 324 if (ntohs(ih->frag_off) & IP_CE) in dump_ipv4_packet() 326 if (ntohs(ih->frag_off) & IP_DF) in dump_ipv4_packet() 328 if (ntohs(ih->frag_off) & IP_MF) in dump_ipv4_packet() 332 if (ntohs(ih->frag_off) & IP_OFFSET) in dump_ipv4_packet() 418 ntohs(ich->un.echo.id), in dump_ipv4_packet() 446 ntohs(ich->un.frag.mtu)); in dump_ipv4_packet() [all …]
|
A D | nf_conntrack_pptp.c | 286 msg = ntohs(ctlh->messageType); in pptp_inbound_pkt() 323 ntohs(cid), ntohs(pcid)); in pptp_inbound_pkt() 339 pr_debug("%s, CID=%X\n", pptp_msg_name(msg), ntohs(cid)); in pptp_inbound_pkt() 396 msg, ntohs(cid), ntohs(pcid), info->cstate, info->sstate, in pptp_inbound_pkt() 397 ntohs(info->pns_call_id), ntohs(info->pac_call_id)); in pptp_inbound_pkt() 414 msg = ntohs(ctlh->messageType); in pptp_outbound_pkt() 452 ntohs(cid), ntohs(pcid)); in pptp_outbound_pkt() 492 msg, ntohs(cid), ntohs(pcid), info->cstate, info->sstate, in pptp_outbound_pkt() 493 ntohs(info->pns_call_id), ntohs(info->pac_call_id)); in pptp_outbound_pkt() 562 if (ntohs(pptph->packetType) != PPTP_PACKET_CONTROL || in conntrack_pptp_help() [all …]
|
A D | xt_sctp.c | 72 offset += SCTP_PAD4(ntohs(sch->length)); in match_packet() 136 pr_debug("spt: %d\tdpt: %d\n", ntohs(sh->source), ntohs(sh->dest)); in sctp_mt() 138 return SCCHECK(ntohs(sh->source) >= info->spts[0] in sctp_mt() 139 && ntohs(sh->source) <= info->spts[1], in sctp_mt() 141 SCCHECK(ntohs(sh->dest) >= info->dpts[0] in sctp_mt() 142 && ntohs(sh->dest) <= info->dpts[1], in sctp_mt()
|
A D | xt_TPROXY.c | 79 iph->protocol, &iph->daddr, ntohs(hp->dest), in tproxy_tg4() 80 &laddr, ntohs(lport), skb->mark); in tproxy_tg4() 87 iph->protocol, &iph->saddr, ntohs(hp->source), in tproxy_tg4() 88 &iph->daddr, ntohs(hp->dest), skb->mark); in tproxy_tg4() 173 tproto, &iph->saddr, ntohs(hp->source), in tproxy_tg6_v1() 174 laddr, ntohs(lport), skb->mark); in tproxy_tg6_v1() 181 tproto, &iph->saddr, ntohs(hp->source), in tproxy_tg6_v1() 182 &iph->daddr, ntohs(hp->dest), skb->mark); in tproxy_tg6_v1()
|
A D | nf_nat_core.c | 222 return ntohs(tuple->src.u.icmp.id) >= ntohs(min->icmp.id) && in l4proto_in_range() 223 ntohs(tuple->src.u.icmp.id) <= ntohs(max->icmp.id); in l4proto_in_range() 235 return ntohs(port) >= ntohs(min->all) && in l4proto_in_range() 236 ntohs(port) <= ntohs(max->all); in l4proto_in_range() 399 min = ntohs(range->min_proto.icmp.id); in nf_nat_l4proto_unique_tuple() 420 min = ntohs(range->min_proto.gre.key); in nf_nat_l4proto_unique_tuple() 446 if (ntohs(*keyptr) < 1024) { in nf_nat_l4proto_unique_tuple() 448 if (ntohs(*keyptr) < 512) { in nf_nat_l4proto_unique_tuple() 460 min = ntohs(range->min_proto.all); in nf_nat_l4proto_unique_tuple() 461 max = ntohs(range->max_proto.all); in nf_nat_l4proto_unique_tuple() [all …]
|
A D | nfnetlink_osf.c | 110 mss = ntohs((__force __be16)mss); in nf_osf_match_one() 180 ctx->totlen = ntohs(ip->tot_len); in nf_osf_hdr_ctx_init() 181 ctx->df = ntohs(ip->frag_off) & IP_DF; in nf_osf_hdr_ctx_init() 182 ctx->window = ntohs(tcp->window); in nf_osf_hdr_ctx_init() 239 &ip->saddr, ntohs(tcp->source), in nf_osf_match() 240 &ip->daddr, ntohs(tcp->dest), in nf_osf_match() 251 &ip->saddr, ntohs(tcp->source), in nf_osf_match() 252 &ip->daddr, ntohs(tcp->dest)); in nf_osf_match()
|
/linux/net/ipv4/netfilter/ |
A D | nf_nat_h323.c | 160 &addr.ip, ntohs(port), in set_ras_addr() 287 u_int16_t nated_port = ntohs(port); in nat_t120() 323 ntohs(exp->tuple.src.u.tcp.port), in nat_t120() 325 ntohs(exp->tuple.dst.u.tcp.port)); in nat_t120() 339 u_int16_t nated_port = ntohs(port); in nat_h245() 383 ntohs(exp->tuple.src.u.tcp.port), in nat_h245() 385 ntohs(exp->tuple.dst.u.tcp.port)); in nat_h245() 430 u_int16_t nated_port = ntohs(port); in nat_q931() 488 ntohs(exp->tuple.src.u.tcp.port), in nat_q931() 490 ntohs(exp->tuple.dst.u.tcp.port)); in nat_q931() [all …]
|
/linux/net/netfilter/ipvs/ |
A D | ip_vs_ftp.c | 289 &from.ip, ntohs(port), &cp->caddr.ip, 0); in ip_vs_ftp_out() 310 IP_VS_DBG_ADDR(cp->af, &from), ntohs(port), in ip_vs_ftp_out() 351 ntohs(port) >> 8, in ip_vs_ftp_out() 352 ntohs(port) & 0xFF); in ip_vs_ftp_out() 358 ntohs(port)); in ip_vs_ftp_out() 504 &to.ip, ntohs(port), &cp->vaddr.ip, in ip_vs_ftp_in() 505 ntohs(cp->vport)-1); in ip_vs_ftp_in() 519 IP_VS_DBG_ADDR(cp->af, &to), ntohs(port), in ip_vs_ftp_in() 521 ntohs(cp->vport)-1); in ip_vs_ftp_in() 533 htons(ntohs(cp->vport)-1), &p); in ip_vs_ftp_in() [all …]
|
A D | ip_vs_conn.c | 784 ntohs(ct->cport), in ip_vs_check_template() 786 ntohs(ct->vport), in ip_vs_check_template() 788 ntohs(ct->dport)); in ip_vs_check_template() 1157 &cp->caddr.in6, ntohs(cp->cport), in ip_vs_conn_seq_show() 1158 &cp->vaddr.in6, ntohs(cp->vport), in ip_vs_conn_seq_show() 1159 dbuf, ntohs(cp->dport), in ip_vs_conn_seq_show() 1172 dbuf, ntohs(cp->dport), in ip_vs_conn_seq_show() 1223 &cp->caddr.in6, ntohs(cp->cport), in ip_vs_conn_sync_seq_show() 1224 &cp->vaddr.in6, ntohs(cp->vport), in ip_vs_conn_sync_seq_show() 1225 dbuf, ntohs(cp->dport), in ip_vs_conn_sync_seq_show() [all …]
|
/linux/net/hsr/ |
A D | hsr_main.h | 80 htons((ntohs(ht->path_and_LSDU_size) & 0x0FFF) | (path << 12)); in set_hsr_tag_path() 85 ht->path_and_LSDU_size = htons((ntohs(ht->path_and_LSDU_size) & in set_hsr_tag_LSDU_size() 161 return ntohs(rct->lan_id_and_LSDU_size) & 0x0FFF; in get_prp_LSDU_size() 166 rct->lan_id_and_LSDU_size = htons((ntohs(rct->lan_id_and_LSDU_size) & in set_prp_lan_id() 171 rct->lan_id_and_LSDU_size = htons((ntohs(rct->lan_id_and_LSDU_size) & in set_prp_LSDU_size() 241 return ntohs(hsr_ethhdr->hsr_tag.sequence_nr); in hsr_get_skb_sequence_nr() 259 return ntohs(rct->sequence_nr); in prp_get_skb_sequence_nr() 264 return ntohs(rct->lan_id_and_LSDU_size) >> 12; in get_prp_lan_id()
|
/linux/net/appletalk/ |
A D | atalk_proc.c | 71 iface->dev->name, ntohs(iface->address.s_net), in atalk_seq_interface_show() 72 iface->address.s_node, ntohs(iface->nets.nr_firstnet), in atalk_seq_interface_show() 73 ntohs(iface->nets.nr_lastnet), iface->status); in atalk_seq_interface_show() 132 ntohs(rt->gateway.s_net), rt->gateway.s_node, in atalk_seq_route_show() 138 ntohs(rt->target.s_net), rt->target.s_node, in atalk_seq_route_show() 139 ntohs(rt->gateway.s_net), rt->gateway.s_node, in atalk_seq_route_show() 179 s->sk_type, ntohs(at->src_net), at->src_node, at->src_port, in atalk_seq_socket_show() 180 ntohs(at->dest_net), at->dest_node, at->dest_port, in atalk_seq_socket_show()
|
A D | ddp.c | 246 ntohs(atif->nets.nr_firstnet) + 1; in atif_probe_device() 294 ntohs(atif->nets.nr_firstnet) + 1; in atif_proxy_probe_device() 410 ntohs(iface->nets.nr_firstnet) <= ntohs(net) && in atalk_find_interface() 411 ntohs(net) <= ntohs(iface->nets.nr_lastnet)) in atalk_find_interface() 534 ntohs(ga->sat_addr.s_net) >= in atrtr_create() 535 ntohs(iface->nets.nr_firstnet) && in atrtr_create() 536 ntohs(ga->sat_addr.s_net) <= in atrtr_create() 537 ntohs(iface->nets.nr_lastnet)) in atrtr_create() 764 limit = ntohs(nr->nr_lastnet); in atif_ioctl() 771 for (ct = ntohs(nr->nr_firstnet); in atif_ioctl() [all …]
|
/linux/include/net/netfilter/ |
A D | nf_tables_ipv4.h | 16 pkt->fragoff = ntohs(ip->frag_off) & IP_OFFSET; in nft_set_pktinfo_ipv4() 32 len = ntohs(iph->tot_len); in __nft_set_pktinfo_ipv4_validate() 42 pkt->fragoff = ntohs(iph->frag_off) & IP_OFFSET; in __nft_set_pktinfo_ipv4_validate() 65 len = ntohs(iph->tot_len); in nft_set_pktinfo_ipv4_ingress() 77 pkt->fragoff = ntohs(iph->frag_off) & IP_OFFSET; in nft_set_pktinfo_ipv4_ingress()
|
/linux/drivers/net/slip/ |
A D | slhc.c | 370 deltaS = ntohs(th->urg_ptr); in slhc_compress() 380 if((deltaS = ntohs(th->window) - ntohs(oth->window)) != 0){ in slhc_compress() 406 ntohs(cs->cs_ip.tot_len) == hlen) in slhc_compress() 417 deltaS == ntohs(cs->cs_ip.tot_len) - hlen){ in slhc_compress() 424 if(deltaS == ntohs(cs->cs_ip.tot_len) - hlen){ in slhc_compress() 431 deltaS = ntohs(ip->id) - ntohs(cs->cs_ip.id); in slhc_compress() 553 i = ntohs(ip->tot_len) - hdrlen; in slhc_uncompress() 561 ntohs(ip->tot_len) - hdrlen); in slhc_uncompress() 577 thp->window = htons( ntohs(thp->window) + x); in slhc_uncompress() 597 ip->id = htons (ntohs (ip->id) + x); in slhc_uncompress() [all …]
|
/linux/net/sctp/ |
A D | sm_make_chunk.c | 1769 len = ntohs(chunk->chunk_hdr->length); in sctp_unpack_cookie() 1994 __u16 len = ntohs(param.p->length); in sctp_process_hn_param() 2144 ntohs(param.p->length))) in sctp_process_unk_param() 2246 if (260 < ntohs(param.p->length)) { in sctp_verify_param() 2258 n_elt = (ntohs(param.p->length) - in sctp_verify_param() 2266 id = ntohs(hmacs->hmac_ids[i]); in sctp_verify_param() 2710 ntohs(param.p->length), gfp); in sctp_process_param() 2724 ntohs(param.p->length), gfp); in sctp_process_param() 2740 ntohs(param.p->length), gfp); in sctp_process_param() 3300 length = ntohs(addr_param->p.length); in sctp_process_asconf() [all …]
|
A D | auth.c | 195 random_len = ntohs(random->param_hdr.length); in sctp_auth_make_key_vector() 196 hmacs_len = ntohs(hmacs->param_hdr.length); in sctp_auth_make_key_vector() 198 chunks_len = ntohs(chunks->param_hdr.length); in sctp_auth_make_key_vector() 542 n_elt = (ntohs(hmacs->param_hdr.length) - in sctp_auth_asoc_get_hmac() 545 id = ntohs(hmacs->hmac_ids[i]); in sctp_auth_asoc_get_hmac() 594 n_elt = (ntohs(hmacs->param_hdr.length) - in sctp_auth_asoc_verify_hmac_id() 618 n_params = (ntohs(hmacs->param_hdr.length) - in sctp_auth_asoc_set_default_hmac() 622 id = ntohs(hmacs->hmac_ids[i]); in sctp_auth_asoc_set_default_hmac() 722 key_id = ntohs(auth->auth_hdr.shkey_id); in sctp_auth_calculate_hmac() 723 hmac_id = ntohs(auth->auth_hdr.hmac_id); in sctp_auth_calculate_hmac() [all …]
|
/linux/net/ife/ |
A D | ife.c | 76 ifehdrln = ntohs(ifehdr->metalen); in ife_decode() 108 tlvlen = ntohs(tlv->len); in __ife_tlv_meta_valid() 135 *dlen = ntohs(tlv->len) - NLA_HDRLEN; in ife_tlv_meta_decode() 136 *attrtype = ntohs(tlv->type); in ife_tlv_meta_decode() 148 u16 tlvlen = ntohs(tlv->len); in ife_tlv_meta_next()
|
/linux/net/bridge/netfilter/ |
A D | ebt_log.c | 69 pr_cont(" SPT=%u DPT=%u", ntohs(pptr->src), ntohs(pptr->dst)); in print_ports() 90 ntohs(eth_hdr(skb)->h_proto)); in ebt_log_packet() 150 ntohs(ah->ar_hrd), ntohs(ah->ar_pro), in ebt_log_packet() 151 ntohs(ah->ar_op)); in ebt_log_packet()
|
A D | ebt_vlan.c | 47 TCI = ntohs(fp->h_vlan_TCI); in ebt_vlan_mt() 85 ntohs(e->ethproto)); in ebt_vlan_mt_check() 141 if ((unsigned short) ntohs(info->encap) < ETH_ZLEN) { in ebt_vlan_mt_check() 143 "minimal\n", ntohs(info->encap)); in ebt_vlan_mt_check()
|
/linux/net/dsa/ |
A D | tag_rtl8_4.c | 128 etype = ntohs(tag[0]); in rtl8_4_tag_rcv() 136 proto = FIELD_GET(RTL8_4_PROTOCOL, ntohs(tag[1])); in rtl8_4_tag_rcv() 145 reason = FIELD_GET(RTL8_4_REASON, ntohs(tag[1])); in rtl8_4_tag_rcv() 148 port = FIELD_GET(RTL8_4_TX, ntohs(tag[3])); in rtl8_4_tag_rcv()
|
/linux/include/net/ |
A D | nsh.h | 262 return ((ntohs(nsh->ver_flags_ttl_len) & NSH_LEN_MASK) in nsh_hdr_len() 268 return (ntohs(nsh->ver_flags_ttl_len) & NSH_VER_MASK) in nsh_get_ver() 274 return (ntohs(nsh->ver_flags_ttl_len) & NSH_FLAGS_MASK) in nsh_get_flags() 280 return (ntohs(nsh->ver_flags_ttl_len) & NSH_TTL_MASK) in nsh_get_ttl()
|
/linux/samples/bpf/ |
A D | test_probe_write_user_user.c | 73 printf("Server bound to: %s:%d\n", ip, ntohs(serv_addr_in->sin_port)); in main() 86 ip, ntohs(mapped_addr_in->sin_port)); in main() 93 ip, ntohs(tmp_addr_in->sin_port)); in main() 99 ip, ntohs(tmp_addr_in->sin_port)); in main()
|
/linux/drivers/net/ethernet/marvell/prestera/ |
A D | prestera_flower.c | 132 n_proto_key = ntohs(match.key->n_proto); in prestera_flower_parse() 133 n_proto_mask = ntohs(match.mask->n_proto); in prestera_flower_parse() 229 m_entry.keymask.u16.key = ntohs(match.key->src); in prestera_flower_parse() 230 m_entry.keymask.u16.mask = ntohs(match.mask->src); in prestera_flower_parse() 237 m_entry.keymask.u16.key = ntohs(match.key->dst); in prestera_flower_parse() 238 m_entry.keymask.u16.mask = ntohs(match.mask->dst); in prestera_flower_parse() 261 m_entry.keymask.u16.key = ntohs(match.key->vlan_tpid); in prestera_flower_parse() 262 m_entry.keymask.u16.mask = ntohs(match.mask->vlan_tpid); in prestera_flower_parse()
|