Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pahole cannot generate BTF from SLES 15 kernels #64

Open
brycekahle opened this issue Jan 31, 2023 · 5 comments
Open

pahole cannot generate BTF from SLES 15 kernels #64

brycekahle opened this issue Jan 31, 2023 · 5 comments

Comments

@brycekahle
Copy link
Collaborator

brycekahle commented Jan 31, 2023

SP4 doesn't need it because it has BTF embedded, but at least SP1, SP2, and SP3 are affected. See acmel/dwarves#10

You will see no output from pahole --btf-encode-detached.

Even simple queries fail:

$ pahole -C task_struct vmlinux-5.14.21-150400.22.1-default
WARNING: DW_TAG_partial_unit used, some types will not be considered!
         Probably this was optimized using a tool like 'dwz'
         A future version of pahole will support this.
pahole: type 'task_struct' not found

Even objdump doesn't understand it

$ objdump --dwarf=pubtypes vmlinux-5.14.21-150400.22.1-default

vmlinux-5.14.21-150400.22.1-default:     file format elf64-x86-64
@brycekahle
Copy link
Collaborator Author

There is a branch of dwarves that seems to work: https://github.com/acmel/dwarves/tree/alt_dwarf

@rafaeldtinoco
Copy link
Contributor

I'm following acmel/dwarves#10 (comment), feel free to propose a new pahole static binary into tools/bin/arch directory if you think it is worth it (now that we will need a specific version, might be worth).

@brycekahle
Copy link
Collaborator Author

After further investigation, the problem is more complicated. It works with SP3, but doesn't work with 15 SP1 or SP2.

@brycekahle
Copy link
Collaborator Author

brycekahle commented Feb 8, 2023

We can definitely explore including a static binary though, that would simplify setup on some distros.

@rafaeldtinoco
Copy link
Contributor

Latest pahole being installed in Ubuntus:

#95

from the repo. TODO: make it agnostic (through a docker image building both bpftool and pahole ?) and then check if this issue is already fixed with the version being pointed by the pahole submodule.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants