From: Torsten Duwe <duwe@suse.de>
Subject: Be prepared to enable ARM64 live patching during SLE15 lifetime
Patch-mainline: Never, kabi
References: FATE#322421
SLE15 might ship without live patching on ARM64;
however, it will eventually be enabled during its lifetime.
Given the experience with ppc64le, the biggest kABI breakage
results from a changing struct module, so include the 2 booleans
right from the start.
Signed-off-by: Torsten Duwe <duwe@suse.de>
--- a/include/linux/module.h
+++ b/include/linux/module.h
@@ -335,7 +335,7 @@ struct mod_kallsyms {
char *typetab;
};
-#ifdef CONFIG_LIVEPATCH
+#if defined(CONFIG_LIVEPATCH) || defined(__aarch64__)
struct klp_modinfo {
Elf_Ehdr hdr;
Elf_Shdr *sechdrs;
@@ -477,7 +477,7 @@ struct module {
unsigned long *ftrace_callsites;
#endif
-#ifdef CONFIG_LIVEPATCH
+#if defined(CONFIG_LIVEPATCH) || defined(__aarch64__)
bool klp; /* Is this a livepatch module? */
bool klp_alive;