History

objtool/klp: Only enable --checksum when needed

With CONFIG_KLP_BUILD enabled, checksums are only needed during a klp-build run. There's no need to enable them for normal kernel builds. This also has the benefit of softening the xxhash dependency.

Josh Poimboeuf committed 1 year ago

Commit 20920071 parent ee0b48f3 files · +5 −2Browse files

Showing the changes to scripts/livepatch (1 of 3 files). Show all

Unified · Split

scripts/livepatch/klp-build+4−0
@@ -489,8 +489,11 @@ clean_kernel() { · 488 unmodified lines
489 489
490build_kernel() {490build_kernel() {
491 local log="$TMP_DIR/build.log"491 local log="$TMP_DIR/build.log"
492 local objtool_args=()
492 local cmd=()493 local cmd=()
493 494
495 objtool_args=("--checksum")
496
494 cmd=("make")497 cmd=("make")
495 498
496 # When a patch to a kernel module references a newly created unexported499 # When a patch to a kernel module references a newly created unexported
@@ -513,6 +516,7 @@ build_kernel() { · 16 unmodified lines
513 cmd+=("$VERBOSE")516 cmd+=("$VERBOSE")
514 cmd+=("-j$JOBS")517 cmd+=("-j$JOBS")
515 cmd+=("KCFLAGS=-ffunction-sections -fdata-sections")518 cmd+=("KCFLAGS=-ffunction-sections -fdata-sections")
519 cmd+=("OBJTOOL_ARGS=${objtool_args[*]}")
516 cmd+=("vmlinux")520 cmd+=("vmlinux")
517 cmd+=("modules")521 cmd+=("modules")
518 522

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t