On Wed, Nov 6, 2019 at 5:47 PM Martin KaFai Lau <kafai@xxxxxx> wrote: > > Access the skb->cb[] in the kfree_skb test. > > Signed-off-by: Martin KaFai Lau <kafai@xxxxxx> > --- Acked-by: Andrii Nakryiko <andriin@xxxxxx> > .../selftests/bpf/prog_tests/kfree_skb.c | 54 +++++++++++++++---- > tools/testing/selftests/bpf/progs/kfree_skb.c | 25 +++++++-- > 2 files changed, 63 insertions(+), 16 deletions(-) > [...] > > + meta.ifindex = _(dev->ifindex); > + meta.cb8_0 = cb8[8]; > + meta.cb32_0 = cb32[2]; Have you tried doing it inside __builtin_preserve_access_index region? Does it fail because of extra allocations against meta? > + > bpf_probe_read_kernel(&pkt_type, sizeof(pkt_type), _(&skb->__pkt_type_offset)); > pkt_type &= 7; > [...]