DLPX-94011 simplify kernel build and exclusion of dkms modules#346
Merged
sebroy merged 1 commit intoApr 23, 2025
Merged
Conversation
64860ce to
6bd1d0c
Compare
prakashsurya
approved these changes
Apr 22, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We currently use a mix of methods to exclude dkms (out of tree) modules from
our kernel builds. In each of the kernel repos, we have removed all of the
lines from
debian.master/dkms-versionsexcept for the line responsible forbuilding zfs out of tree. For preventing the zfs build, there is a
do_zfs=falsedebian/rulesargument set in linux-pkg’sdefault-package-config.shscript which works for that package.It would be beneficial to restore the
debian.master/dkms-versionsfiles totheir original contents, as these are a source of regular merge conflicts.
Instead, we should use the
debian/rulesargument method from linux-pkg, whichcan be shared across all linux kernel repos.
Some investigation reveals that there are two ways of excluding a dkms module
from the kernel build via a debian/rules arg:
do_<module>=false(this is how we exclude zfs, by settingdo_zfs=false)dkms_exclude=<module list>argument (thisis how we were excluding the build of
v4l2loopbackbefore that line wasremoved entirely from
dkms-versions)Using method 2 above is more compact, as all modules we need to exclude can be
included in that one argument. Setting this in linux-pkg will allow us to
restore
dkms-versionsin all of our linux-kernel-* repos and eliminate thatsource of merge conflicts.
Once this linux-pkg PR lands, I'll move forward with simplifying our linux-kernel-*
repos.
A secondary problem I noticed in our kernel builds (and this is a problem on develop
as well as on os-upgrade) is that various calls to
debian/rulesare failing becausethe gawk command isn't installed. This can be seen in the console output of our various
build-package jobs for the kernel repos. I've fixed that while in here.
Testing
I'm manually running a kernel build of linux-kernel-generic on an os-upgrade build server
with these linux-pkg changes in place.