/linux/net/ipv6/ |
A D | exthdrs_core.c | 13 bool ipv6_ext_hdr(u8 nexthdr) in ipv6_ext_hdr() argument 23 (nexthdr == NEXTHDR_DEST); in ipv6_ext_hdr() 75 u8 nexthdr = *nexthdrp; in ipv6_skip_exthdr() local 107 nexthdr = hp->nexthdr; in ipv6_skip_exthdr() 111 *nexthdrp = nexthdr; in ipv6_skip_exthdr() 190 u8 nexthdr = ipv6_hdr(skb)->nexthdr; in ipv6_find_hdr() local 203 nexthdr = ip6->nexthdr; in ipv6_find_hdr() 211 if ((!ipv6_ext_hdr(nexthdr)) || nexthdr == NEXTHDR_NONE) { in ipv6_find_hdr() 255 return hp->nexthdr; in ipv6_find_hdr() 272 nexthdr = hp->nexthdr; in ipv6_find_hdr() [all …]
|
A D | ip6_input.c | 249 IP6CB(skb)->nhoff = offsetof(struct ipv6hdr, nexthdr); in ip6_rcv_core() 254 if (pkt_len || hdr->nexthdr != NEXTHDR_HOP) { in ip6_rcv_core() 267 if (hdr->nexthdr == NEXTHDR_HOP) { in ip6_rcv_core() 368 nexthdr = skb_network_header(skb)[nhoff]; in ip6_protocol_deliver_rcu() 372 raw = raw6_local_deliver(skb, nexthdr); in ip6_protocol_deliver_rcu() 373 ipprot = rcu_dereference(inet6_protos[nexthdr]); in ip6_protocol_deliver_rcu() 431 nexthdr = ret; in ip6_protocol_deliver_rcu() 525 u8 nexthdr = hdr->nexthdr; in ip6_mc_input() local 535 if (!ipv6_ext_hdr(nexthdr)) { in ip6_mc_input() 540 &nexthdr, &frag_off); in ip6_mc_input() [all …]
|
A D | output_core.c | 64 int ip6_find_1stfragopt(struct sk_buff *skb, u8 **nexthdr) in ip6_find_1stfragopt() argument 70 *nexthdr = &ipv6_hdr(skb)->nexthdr; in ip6_find_1stfragopt() 75 switch (**nexthdr) { in ip6_find_1stfragopt() 102 *nexthdr = &exthdr->nexthdr; in ip6_find_1stfragopt() 138 IP6CB(skb)->nhoff = offsetof(struct ipv6hdr, nexthdr); in __ip6_local_out()
|
A D | mcast_snoop.c | 41 u8 nexthdr; in ipv6_mc_check_exthdrs() local 46 if (ip6h->nexthdr != IPPROTO_HOPOPTS) in ipv6_mc_check_exthdrs() 49 nexthdr = ip6h->nexthdr; in ipv6_mc_check_exthdrs() 51 offset = ipv6_skip_exthdr(skb, offset, &nexthdr, &frag_off); in ipv6_mc_check_exthdrs() 56 if (nexthdr != IPPROTO_ICMPV6) in ipv6_mc_check_exthdrs()
|
A D | mip6.c | 123 int err = destopt->nexthdr; in mip6_destopt_input() 143 u8 nexthdr; in mip6_destopt_output() local 149 nexthdr = *skb_mac_header(skb); in mip6_destopt_output() 153 dstopt->nexthdr = nexthdr; in mip6_destopt_output() 293 int err = rt2->rt_hdr.nexthdr; in mip6_rthdr_input() 311 u8 nexthdr; in mip6_rthdr_output() local 316 nexthdr = *skb_mac_header(skb); in mip6_rthdr_output() 320 rt2->rt_hdr.nexthdr = nexthdr; in mip6_rthdr_output()
|
A D | ah6.c | 253 int nexthdr = iph->nexthdr; in ipv6_clear_mutable_options() local 258 switch (nexthdr) { in ipv6_clear_mutable_options() 266 nexthdr == NEXTHDR_HOP ? in ipv6_clear_mutable_options() 280 nexthdr = exthdr.opth->nexthdr; in ipv6_clear_mutable_options() 329 u8 nexthdr; in ah6_output() local 379 nexthdr = *skb_mac_header(skb); in ah6_output() 401 ah->nexthdr = nexthdr; in ah6_output() 480 err = ah->nexthdr; in ah6_input_done() 525 int nexthdr; in ah6_input() local 548 nexthdr = ah->nexthdr; in ah6_input() [all …]
|
A D | rpl.c | 44 outhdr->nexthdr = inhdr->nexthdr; in ipv6_rpl_srh_decompress() 104 outhdr->nexthdr = inhdr->nexthdr; in ipv6_rpl_srh_compress()
|
A D | ioam6_iptunnel.c | 208 tuninfo->eh.nexthdr = hdr->nexthdr; in ioam6_do_inline() 215 hdr->nexthdr = NEXTHDR_HOP; in ioam6_do_inline() 243 tuninfo->eh.nexthdr = NEXTHDR_IPV6; in ioam6_do_encap() 249 hdr->nexthdr = NEXTHDR_HOP; in ioam6_do_encap() 277 if (ipv6_hdr(skb)->nexthdr == NEXTHDR_HOP) in ioam6_output() 324 fl6.flowi6_proto = hdr->nexthdr; in ioam6_output()
|
A D | ip6_offload.c | 67 proto = opth->nexthdr; in ipv6_gso_pull_exthdrs() 103 proto = ipv6_gso_pull_exthdrs(skb, ipv6h->nexthdr); in ipv6_gso_segment() 166 proto = iph->nexthdr; in ipv6_exthdrs_len() 178 proto = opth->nexthdr; in ipv6_exthdrs_len() 212 proto = iph->nexthdr; in ipv6_gro_receive() 253 *(u16 *)&iph->nexthdr != *(u16 *)&iph2->nexthdr) { in ipv6_gro_receive()
|
/linux/net/ipv6/netfilter/ |
A D | ip6t_ipv6header.c | 32 u8 nexthdr; in ipv6header_mt6() local 38 nexthdr = ipv6_hdr(skb)->nexthdr; in ipv6header_mt6() 45 while (nf_ip6_ext_hdr(nexthdr)) { in ipv6header_mt6() 51 if (nexthdr == NEXTHDR_NONE) { in ipv6header_mt6() 59 if (nexthdr == NEXTHDR_ESP) { in ipv6header_mt6() 71 if (nexthdr == NEXTHDR_FRAGMENT) in ipv6header_mt6() 73 else if (nexthdr == NEXTHDR_AUTH) in ipv6header_mt6() 79 switch (nexthdr) { in ipv6header_mt6() 99 nexthdr = hp->nexthdr; in ipv6header_mt6() 106 if (nexthdr != NEXTHDR_NONE && nexthdr != NEXTHDR_ESP) in ipv6header_mt6()
|
A D | nf_conntrack_reasm.c | 390 u8 nexthdr = ipv6_hdr(skb)->nexthdr; in find_prev_fhdr() local 392 u8 prev_nhoff = netoff + offsetof(struct ipv6hdr, nexthdr); in find_prev_fhdr() 397 while (nexthdr != NEXTHDR_FRAGMENT) { in find_prev_fhdr() 401 if (!ipv6_ext_hdr(nexthdr)) { in find_prev_fhdr() 404 if (nexthdr == NEXTHDR_NONE) { in find_prev_fhdr() 414 if (nexthdr == NEXTHDR_AUTH) in find_prev_fhdr() 419 prevhdr = nexthdr; in find_prev_fhdr() 422 nexthdr = hdr.nexthdr; in find_prev_fhdr() 440 u8 nexthdr = NEXTHDR_FRAGMENT; in nf_ct_frag6_gather() local 459 if (ipv6frag_thdr_truncated(skb, fhoff, &nexthdr)) { in nf_ct_frag6_gather()
|
/linux/samples/bpf/ |
A D | parse_varlen.c | 83 uint64_t nexthdr; in parse_ipv6() local 89 nexthdr = ip6h->nexthdr; in parse_ipv6() 91 if (nexthdr == IPPROTO_IPIP) { in parse_ipv6() 96 nexthdr = iph->protocol; in parse_ipv6() 97 } else if (nexthdr == IPPROTO_IPV6) { in parse_ipv6() 102 nexthdr = ip6h->nexthdr; in parse_ipv6() 105 if (nexthdr == IPPROTO_TCP) in parse_ipv6() 107 else if (nexthdr == IPPROTO_UDP) in parse_ipv6()
|
/linux/include/linux/ |
A D | netfilter_ipv6.h | 15 nf_ip6_ext_hdr(u8 nexthdr) in nf_ip6_ext_hdr() argument 16 { return (nexthdr == IPPROTO_HOPOPTS) || in nf_ip6_ext_hdr() 17 (nexthdr == IPPROTO_ROUTING) || in nf_ip6_ext_hdr() 18 (nexthdr == IPPROTO_FRAGMENT) || in nf_ip6_ext_hdr() 19 (nexthdr == IPPROTO_ESP) || in nf_ip6_ext_hdr() 20 (nexthdr == IPPROTO_AH) || in nf_ip6_ext_hdr() 21 (nexthdr == IPPROTO_NONE) || in nf_ip6_ext_hdr() 22 (nexthdr == IPPROTO_DSTOPTS); in nf_ip6_ext_hdr()
|
/linux/net/6lowpan/ |
A D | nhc.c | 100 nhc = lowpan_nexthdr_nhcs[hdr->nexthdr]; in lowpan_nhc_check_compression() 117 nhc = lowpan_nexthdr_nhcs[hdr->nexthdr]; in lowpan_nhc_do_compression() 182 hdr->nexthdr = nhc->nexthdr; in lowpan_nhc_do_uncompression() 207 if (lowpan_nexthdr_nhcs[nhc->nexthdr]) { in lowpan_nhc_add() 216 lowpan_nexthdr_nhcs[nhc->nexthdr] = nhc; in lowpan_nhc_add() 228 lowpan_nexthdr_nhcs[nhc->nexthdr] = NULL; in lowpan_nhc_del()
|
A D | nhc.h | 31 .nexthdr = _nexthdr, \ 70 const u8 nexthdr; member 86 struct lowpan_nhc *lowpan_nhc_by_nexthdr(u8 nexthdr);
|
/linux/net/xfrm/ |
A D | xfrm_input.c | 144 switch (nexthdr) { in xfrm_parse_spi() 194 XFRM_MODE_SKB_CB(skb)->protocol = ph->nexthdr; in xfrm4_remove_beet_encap() 533 if (xfrm_parse_spi(skb, nexthdr, &spi, &seq)) { in xfrm_input() 640 nexthdr = x->type_offload->input_tail(x, skb); in xfrm_input() 642 nexthdr = x->type->input(x, skb); in xfrm_input() 644 if (nexthdr == -EINPROGRESS) in xfrm_input() 650 if (nexthdr < 0) { in xfrm_input() 651 if (nexthdr == -EBADMSG) { in xfrm_input() 675 XFRM_MODE_SKB_CB(skb)->protocol = nexthdr; in xfrm_input() 704 err = xfrm_parse_spi(skb, nexthdr, &spi, &seq); in xfrm_input() [all …]
|
A D | xfrm_output.c | 89 *nexthdr = &ipv6_hdr(skb)->nexthdr; in mip6_rthdr_offset() 94 switch (**nexthdr) { in mip6_rthdr_offset() 133 *nexthdr = &exthdr->nexthdr; in mip6_rthdr_offset() 256 ph->nexthdr = top_iph->protocol; in xfrm4_beet_encap_add() 330 offsetof(struct ipv6hdr, nexthdr); in xfrm6_tunnel_encap_add() 338 top_iph->nexthdr = xfrm_af2proto(skb_dst(skb)->ops->family); in xfrm6_tunnel_encap_add() 369 offsetof(struct ipv6hdr, nexthdr); in xfrm6_beet_encap_add() 382 ph->nexthdr = top_iph->nexthdr; in xfrm6_beet_encap_add() 386 top_iph->nexthdr = IPPROTO_BEETPH; in xfrm6_beet_encap_add() 673 xo->inner_ipproto = inner_ipv6_hdr(skb)->nexthdr; in xfrm_get_inner_ipproto() [all …]
|
/linux/net/netfilter/ipset/ |
A D | ip_set_getport.c | 136 u8 nexthdr; in ip_set_get_ip6_port() local 139 nexthdr = ipv6_hdr(skb)->nexthdr; in ip_set_get_ip6_port() 142 sizeof(struct ipv6hdr), &nexthdr, in ip_set_get_ip6_port() 147 return get_port(skb, nexthdr, protoff, src, port, proto); in ip_set_get_ip6_port()
|
/linux/net/netfilter/ |
A D | xt_AUDIT.c | 50 u8 nexthdr; in audit_ip6() local 57 nexthdr = ih->nexthdr; in audit_ip6() 58 ipv6_skip_exthdr(skb, skb_network_offset(skb) + sizeof(_ip6h), &nexthdr, &frag_off); in audit_ip6() 61 &ih->saddr, &ih->daddr, nexthdr); in audit_ip6()
|
A D | xt_TCPOPTSTRIP.c | 100 u_int8_t nexthdr; in tcpoptstrip_tg6() local 103 nexthdr = ipv6h->nexthdr; in tcpoptstrip_tg6() 104 tcphoff = ipv6_skip_exthdr(skb, sizeof(*ipv6h), &nexthdr, &frag_off); in tcpoptstrip_tg6()
|
A D | xt_HMARK.c | 172 int nexthdr; in hmark_pkt_set_htuple_ipv6() local 175 nexthdr = ipv6_find_hdr(skb, &nhoff, -1, &fragoff, &flag); in hmark_pkt_set_htuple_ipv6() 176 if (nexthdr < 0) in hmark_pkt_set_htuple_ipv6() 179 if ((flag & IP6_FH_F_FRAG) || (nexthdr != IPPROTO_ICMPV6)) in hmark_pkt_set_htuple_ipv6() 188 nexthdr = ipv6_find_hdr(skb, &nhoff, -1, &fragoff, &flag); in hmark_pkt_set_htuple_ipv6() 189 if (nexthdr < 0) in hmark_pkt_set_htuple_ipv6() 199 t->proto = nexthdr; in hmark_pkt_set_htuple_ipv6()
|
/linux/tools/testing/selftests/bpf/progs/ |
A D | bpf_flow.c | 53 __u8 nexthdr; member 241 static __always_inline int parse_ipv6_proto(struct __sk_buff *skb, __u8 nexthdr) in parse_ipv6_proto() argument 245 switch (nexthdr) { in parse_ipv6_proto() 254 return parse_ip_proto(skb, nexthdr); in parse_ipv6_proto() 322 keys->ip_proto = ip6h->nexthdr; in PROG() 328 return parse_ipv6_proto(skb, ip6h->nexthdr); in PROG() 344 keys->ip_proto = ip6h->nexthdr; in PROG() 346 return parse_ipv6_proto(skb, ip6h->nexthdr); in PROG() 360 keys->ip_proto = fragh->nexthdr; in PROG() 374 return parse_ipv6_proto(skb, fragh->nexthdr); in PROG()
|
/linux/net/bridge/netfilter/ |
A D | ebt_log.c | 118 uint8_t nexthdr; in ebt_log_packet() local 128 &ih->saddr, &ih->daddr, ih->priority, ih->nexthdr); in ebt_log_packet() 129 nexthdr = ih->nexthdr; in ebt_log_packet() 130 offset_ph = ipv6_skip_exthdr(skb, sizeof(_iph), &nexthdr, &frag_off); in ebt_log_packet() 133 print_ports(skb, nexthdr, offset_ph); in ebt_log_packet()
|
A D | ebt_ip6.c | 63 uint8_t nexthdr = ih6->nexthdr; in ebt_ip6_mt() local 67 offset_ph = ipv6_skip_exthdr(skb, sizeof(_ip6h), &nexthdr, &frag_off); in ebt_ip6_mt() 70 if (NF_INVF(info, EBT_IP6_PROTO, info->protocol != nexthdr)) in ebt_ip6_mt()
|
/linux/drivers/net/ethernet/qualcomm/rmnet/ |
A D | rmnet_map_data.c | 121 csum_field = rmnet_map_get_csum_field(ip6h->nexthdr, txporthdr); in rmnet_map_ipv6_dl_csum_trailer() 138 ip6h->nexthdr, 0); in rmnet_map_ipv6_dl_csum_trailer() 208 if (ip6h->nexthdr == IPPROTO_TCP || ip6h->nexthdr == IPPROTO_UDP) { in rmnet_map_complement_ipv6_txporthdr_csum_field() 209 csum = (u16 *)rmnet_map_get_csum_field(ip6h->nexthdr, txphdr); in rmnet_map_complement_ipv6_txporthdr_csum_field() 222 if (ipv6hdr->nexthdr == IPPROTO_UDP) in rmnet_map_ipv6_ul_csum_header() 269 proto = ((struct ipv6hdr *)iph)->nexthdr; in rmnet_map_v5_checksum_uplink_packet()
|