-
Notifications
You must be signed in to change notification settings - Fork 521
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1526 from bcressey/kernel-five-ten
add support for kernel 5.10
- Loading branch information
Showing
40 changed files
with
580 additions
and
139 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
File renamed without changes.
50 changes: 50 additions & 0 deletions
50
packages/kernel-5.10/1001-Makefile-add-prepare-target-for-external-modules.patch
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
From b6d859b7089dd68d3186f2a088823c322ad4852e Mon Sep 17 00:00:00 2001 | ||
From: Ben Cressey <bcressey@amazon.com> | ||
Date: Mon, 19 Apr 2021 18:46:04 +0000 | ||
Subject: [PATCH] Makefile: add prepare target for external modules | ||
|
||
We need to ensure that native versions of programs like `objtool` are | ||
built before trying to build out-of-tree modules, or else the build | ||
will fail. | ||
|
||
Unlike other distributions, we cannot include these programs in our | ||
kernel-devel archive, because we rely on cross-compilation: these are | ||
"host" programs and may not match the architecture of the target. | ||
|
||
Ideally, out-of-tree builds would run `make prepare` first, so that | ||
these programs could be compiled in the normal fashion. We ship all | ||
the files needed for this to work. However, this requirement is | ||
specific to our use case, and DKMS does not support it. | ||
|
||
Adding a minimal prepare target to the dependency graph causes the | ||
programs to be built automatically and improves compatibility with | ||
existing solutions. | ||
|
||
Signed-off-by: Ben Cressey <bcressey@amazon.com> | ||
--- | ||
Makefile | 9 +++++++++ | ||
1 file changed, 9 insertions(+) | ||
|
||
diff --git a/Makefile b/Makefile | ||
index 1d4a50ebe3b7..b9347d1e69e2 100644 | ||
--- a/Makefile | ||
+++ b/Makefile | ||
@@ -1719,6 +1719,15 @@ else # KBUILD_EXTMOD | ||
KBUILD_BUILTIN := | ||
KBUILD_MODULES := 1 | ||
|
||
+PHONY += modules_prepare | ||
+modules_prepare: $(objtool_target) | ||
+ $(Q)$(MAKE) $(build)=scripts/basic | ||
+ $(Q)$(MAKE) $(build)=scripts/dtc | ||
+ $(Q)$(MAKE) $(build)=scripts/mod | ||
+ $(Q)$(MAKE) $(build)=scripts | ||
+ | ||
+prepare: modules_prepare | ||
+ | ||
build-dirs := $(KBUILD_EXTMOD) | ||
PHONY += modules | ||
modules: $(MODORDER) | ||
-- | ||
2.21.3 | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
[package] | ||
name = "kernel-5_10" | ||
version = "0.1.0" | ||
edition = "2018" | ||
publish = false | ||
build = "build.rs" | ||
|
||
[package.metadata.build-package] | ||
package-name = "kernel-5.10" | ||
|
||
[lib] | ||
path = "pkg.rs" | ||
|
||
[[package.metadata.build-package.external-files]] | ||
# Use latest-srpm-url.sh to get this. | ||
url = "https://cdn.amazonlinux.com/blobstore/fa04b98fc067a4943beac60d0c2971e2fbef1a29faed4bac1c4096abe4ad4c12/kernel-5.10.29-27.126.amzn2.src.rpm" | ||
sha512 = "47341f4a1c13ba7e5ea72bad13fe689eefd22cc7547aea08a08fe47238b4a3fe1659786a406b84a1d1508143be20d9be2fae6fe3e7a6924bc85043bf61d4bfce" |
File renamed without changes.
File renamed without changes.
Oops, something went wrong.