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

clang: loader: Allow user to override kernel version #1895

Merged
merged 1 commit into from
Jul 24, 2018

Conversation

joelagnel
Copy link
Contributor

BCC currently requires exactly matching headers. Sometimes this is quite
inconvenient especially if the kernel version is only very slightly
different such as updates in a stable kernel. This patch gives the user
the flexibility to override the the LINUX_VERSION_CODE provided in the
linux kernel headers, so that the eBPF program may load. We also print a
message when this is done, so that the user is warned about the override
happening and that results may be unpredictable.

Also updated the docs.

Signed-off-by: Joel Fernandes joel@joelfernandes.org

BCC currently requires exactly matching headers. Sometimes this is quite
inconvenient especially if the kernel version is only very slightly
different such as updates in a stable kernel. This patch gives the user
the flexibility to override the the LINUX_VERSION_CODE provided in the
linux kernel headers, so that the eBPF program may load. We also print a
message when this is done, so that the user is warned about the override
happening and that results may be unpredictable.

Also updated the docs.

Signed-off-by: Joel Fernandes <joel@joelfernandes.org>
@joelagnel
Copy link
Contributor Author

This same as the previous PR #1880 which got closed.

It has got LGTMs with minor nits corrected, all checks were passed in the old PR so safe to merge.

@yonghong-song
Copy link
Collaborator

[buildbot, ok to test]

@yonghong-song
Copy link
Collaborator

Thanks @joelagnel will merge once the test passed. The github won't allow to merge without passing tests.

@joelagnel
Copy link
Contributor Author

I understand, thanks!

@yonghong-song yonghong-song merged commit bfecc24 into iovisor:master Jul 24, 2018
jeromemarchand added a commit to jeromemarchand/bcc that referenced this pull request Feb 5, 2019
A few files that are obviously not executable have the exec bit set.
Most those files were created with faulty mode to begin with, but
src/cc/export/helpers.h and src/cc/frontends/clang/loader.cc have had
their exec bit (unintendedly I assume) set by commit bfecc24
("clang: loader: Allow user to override kernel version (iovisor#1895)").
yonghong-song pushed a commit that referenced this pull request Feb 5, 2019
A few files that are obviously not executable have the exec bit set.
Most those files were created with faulty mode to begin with, but
src/cc/export/helpers.h and src/cc/frontends/clang/loader.cc have had
their exec bit (unintendedly I assume) set by commit bfecc24
("clang: loader: Allow user to override kernel version (#1895)").
palexster pushed a commit to palexster/bcc that referenced this pull request Jul 7, 2019
A few files that are obviously not executable have the exec bit set.
Most those files were created with faulty mode to begin with, but
src/cc/export/helpers.h and src/cc/frontends/clang/loader.cc have had
their exec bit (unintendedly I assume) set by commit bfecc24
("clang: loader: Allow user to override kernel version (iovisor#1895)").
CrackerCat pushed a commit to CrackerCat/bcc that referenced this pull request Jul 31, 2024
BCC currently requires exactly matching headers. Sometimes this is quite
inconvenient especially if the kernel version is only very slightly
different such as updates in a stable kernel. This patch gives the user
the flexibility to override the the LINUX_VERSION_CODE provided in the
linux kernel headers, so that the eBPF program may load. We also print a
message when this is done, so that the user is warned about the override
happening and that results may be unpredictable.

Also updated the docs.

Signed-off-by: Joel Fernandes <joel@joelfernandes.org>
CrackerCat pushed a commit to CrackerCat/bcc that referenced this pull request Jul 31, 2024
A few files that are obviously not executable have the exec bit set.
Most those files were created with faulty mode to begin with, but
src/cc/export/helpers.h and src/cc/frontends/clang/loader.cc have had
their exec bit (unintendedly I assume) set by commit bfecc24
("clang: loader: Allow user to override kernel version (iovisor#1895)").
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants