Home
last modified time | relevance | path

Searched refs:iphdr_sz (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/tools/testing/selftests/bpf/progs/
H A Dtest_xdp_dynptr.c24 const size_t iphdr_sz = sizeof(struct iphdr); variable
79 __u8 eth_buffer[ethhdr_sz + iphdr_sz + ethhdr_sz]; in handle_ipv4()
80 __u8 iph_buffer_tcp[iphdr_sz + tcphdr_sz]; in handle_ipv4()
81 __u8 iph_buffer_udp[iphdr_sz + udphdr_sz]; in handle_ipv4()
98 if (ethhdr_sz + iphdr_sz + tcphdr_sz > xdp->data_end - xdp->data) in handle_ipv4()
121 if (bpf_xdp_adjust_head(xdp, 0 - (int)iphdr_sz)) in handle_ipv4()
138 iph->ihl = iphdr_sz >> 2; in handle_ipv4()
143 iph->tot_len = bpf_htons(payload_len + iphdr_sz); in handle_ipv4()
149 for (i = 0; i < iphdr_sz >> 1; i++) in handle_ipv4()
177 if (ethhdr_sz + iphdr_sz + tcphdr_sz > xdp->data_end - xdp->data) in handle_ipv6()