From: Zheng Yejian Date: Thu, 14 Sep 2023 07:26:44 +0000 (+0800) Subject: livepatch: Fix missing newline character in klp_resolve_symbols() X-Git-Tag: v6.6.7~1194 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fe998f4c3291a54e2c06901e73655d210a78db0a;p=platform%2Fkernel%2Flinux-starfive.git livepatch: Fix missing newline character in klp_resolve_symbols() [ Upstream commit 67e18e132f0fd738f8c8cac3aa1420312073f795 ] Without the newline character, the log may not be printed immediately after the error occurs. Fixes: ca376a937486 ("livepatch: Prevent module-specific KLP rela sections from referencing vmlinux symbols") Signed-off-by: Zheng Yejian Reviewed-by: Petr Mladek Signed-off-by: Petr Mladek Link: https://lore.kernel.org/r/20230914072644.4098857-1-zhengyejian1@huawei.com Signed-off-by: Sasha Levin --- diff --git a/kernel/livepatch/core.c b/kernel/livepatch/core.c index 6132832..ecbc9b6 100644 --- a/kernel/livepatch/core.c +++ b/kernel/livepatch/core.c @@ -243,7 +243,7 @@ static int klp_resolve_symbols(Elf_Shdr *sechdrs, const char *strtab, * symbols are exported and normal relas can be used instead. */ if (!sec_vmlinux && sym_vmlinux) { - pr_err("invalid access to vmlinux symbol '%s' from module-specific livepatch relocation section", + pr_err("invalid access to vmlinux symbol '%s' from module-specific livepatch relocation section\n", sym_name); return -EINVAL; }