I've just compiled BPF examples from kernel tools/testing/selftests/bpf
and tried to load as explained in http://cilium.readthedocs.io/en/v0.10/bpf/:
% tc filter add dev enp0s1 ingress bpf \
object-file ./net-next.git/tools/testing/selftests/bpf/sockmap_parse_prog.o \
section sk_skb1 verbose
Program section 'sk_skb1' not found in ELF file!
Error fetching program/map!
This happens on Ubuntu 16.04.3 LTS with kernel 4.4.0-98, llvm
and clang
of version 3.8 installed from packages, iproute2
is the latest from github.
I suspect I'm running into some toolchain/kernel version/features mismatch.
What am I doing wrong?