On Fri, 2024-08-30 at 02:51 -0700, Tony Ambardar wrote: > The pahole master branch recently added support for "distilled BTF" based > on libbpf v1.5, but may add .BTF and .BTF.base sections with the wrong byte > order (e.g. on s390x BPF CI), which then lead to kernel Oops when loaded. > > Fix by updating libbpf's btf__distill_base() and btf_new_empty() to retain > the byte order of any source BTF objects when creating new ones. > > Reported-by: Song Liu > Reported-by: Eduard Zingerman > Suggested-by: Eduard Zingerman > Link: https://lore.kernel.org/bpf/6358db36c5f68b07873a0a5be2d062b1af5ea5f8.camel@gmail.com/ > Signed-off-by: Tony Ambardar > --- Acked-by: Eduard Zingerman But we also need a test for this. Like the one attached. Or Alan can share his test, which is much shorter but skips round trip to bytes and back. [...]