Searched refs:ethhdr_sz (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/tools/testing/selftests/bpf/progs/ |
H A D | test_xdp_dynptr.c | 23 const size_t ethhdr_sz = sizeof(struct ethhdr); variable 79 __u8 eth_buffer[ethhdr_sz + iphdr_sz + ethhdr_sz]; in handle_ipv4() 98 if (ethhdr_sz + iphdr_sz + tcphdr_sz > xdp->data_end - xdp->data) in handle_ipv4() 99 iph = bpf_dynptr_slice(xdp_ptr, ethhdr_sz, iph_buffer_udp, sizeof(iph_buffer_udp)); in handle_ipv4() 101 iph = bpf_dynptr_slice(xdp_ptr, ethhdr_sz, iph_buffer_tcp, sizeof(iph_buffer_tcp)); in handle_ipv4() 161 __u8 eth_buffer[ethhdr_sz + ipv6hdr_sz + ethhdr_sz]; in handle_ipv6() 177 if (ethhdr_sz + iphdr_sz + tcphdr_sz > xdp->data_end - xdp->data) in handle_ipv6() 178 ip6h = bpf_dynptr_slice(xdp_ptr, ethhdr_sz, ip6h_buffer_udp, sizeof(ip6h_buffer_udp)); in handle_ipv6() 180 ip6h = bpf_dynptr_slice(xdp_ptr, ethhdr_sz, ip6h_buffer_tcp, sizeof(ip6h_buffer_tcp)); in handle_ipv6() 233 __u8 buffer[ethhdr_sz]; in _xdp_tx_iptunnel()
|