Can a tc prog understand and load the BTF section? #721
-
When I wrote a BTF loader by myself, I found that the prog types such as xdp and tracepoint can load the btf section very well, but the TC program always has errors when loading into the kernel. So I would like to ask if the TC program itself cannot support BTF? Thank you, looking forward to your reply |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Without more detail is it hard to tell the differences in your BTF loader. As attaching to XDP, to a tracepoint and TC (traffic control) is independent of loading a eBPF program and optional its BTF, I think there is a different problem. Taking a look at existing examples github.com/cilium/ebpf/examples/xdp for XDP or github.com/florianl/go-tc/example_gteq_1.16_test.go for TC the sequence of loading and attaching is following similar steps:
So to speak, eBPF prgrams of type |
Beta Was this translation helpful? Give feedback.
Without more detail is it hard to tell the differences in your BTF loader. As attaching to XDP, to a tracepoint and TC (traffic control) is independent of loading a eBPF program and optional its BTF, I think there is a different problem.
Taking a look at existing examples github.com/cilium/ebpf/examples/xdp for XDP or github.com/florianl/go-tc/example_gteq_1.16_test.go for TC the sequence of loading and attaching is following similar steps:
This is happening here for the XDP example and here for the TC example.
This is happening here for the XDP example and here for the TC example.
So to speak, eBPF prgrams of type
SchedCLS
that …