[PATCH v3 4/7] kho: replace KHO FDT with kstate metadata
Rob Herring
robh at kernel.org
Wed Sep 10 09:50:10 PDT 2025
On Tue, Sep 09, 2025 at 10:14:39PM +0200, Andrey Ryabinin wrote:
> Store KSTATE physical address & size instead of FDT in kho_data.
> and initialize KSTATE from kho_populate().
> To be able to use FDT in parallel with KSTATE place FDT
> address&size into 'struct kho_fdt' and save/restore it using KSTATE.
>
> This finishes wiring KSTATE with KHO, making it fully functional.
>
> Signed-off-by: Andrey Ryabinin <arbn at yandex-team.com>
> ---
> arch/x86/include/uapi/asm/setup_data.h | 4 +-
> arch/x86/kernel/kexec-bzimage64.c | 6 +--
> arch/x86/kernel/setup.c | 3 +-
> drivers/of/fdt.c | 6 +--
> include/linux/kexec.h | 2 +-
> include/linux/kstate.h | 1 +
> kernel/liveupdate/kexec_handover.c | 60 +++++++++++++++++++++-----
> 7 files changed, 61 insertions(+), 21 deletions(-)
>
> diff --git a/arch/x86/include/uapi/asm/setup_data.h b/arch/x86/include/uapi/asm/setup_data.h
> index 2671c4e1b3a0..844f5b93473f 100644
> --- a/arch/x86/include/uapi/asm/setup_data.h
> +++ b/arch/x86/include/uapi/asm/setup_data.h
> @@ -83,8 +83,8 @@ struct ima_setup_data {
> * Locations of kexec handover metadata
> */
> struct kho_data {
> - __u64 fdt_addr;
> - __u64 fdt_size;
> + __u64 kstate_addr;
> + __u64 kstate_size;
> __u64 scratch_addr;
> __u64 scratch_size;
> } __attribute__((packed));
Isn't this part of the ABI which you can't just change.
Rob
More information about the kexec
mailing list