Skip to content

Conversation

@jameshilliard
Copy link
Contributor

This should be useable in bpftool v5.13 or newer based on:
torvalds/linux@d80b2fc

@yuwata yuwata added bpf meson good-to-merge/waiting-for-ci 👍 PR is good to merge, but CI hasn't passed at time of review. Please merge if you see CI has passed needs-rebase labels Jan 31, 2022
@yuwata
Copy link
Member

yuwata commented Jan 31, 2022

Please rebase.

This should be useable in bpftool v5.13 or newer based on:
torvalds/linux@d80b2fc
bpftool = find_program('bpftool',
'/usr/sbin/bpftool',
required : bpf_framework_required,
version : '>= 5.6.0')
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed this to the full 3 part version string since that seems to match the format output from bpftool:

$ ./bpftool --version
./bpftool v5.16.0-c446fdacb10d
features: libbpf_strict

@jameshilliard
Copy link
Contributor Author

rebased

Copy link
Member

@yuwata yuwata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@yuwata yuwata merged commit e3759ac into systemd:main Jan 31, 2022
@jameshilliard jameshilliard deleted the bpftool-strip branch January 31, 2022 18:25
Comment on lines +71 to +72
'g',
'o',

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'gen' and 'object' is probably better. It has nothing to do with -g and -o of llvm-strip, btw (pure coincidence).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I copied the style from the gen skeleton command here, should I change both?:

skel_h_cmd = [
bpftool,
'g',
's',
'@INPUT@'
]

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've changed these to full names in #22330.

'g',
'o',
'@OUTPUT@',
'@INPUT@'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is @input@ always a single file? bpftool gen object allows statically linking BPF application that consists of multiple .bpf.o objects, that's it's main purpose. Stripping out DWARF info is just a by product. So I'm wondering if ability to do multi-file BPF programs was added by this PR as well or it's purely about stripping out DWARF?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is @input@ always a single file?

Should be at the moment.

Stripping out DWARF info is just a by product. So I'm wondering if ability to do multi-file BPF programs was added by this PR as well or it's purely about stripping out DWARF?

I didn't make any changes for multi-file BPF program support.

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

Labels

bpf good-to-merge/waiting-for-ci 👍 PR is good to merge, but CI hasn't passed at time of review. Please merge if you see CI has passed meson

Development

Successfully merging this pull request may close these issues.

3 participants