====================================================================== BUILD LOG: pass/long/add-remove-file-git ====================================================================== Verdict: pass Exit code: 0 Kernel: 6.19.0+ Toolchain: Compiler: clang version 21.1.8 (Fedora 21.1.8-4.fc43) Linker: LLD 21.1.8 (compatible with GNU linkers) Assembler: Clang integrated assembler ====================================================================== FULL BUILD OUTPUT ====================================================================== --- klp-build stdout --- Validating patch(es) checking file Documentation/livepatch/api.rst checking file fs/proc/klp_test_header1.h checking file fs/proc/klp_test_header2.h checking file fs/proc/meminfo.c Hunk #2 succeeded at 41 with fuzz 2. checking file fs/proc/cmdline.c Hunk #1 succeeded at 6 with fuzz 1 (offset -1 lines). Fixing patch(es) Building patched kernel Copying patched object files Diffing objects vmlinux.o: changed function: cmdline_proc_show vmlinux.o: changed function: meminfo_proc_show Building patch module: livepatch-add-remove-file-git-generated.ko SUCCESS --- klp-build stderr --- warn: klp-build: /home/jolawren/Applications/cursor-cli/workspace/linux/tools/testing/selftests/klp-build/tests/current-tree/pass/long/add-remove-file-git/add-remove-file-git-generated.patch applied with drift --- diff.log --- vmlinux.o: changed function: cmdline_proc_show vmlinux.o: changed function: meminfo_proc_show ====================================================================== BUILD VERIFICATION ====================================================================== klp-build exit code is 0 Module exists: livepatch-add-remove-file-git-generated.ko verify_diff_log_contains('changed function: meminfo_proc_show'): OK verify_diff_log_contains('changed function: cmdline_proc_show'): OK ELF Analysis: klp_object[0]: .name = NULL (vmlinux) .callbacks = {0} VERIFIED: klp_object.name = NULL (vmlinux) klp_func[0]: .old_name = "cmdline_proc_show" [-> .rodata+0x360] .new_func -> cmdline_proc_show .old_sympos = 0 klp_func[1]: .old_name = "meminfo_proc_show" [-> .rodata+0x372] .new_func -> meminfo_proc_show .old_sympos = 0 VERIFIED: klp_func.old_name = 'meminfo_proc_show' VERIFIED: klp_func.new_func -> meminfo_proc_show VERIFIED: klp_func.old_name = 'cmdline_proc_show' VERIFIED: klp_func.new_func -> cmdline_proc_show ====================================================================== TEST PATCH(ES) ====================================================================== --- Patch: add-remove-file-git-generated.patch --- From: Test Author Subject: [PATCH] Add/remove files and update proc (git format) Add new headers and meminfo change; remove one doc and update cmdline. diff --git a/Documentation/livepatch/api.rst b/Documentation/livepatch/api.rst deleted file mode 100644 index 78944b63d74b..000000000000 --- a/Documentation/livepatch/api.rst +++ /dev/null @@ -1,30 +0,0 @@ -.. SPDX-License-Identifier: GPL-2.0 - -================= -Livepatching APIs -================= - -Livepatch Enablement -==================== - -.. kernel-doc:: kernel/livepatch/core.c - :export: - - -Shadow Variables -================ - -.. kernel-doc:: kernel/livepatch/shadow.c - :export: - -System State Changes -==================== - -.. kernel-doc:: kernel/livepatch/state.c - :export: - -Object Types -============ - -.. kernel-doc:: include/linux/livepatch.h - :identifiers: klp_patch klp_object klp_func klp_callbacks klp_state diff --git a/fs/proc/klp_test_header1.h b/fs/proc/klp_test_header1.h new file mode 100644 index 000000000000..9f1204d43157 --- /dev/null +++ b/fs/proc/klp_test_header1.h @@ -0,0 +1,6 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef _KLP_TEST_HEADER1_H +#define _KLP_TEST_HEADER1_H + +#define KLP_TEST_MARKER1 "klp-build-test: header1 included" +#endif diff --git a/fs/proc/klp_test_header2.h b/fs/proc/klp_test_header2.h new file mode 100644 index 000000000000..a92cb184b0d6 --- /dev/null +++ b/fs/proc/klp_test_header2.h @@ -0,0 +1,6 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef _KLP_TEST_HEADER2_H +#define _KLP_TEST_HEADER2_H + +#define KLP_TEST_MARKER2 "klp-build-test: header2 included" +#endif diff --git a/fs/proc/meminfo.c b/fs/proc/meminfo.c index a458f1e112fd..fc5ca18b7fe9 100644 --- a/fs/proc/meminfo.c +++ b/fs/proc/meminfo.c @@ -18,6 +18,8 @@ #include #endif #include +#include "klp_test_header1.h" +#include "klp_test_header2.h" #include #include "internal.h" @@ -39,6 +41,8 @@ static int meminfo_proc_show(struct seq_file *m, void *v) long available; unsigned long pages[NR_LRU_LISTS]; unsigned long sreclaimable, sunreclaim; int lru; + pr_info(KLP_TEST_MARKER1 "\n"); + pr_info(KLP_TEST_MARKER2 "\n"); si_meminfo(&i); diff --git a/fs/proc/cmdline.c b/fs/proc/cmdline.c index a6f76121955f..addbdf01415c 100644 --- a/fs/proc/cmdline.c +++ b/fs/proc/cmdline.c @@ -7,7 +7,8 @@ static int cmdline_proc_show(struct seq_file *m, void *v) { + pr_info("klp-build-test: add-remove-file-git test\n"); seq_puts(m, saved_command_line); seq_putc(m, '\n'); return 0; }