-
Notifications
You must be signed in to change notification settings - Fork 167
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
new(driver): kmod configure system #1452
new(driver): kmod configure system #1452
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SHIP IT!
LGTM label has been added. Git tree hash: 18648c12b53dcbaa17bcea074e904de7011b4ab1
|
/hold |
I opened a |
It would be great if you could add a configuration for the only driver testing issues we are seeing: https://falcosecurity.github.io/libs/matrix_X64/#centos-418-kmod_build EDIT: uh i missed it, there was already the config to fix it! (indeed, as we can see below, centos 4.18 is already fixed!) |
Also, i am running kernel-tests against this branch: https://github.com/falcosecurity/libs/actions/runs/7526616526, just to make sure everything is ok ;) |
x86_64 matrix:
|
Shouldn't this be already fixed given it is the same error as centos-4.18 (on master), and the latter is solved by this PR? fedora-5.17 kmod_buildMsg:
Err:
|
078b1f6
to
1b416f0
Compare
@FedeDP now it should work. Thanks for pointing me to https://falcosecurity.github.io/kernel-crawler/?arch=x86_64&target=fedora&search=5.17.5-300.fc36.x86_64 🙂 |
Update! Driverkit PR was just merged; we are running some tests and then a new driverkit release will be tagged. At that time, we will be free to proceed with this one and i'll ask you @deepskyblue86 for a rebase ;) |
Introduce a new mechanism for conditional build in the kernel module, documented in driver/README.configure.md Apply such mechanism to `ppm_access_ok`, easily detecting if `access_ok` is the old version with 3 parameters or the new one with just two. Signed-off-by: Angelo Puglisi <[email protected]>
- embellish the output with a '[configure]' prefix - show the make output of the configuration step (notice it will be squashed into a single line) Signed-off-by: Gerlando Falauto <[email protected]> Co-authored-by: Angelo Puglisi <[email protected]>
RHEL8.9 kernels (4.18.0) have an inconsistent behavior in that the first releases (up to ~500) do NOT include the backported change, which was however included from a certain point on. The previous implementation empirically (but wrongly) assumed that all RHEL8.9 kernels would have the patch, so the first ones would not compile. Now that we have a dynamic discovery mechanism, we can drop this assumption and leverage HAS_DEVNODE_ARG1_CONST. Notice how this includes a revert of: commit 977f946 Author: Gerlando Falauto <[email protected]> Date: Wed Aug 2 14:22:37 2023 +0200 fix(driver): fix build on RHEL 8.9 kernels Signed-off-by: Gerlando Falauto <[email protected]> Co-authored-by: Angelo Puglisi <[email protected]>
When installing a new kernel, dkms would build the module for it, but with KERNELDIR defined with `uname -r` the compilation will likely fail. Define it with the current kernel headers only when the makefile is used directly, and rely on the make current directory otherwise (coming from make -C ...). Signed-off-by: Angelo Puglisi <[email protected]>
Trust the kmod configure system for `ppm_devnode`, and drop PPM_RHEL_RELEASE_CODE checks. Fixes fedora-5.17 build, failing because of RHEL release version 9.99 Signed-off-by: Angelo Puglisi <[email protected]>
5ac59b8
to
3032f57
Compare
/milestone 0.15.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/approve
LGTM label has been added. Git tree hash: def53456f4e4ae4e82212318b5fb75b13fead664
|
/unhold |
@gnosek |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤩
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: deepskyblue86, FedeDP, gnosek The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What type of PR is this?
/kind feature
Any specific area of the project related to this PR?
/area driver-kmod
Does this PR require a change in the driver versions?
What this PR does / why we need it:
Introduce a new mechanism for conditional build in the kernel module, documented in driver/README.configure.md
Apply such mechanism to
ppm_access_ok
, easily detecting ifaccess_ok
is the old version with 3 parameters or the new one with just two.Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?: