common: bootm: add bootm state param for arch_preboot_os()
- This makes arch_preboot_os() more flexsible; - call arch_preboot_os() when BOOTM_STATE_OS_PREP; Change-Id: Ia4ae3666b8180c993c761ef222acbcff5358ae97 Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
This commit is contained in:
parent
6281e7d505
commit
bd700d6b80
|
|
@ -725,6 +725,8 @@ int do_bootm_states(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[],
|
|||
if (images->os.os == IH_OS_LINUX)
|
||||
fixup_silent_linux();
|
||||
#endif
|
||||
arch_preboot_os(BOOTM_STATE_OS_PREP);
|
||||
|
||||
ret = boot_fn(BOOTM_STATE_OS_PREP, argc, argv, images);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -469,7 +469,7 @@ static boot_os_fn *boot_os[] = {
|
|||
};
|
||||
|
||||
/* Allow for arch specific config before we boot */
|
||||
__weak void arch_preboot_os(void)
|
||||
__weak void arch_preboot_os(uint32_t bootm_state)
|
||||
{
|
||||
/* please define platform specific arch_preboot_os() */
|
||||
}
|
||||
|
|
@ -477,7 +477,7 @@ __weak void arch_preboot_os(void)
|
|||
int boot_selected_os(int argc, char * const argv[], int state,
|
||||
bootm_headers_t *images, boot_os_fn *boot_fn)
|
||||
{
|
||||
arch_preboot_os();
|
||||
arch_preboot_os(state);
|
||||
boot_fn(state, argc, argv, images);
|
||||
|
||||
/* Stand-alone may return when 'autostart' is 'no' */
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ int bootm_find_images(int flag, int argc, char * const argv[]);
|
|||
int do_bootm_states(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[],
|
||||
int states, bootm_headers_t *images, int boot_progress);
|
||||
|
||||
void arch_preboot_os(void);
|
||||
void arch_preboot_os(uint32_t bootm_state);
|
||||
|
||||
/**
|
||||
* bootm_decomp_image() - decompress the operating system
|
||||
|
|
|
|||
Loading…
Reference in New Issue