x86: Move x86 zboot state into struct bootm_info
authorSimon Glass <sjg@chromium.org>
Thu, 6 Mar 2025 00:24:58 +0000 (17:24 -0700)
committerTom Rini <trini@konsulko.com>
Tue, 18 Mar 2025 19:12:15 +0000 (13:12 -0600)
commit75e85df7963f57e4bb80b3d805ba2295b1843911
tree66bd81bc240b2a37dc6d85982e07a7b58a38721e
parent2de073527bb92b47d49366249cd3fdea5016bcaf
x86: Move x86 zboot state into struct bootm_info

This structure is supposed to handle any type of booting
programmatically, i.e. without needing a command to be executed. Move
the x86-specific members into it and use it instead of
struct zboot_state. Provide a macro so access is possible without adding
lots of #ifdefs to the code.

This will allow the struct to be used for all four types of booting
(bootm, bootz, booti and zboot).

Call bootm_init() to init the state, to match other boot methods.

Note that some rationalisation could be performed on this. But this
is tricky since addresses are stored as strings in several places. Also
some strings combine multiple arguments into one. So to keep this task
somewhat manageable, we content ourselves with just getting everything
into the same struct

Signed-off-by: Simon Glass <sjg@chromium.org>
arch/x86/include/asm/zimage.h
arch/x86/lib/zimage.c
include/bootm.h