-
Notifications
You must be signed in to change notification settings - Fork 174
fix(driver): fix driver Makefile for Linux 6.13 support #2301
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
Conversation
Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Welcome @m-pellizzer! It looks like this is your first PR to falcosecurity/libs 🎉 |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: m-pellizzer The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Perf diff from master - unit tests
Heap diff from master - unit tests
Heap diff from master - scap file
Benchmarks diff from master
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2301 +/- ##
=======================================
Coverage 77.17% 77.17%
=======================================
Files 224 224
Lines 30133 30133
Branches 4605 4605
=======================================
Hits 23256 23256
Misses 6877 6877
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
569aaed
to
8c82168
Compare
Thanks @FedeDP for the heads-up! I tested the driver in Ubuntu against 6.12 and 6.14. |
8c82168
to
00006b9
Compare
Hi. Please read all of #2277. Your fix does not work in general. In particular, look at #2277 (comment) |
I looked around a bit, and I'm thinking that maybe the final fix in #2277 might actually work in many more than just Debian systems. I looked around, and the |
Hello @dkogan. Thanks for the suggestion, I will test again my code and update the PR if needed. |
Thanks for checking. What does "on Ubuntu Plucky 6.14" mean? Where did
the kernel you're building against come from? Can you point me to the
exact package please?
Thanks.
|
In Linux 6.13 there has been a change regarding how kernel modules get built when using the M= option. In partiucular, when building a module (M=) the working directory changed from the kernel directory to the external module directory. See commit 13b25489b6f8bd kbuild: change working directory to external module directory with M=. This causes compile time errors when compiling the driver against kernels >= 6.13. This update requires changes in the driver's Makefile. The change keeps compatibility with previous kernels. Signed-off-by: Massimiliano Pellizzer <massimiliano.pellizzer@canonical.com>
00006b9
to
2f63a55
Compare
I tested the latest PR update against multiple kernels.
The driver compiles also from source without using the DKMS framework. Notice that 6.14-rc6, 6.13, 6.11 are mainline kernels, while 6.12 is the Ubuntu generic kernel. @dkogan can you please test also on your side and let me know if you get the same compile time errors mentioned in the issue? |
I Just triggered the CI! Thanks for looking into this. Hopefully @dkogan is able to test this too. |
I don't understand. Once again. Please read all of #2277. Your fix does not work in general. In particular, look at #2277 (comment) |
@dkogan Can you please provide a specific case in which this solution is not working? This would help me debug further the issue |
It does not work in Debian kernels, as noted in #2277. Linus presumably doesn't use a distro, and his
|
This is the result in debian unstable with kernel 6.12:
As you said |
OK. But then it doesn't work with Debian kernels. For those the patch in #2277 works in both old and new kernels. You can add another branch to your logic to cover those. But it really feels like there should be a better way. |
The kernel I used in the previous testing (6.12.17-1) it's from Debian archive. |
I think we're talking past each other. You tested 6.12 with The patch in #2277 works with both old and new Debian kernels, but you have observed it to fail with some others, and you're proposing a different patch to use Thanks |
@dkogan Thanks for explaining me the issue more in depth. |
Do you have evidence that the slightly different naming scheme is breaking it? The observations in #2277 don't agree: #2277 (comment)
If you live in a world where you build a kernel and install it on the build machine (what the person that made this breaking kernel change almost certainly does), then you only are looking at one architecture, and there's no duplication to think about. So they inadvertently broke it in the Debian case. |
Since #2329 was merged, we can close this one! |
@FedeDP: Closed this PR. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
In Linux 6.13 there has been a change regarding how kernel modules get built when using the M= option. In partiucular, when building a module (M=) the working directory changed from the kernel directory to the external module directory.
See commit 13b25489b6f8bd kbuild: change working directory to external module directory with M=.
This causes compile time errors when compiling the driver against kernels >= 6.13.
This update requires changes in the driver's Makefile.
Fixes #2277
/kind bug
/area driver-kmod