We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6af0dad commit 517017eCopy full SHA for 517017e
tools/testing/selftests/bpf/progs/test_xdp_pull_data.c
@@ -2,6 +2,7 @@
2
3
#include "vmlinux.h"
4
#include <bpf/bpf_helpers.h>
5
+#include <bpf/bpf_core_read.h>
6
7
int xdpf_sz;
8
int sinfo_sz;
@@ -13,7 +14,7 @@ int pull_len;
13
14
SEC("xdp.frags")
15
int xdp_find_sizes(struct xdp_md *ctx)
16
{
- xdpf_sz = sizeof(struct xdp_frame);
17
+ xdpf_sz = bpf_core_type_size(struct xdp_frame);
18
sinfo_sz = __PAGE_SIZE - XDP_PACKET_HEADROOM -
19
(ctx->data_end - ctx->data);
20
0 commit comments