[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210221174930.27324-2-nramas@linux.microsoft.com>
Date: Sun, 21 Feb 2021 09:49:18 -0800
From: Lakshmi Ramasubramanian <nramas@...ux.microsoft.com>
To: zohar@...ux.ibm.com, bauerman@...ux.ibm.com, robh@...nel.org,
takahiro.akashi@...aro.org, gregkh@...uxfoundation.org,
will@...nel.org, joe@...ches.com, catalin.marinas@....com,
mpe@...erman.id.au, sfr@...b.auug.org.au
Cc: james.morse@....com, sashal@...nel.org, benh@...nel.crashing.org,
paulus@...ba.org, frowand.list@...il.com,
vincenzo.frascino@....com, mark.rutland@....com,
dmitry.kasatkin@...il.com, jmorris@...ei.org, serge@...lyn.com,
pasha.tatashin@...een.com, allison@...utok.net,
masahiroy@...nel.org, mbrugger@...e.com, hsinyi@...omium.org,
tao.li@...o.com, christophe.leroy@....fr,
prsriva@...ux.microsoft.com, balajib@...ux.microsoft.com,
linux-integrity@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, devicetree@...r.kernel.org,
linuxppc-dev@...ts.ozlabs.org
Subject: [PATCH v19 01/13] kexec: Move ELF fields to struct kimage
ELF related fields elf_headers, elf_headers_sz, and elf_load_addr are
defined in architecture specific 'struct kimage_arch' for x86, powerpc,
and arm64. The name of these fields are different in these
architectures that makes it hard to have a common code for setting up
the device tree for kexec system call.
Move the ELF fields to 'struct kimage' defined in include/linux/kexec.h
so common code can use it.
Signed-off-by: Lakshmi Ramasubramanian <nramas@...ux.microsoft.com>
Suggested-by: Rob Herring <robh@...nel.org>
Fixes: 33488dc4d61f ("of: Add a common kexec FDT setup function")
Reported-by: kernel test robot <lkp@...el.com>
---
include/linux/kexec.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/include/linux/kexec.h b/include/linux/kexec.h
index 5f61389f5f36..0208fe8f8e42 100644
--- a/include/linux/kexec.h
+++ b/include/linux/kexec.h
@@ -305,6 +305,11 @@ struct kimage {
/* Virtual address of IMA measurement buffer for kexec syscall */
void *ima_buffer;
#endif
+
+ /* Core ELF header buffer */
+ void *elf_headers;
+ unsigned long elf_headers_sz;
+ unsigned long elf_load_addr;
};
/* kexec interface functions */
--
2.30.0
Powered by blists - more mailing lists