/samples/bpf/ |
D | parse_varlen.c | 22 static int tcp(void *data, uint64_t tp_off, void *data_end) in tcp() argument 26 if (tcp + 1 > data_end) in tcp() 33 static int udp(void *data, uint64_t tp_off, void *data_end) in udp() argument 37 if (udp + 1 > data_end) in udp() 51 static int parse_ipv4(void *data, uint64_t nh_off, void *data_end) in parse_ipv4() argument 57 if (iph + 1 > data_end) in parse_ipv4() 66 if (iph + 1 > data_end) in parse_ipv4() 72 return tcp(data, nh_off + ihl_len, data_end); in parse_ipv4() 74 return udp(data, nh_off + ihl_len, data_end); in parse_ipv4() 78 static int parse_ipv6(void *data, uint64_t nh_off, void *data_end) in parse_ipv6() argument [all …]
|
D | xdp1_kern.c | 24 static int parse_ipv4(void *data, u64 nh_off, void *data_end) in parse_ipv4() argument 28 if (iph + 1 > data_end) in parse_ipv4() 33 static int parse_ipv6(void *data, u64 nh_off, void *data_end) in parse_ipv6() argument 37 if (ip6h + 1 > data_end) in parse_ipv6() 45 void *data_end = (void *)(long)ctx->data_end; in xdp_prog1() local 55 if (data + nh_off > data_end) in xdp_prog1() 65 if (data + nh_off > data_end) in xdp_prog1() 74 if (data + nh_off > data_end) in xdp_prog1() 80 ipproto = parse_ipv4(data, nh_off, data_end); in xdp_prog1() 82 ipproto = parse_ipv6(data, nh_off, data_end); in xdp_prog1()
|
D | xdp_tx_iptunnel_kern.c | 45 static __always_inline int get_dport(void *trans_data, void *data_end, in get_dport() argument 54 if (th + 1 > data_end) in get_dport() 59 if (uh + 1 > data_end) in get_dport() 79 void *data_end = (void *)(long)xdp->data_end; in handle_ipv4() local 92 if (iph + 1 > data_end) in handle_ipv4() 95 dport = get_dport(iph + 1, data_end, iph->protocol); in handle_ipv4() 116 data_end = (void *)(long)xdp->data_end; in handle_ipv4() 122 if (new_eth + 1 > data_end || in handle_ipv4() 123 old_eth + 1 > data_end || in handle_ipv4() 124 iph + 1 > data_end) in handle_ipv4() [all …]
|
D | xdp2_kern.c | 40 static int parse_ipv4(void *data, u64 nh_off, void *data_end) in parse_ipv4() argument 44 if (iph + 1 > data_end) in parse_ipv4() 49 static int parse_ipv6(void *data, u64 nh_off, void *data_end) in parse_ipv6() argument 53 if (ip6h + 1 > data_end) in parse_ipv6() 61 void *data_end = (void *)(long)ctx->data_end; in xdp_prog1() local 71 if (data + nh_off > data_end) in xdp_prog1() 81 if (data + nh_off > data_end) in xdp_prog1() 90 if (data + nh_off > data_end) in xdp_prog1() 96 ipproto = parse_ipv4(data, nh_off, data_end); in xdp_prog1() 98 ipproto = parse_ipv6(data, nh_off, data_end); in xdp_prog1()
|
D | tc_l2_redirect_kern.c | 64 void *data_end = (void *)(long)skb->data_end; in _l2_to_iptun_ingress_forward() local 69 if (data + sizeof(*eth) > data_end) in _l2_to_iptun_ingress_forward() 80 if (data + sizeof(*eth) + sizeof(*iph) > data_end) in _l2_to_iptun_ingress_forward() 93 if (data + sizeof(*eth) + sizeof(*ip6h) > data_end) in _l2_to_iptun_ingress_forward() 115 void *data_end = (void *)(long)skb->data_end; in _l2_to_iptun_ingress_redirect() local 120 if (data + sizeof(*eth) > data_end) in _l2_to_iptun_ingress_redirect() 132 if (data + sizeof(*eth) + sizeof(*iph) > data_end) in _l2_to_iptun_ingress_redirect() 156 void *data_end = (void *)(long)skb->data_end; in _l2_to_ip6tun_ingress_redirect() local 159 if (data + sizeof(*eth) > data_end) in _l2_to_ip6tun_ingress_redirect() 170 if (data + sizeof(*eth) + sizeof(*iph) > data_end) in _l2_to_ip6tun_ingress_redirect() [all …]
|
D | xdp_redirect_cpu_kern.c | 115 bool parse_eth(struct ethhdr *eth, void *data_end, in parse_eth() argument 122 if ((void *)eth + offset > data_end) in parse_eth() 137 if ((void *)eth + offset > data_end) in parse_eth() 147 if ((void *)eth + offset > data_end) in parse_eth() 160 void *data_end = (void *)(long)ctx->data_end; in get_dest_port_ipv4_udp() local 166 if (iph + 1 > data_end) in get_dest_port_ipv4_udp() 172 if (udph + 1 > data_end) in get_dest_port_ipv4_udp() 182 void *data_end = (void *)(long)ctx->data_end; in get_proto_ipv4() local 186 if (iph + 1 > data_end) in get_proto_ipv4() 194 void *data_end = (void *)(long)ctx->data_end; in get_proto_ipv6() local [all …]
|
D | xdp_sample_pkts_kern.c | 18 void *data_end = (void *)(long)ctx->data_end; in xdp_sample_prog() local 27 if (data < data_end) { in xdp_sample_prog() 43 metadata.pkt_len = (u16)(data_end - data); in xdp_sample_prog()
|
D | xdp_adjust_tail_kern.c | 77 void *data_end = (void *)(long)xdp->data_end; in send_icmp4_too_big() local 79 if (data + (ICMP_TOOBIG_SIZE + headroom) > data_end) in send_icmp4_too_big() 122 void *data_end = (void *)(long)xdp->data_end; in handle_ipv4() local 124 int pckt_size = data_end - data; in handle_ipv4() 139 void *data_end = (void *)(long)xdp->data_end; in _xdp_icmp() local 144 if (eth + 1 > data_end) in _xdp_icmp()
|
D | parse_simple.c | 33 void *data_end = (void *)(long)skb->data_end; in handle_ingress() local 36 if (data + sizeof(*eth) + sizeof(*iph) + sizeof(*udp) > data_end) in handle_ingress()
|
D | xdp2skb_meta_kern.c | 35 void *data, *data_end; in _xdp_mark() local 66 void *data_end = (void *)(unsigned long)ctx->data_end; in _tc_mark() local
|
D | xdp_router_ipv4_kern.c | 96 static inline int parse_ipv4(void *data, u64 nh_off, void *data_end, in parse_ipv4() argument 101 if (iph + 1 > data_end) in parse_ipv4() 111 void *data_end = (void *)(long)ctx->data_end; in xdp_router_ipv4_prog() local 124 if (data + nh_off > data_end) in xdp_router_ipv4_prog() 134 if (data + nh_off > data_end) in xdp_router_ipv4_prog() 144 ipproto = parse_ipv4(data, nh_off, data_end, &src_ip, &dest_ip); in xdp_router_ipv4_prog()
|
D | test_cgrp2_tc_kern.c | 47 void *data_end = (void *)(long)skb->data_end; in handle_egress() local 53 if (data + sizeof(*eth) + sizeof(*ip6h) > data_end) in handle_egress()
|
D | xdp_redirect_map_kern.c | 58 void *data_end = (void *)(long)ctx->data_end; in xdp_redirect_map_prog() local 68 if (data + nh_off > data_end) in xdp_redirect_map_prog()
|
D | xdp_redirect_kern.c | 58 void *data_end = (void *)(long)ctx->data_end; in xdp_redirect_prog() local 68 if (data + nh_off > data_end) in xdp_redirect_prog()
|
D | xdp_fwd_kern.c | 45 void *data_end = (void *)(long)ctx->data_end; in xdp_fwd_flags() local 56 if (data + nh_off > data_end) in xdp_fwd_flags() 65 if (iph + 1 > data_end) in xdp_fwd_flags() 84 if (ip6h + 1 > data_end) in xdp_fwd_flags()
|
D | xdp_rxq_info_kern.c | 77 void *data_end = (void *)(long)ctx->data_end; in xdp_prognum0() local 123 if (eth + 1 > data_end) in xdp_prognum0()
|
D | test_lwt_bpf.c | 71 void *data_end = (void *)(long)skb->data_end; in do_test_data() local 74 if (data + sizeof(*iph) > data_end) { in do_test_data()
|