| /net/netfilter/ipvs/ |
| A D | ip_vs_proto_udp.c | 139 struct udphdr *udph; in udp_snat_handler() local 174 udph->source = cp->vport; in udp_snat_handler() 192 udph->check = 0; in udp_snat_handler() 207 if (udph->check == 0) in udp_snat_handler() 208 udph->check = CSUM_MANGLED_0; in udp_snat_handler() 211 pp->name, udph->check, in udp_snat_handler() 212 (char*)&(udph->check) - (char*)udph); in udp_snat_handler() 222 struct udphdr *udph; in udp_dnat_handler() local 258 udph->dest = cp->dport; in udp_dnat_handler() 276 udph->check = 0; in udp_dnat_handler() [all …]
|
| A D | ip_vs_xmit.c | 1000 struct udphdr *udph; /* Our new UDP header */ in ipvs_gue_encap() local 1055 udph = udp_hdr(skb); in ipvs_gue_encap() 1058 udph->dest = dport; in ipvs_gue_encap() 1059 udph->source = sport; in ipvs_gue_encap() 1060 udph->len = htons(skb->len); in ipvs_gue_encap() 1061 udph->check = 0; in ipvs_gue_encap()
|
| A D | ip_vs_core.c | 1508 struct udphdr _udph, *udph; in ipvs_udp_decap() local 1511 udph = skb_header_pointer(skb, offset, sizeof(_udph), &_udph); in ipvs_udp_decap() 1512 if (!udph) in ipvs_udp_decap() 1515 dest = ip_vs_find_tunnel(ipvs, af, daddr, udph->dest); in ipvs_udp_decap()
|
| /net/sched/ |
| A D | act_csum.c | 258 struct udphdr *udph; in tcf_csum_ipv4_udp() local 272 udph = tcf_csum_skb_nextlayer(skb, ihl, ipl, sizeof(*udph)); in tcf_csum_ipv4_udp() 273 if (udph == NULL) in tcf_csum_ipv4_udp() 277 ul = ntohs(udph->len); in tcf_csum_ipv4_udp() 281 udph->check = 0; in tcf_csum_ipv4_udp() 301 if (!udph->check) in tcf_csum_ipv4_udp() 314 struct udphdr *udph; in tcf_csum_ipv6_udp() local 328 udph = tcf_csum_skb_nextlayer(skb, ihl, ipl, sizeof(*udph)); in tcf_csum_ipv6_udp() 329 if (udph == NULL) in tcf_csum_ipv6_udp() 335 udph->check = 0; in tcf_csum_ipv6_udp() [all …]
|
| A D | act_nat.c | 194 struct udphdr *udph; in tcf_nat_act() local 196 if (!pskb_may_pull(skb, ihl + sizeof(*udph) + noff) || in tcf_nat_act() 197 skb_try_make_writable(skb, ihl + sizeof(*udph) + noff)) in tcf_nat_act() 200 udph = (void *)(skb_network_header(skb) + ihl); in tcf_nat_act() 201 if (udph->check || skb->ip_summed == CHECKSUM_PARTIAL) { in tcf_nat_act() 202 inet_proto_csum_replace4(&udph->check, skb, addr, in tcf_nat_act() 204 if (!udph->check) in tcf_nat_act() 205 udph->check = CSUM_MANGLED_0; in tcf_nat_act()
|
| /net/ipv4/netfilter/ |
| A D | nf_nat_snmp_basic_main.c | 129 struct udphdr *udph = (struct udphdr *)((__be32 *)iph + iph->ihl); in snmp_translate() local 130 u16 datalen = ntohs(udph->len) - sizeof(struct udphdr); in snmp_translate() 131 char *data = (unsigned char *)udph + sizeof(struct udphdr); in snmp_translate() 146 ctx.begin = (unsigned char *)udph + sizeof(struct udphdr); in snmp_translate() 147 ctx.check = &udph->check; in snmp_translate() 167 const struct udphdr *udph = (struct udphdr *)((__be32 *)iph + iph->ihl); in help() local 170 if (udph->source == htons(SNMP_PORT) && dir != IP_CT_DIR_REPLY) in help() 172 if (udph->dest == htons(SNMP_TRAP_PORT) && dir != IP_CT_DIR_ORIGINAL) in help() 184 if (ntohs(udph->len) != skb->len - (iph->ihl << 2)) { in help()
|
| /net/netfilter/ |
| A D | nf_nat_helper.c | 145 struct udphdr *udph; in nf_nat_mangle_udp_packet() local 156 udph = (void *)skb->data + protoff; in nf_nat_mangle_udp_packet() 159 mangle_contents(skb, protoff + sizeof(*udph), in nf_nat_mangle_udp_packet() 164 udph->len = htons(datalen); in nf_nat_mangle_udp_packet() 167 if (!udph->check && skb->ip_summed != CHECKSUM_PARTIAL) in nf_nat_mangle_udp_packet() 171 udph, &udph->check, datalen, oldlen); in nf_nat_mangle_udp_packet()
|
| A D | nf_flow_table_ip.c | 55 struct udphdr *udph; in nf_flow_nat_ip_udp() local 57 udph = (void *)(skb_network_header(skb) + thoff); in nf_flow_nat_ip_udp() 58 if (udph->check || skb->ip_summed == CHECKSUM_PARTIAL) { in nf_flow_nat_ip_udp() 59 inet_proto_csum_replace4(&udph->check, skb, addr, in nf_flow_nat_ip_udp() 61 if (!udph->check) in nf_flow_nat_ip_udp() 62 udph->check = CSUM_MANGLED_0; in nf_flow_nat_ip_udp() 495 struct udphdr *udph; in nf_flow_nat_ipv6_udp() local 497 udph = (void *)(skb_network_header(skb) + thoff); in nf_flow_nat_ipv6_udp() 498 if (udph->check || skb->ip_summed == CHECKSUM_PARTIAL) { in nf_flow_nat_ipv6_udp() 501 if (!udph->check) in nf_flow_nat_ipv6_udp() [all …]
|
| A D | nf_flow_table_core.c | 612 struct udphdr *udph; in nf_flow_nat_port_udp() local 614 udph = (void *)(skb_network_header(skb) + thoff); in nf_flow_nat_port_udp() 615 if (udph->check || skb->ip_summed == CHECKSUM_PARTIAL) { in nf_flow_nat_port_udp() 616 inet_proto_csum_replace2(&udph->check, skb, port, in nf_flow_nat_port_udp() 618 if (!udph->check) in nf_flow_nat_port_udp() 619 udph->check = CSUM_MANGLED_0; in nf_flow_nat_port_udp()
|
| /net/core/ |
| A D | netpoll.c | 378 struct udphdr *udph; in netpoll_udp_checksum() local 382 udph = udp_hdr(skb); in netpoll_udp_checksum() 385 udph->check = 0; in netpoll_udp_checksum() 395 csum_partial(udph, udp_len, 0)); in netpoll_udp_checksum() 396 if (udph->check == 0) in netpoll_udp_checksum() 397 udph->check = CSUM_MANGLED_0; in netpoll_udp_checksum() 469 struct udphdr *udph; in push_udp() local 477 udph = udp_hdr(skb); in push_udp() 478 udph->source = htons(np->local_port); in push_udp() 479 udph->dest = htons(np->remote_port); in push_udp() [all …]
|
| A D | pktgen.c | 2932 struct udphdr *udph; in fill_packet_ipv4() local 3007 udph->dest = htons(pkt_dev->cur_udp_dst); in fill_packet_ipv4() 3009 udph->check = 0; in fill_packet_ipv4() 3043 if (udph->check == 0) in fill_packet_ipv4() 3044 udph->check = CSUM_MANGLED_0; in fill_packet_ipv4() 3060 struct udphdr *udph; in fill_packet_ipv6() local 3140 udph->dest = htons(pkt_dev->cur_udp_dst); in fill_packet_ipv6() 3141 udph->len = htons(udplen); in fill_packet_ipv6() 3142 udph->check = 0; in fill_packet_ipv6() 3178 if (udph->check == 0) in fill_packet_ipv6() [all …]
|
| /net/ipv4/ |
| A D | ipconfig.c | 629 struct udphdr udph; /* UDP header */ member 853 b->udph.source = htons(68); in ic_bootp_send_if() 854 b->udph.dest = htons(67); in ic_bootp_send_if() 855 b->udph.len = htons(sizeof(struct bootp_pkt) - sizeof(struct iphdr)); in ic_bootp_send_if() 1030 if (b->udph.source != htons(67) || b->udph.dest != htons(68)) in ic_bootp_recv() 1033 if (ntohs(h->tot_len) < ntohs(b->udph.len) + sizeof(struct iphdr)) in ic_bootp_recv() 1036 len = ntohs(b->udph.len) - sizeof(struct udphdr); in ic_bootp_recv()
|
| A D | ip_tunnel.c | 366 const struct udphdr *udph; in ip_tunnel_md_udp_encap() local 371 udph = (struct udphdr *)((__u8 *)iph + (iph->ihl << 2)); in ip_tunnel_md_udp_encap() 372 info->encap.sport = udph->source; in ip_tunnel_md_udp_encap() 373 info->encap.dport = udph->dest; in ip_tunnel_md_udp_encap()
|
| A D | route.c | 3179 struct udphdr *udph; in inet_rtm_getroute_build_skb() local 3181 udph = skb_put_zero(skb, sizeof(struct udphdr)); in inet_rtm_getroute_build_skb() 3182 udph->source = sport; in inet_rtm_getroute_build_skb() 3183 udph->dest = dport; in inet_rtm_getroute_build_skb() 3184 udph->len = htons(sizeof(struct udphdr)); in inet_rtm_getroute_build_skb() 3185 udph->check = 0; in inet_rtm_getroute_build_skb()
|