1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-08-31 16:22:36 +02:00

fastboot: Add default fastboot_set_reboot_flag implementation

Default implementation of fastboot_set_reboot_flag function that depends
on "bcb" commands could be used in general case if there are no need to
make any platform-specific implementation, otherwise it could be
disabled via Kconfig option FASTBOOT_USE_BCB_SET_REBOOT_FLAG.

Please note that FASTBOOT_USE_BCB_SET_REBOOT_FLAG is mutually exclusive
with some platforms which already have their own implementation of this
function.

Signed-off-by: Roman Kovalivskyi <roman.kovalivskyi@globallogic.com>
This commit is contained in:
Roman Kovalivskyi
2020-07-28 23:35:34 +03:00
committed by Marek Vasut
parent 2b2a771b40
commit 0ebf9842e5
4 changed files with 65 additions and 0 deletions

View File

@@ -52,6 +52,15 @@ enum fastboot_reboot_reason {
FASTBOOT_REBOOT_REASONS_COUNT
};
/**
* BCB boot commands
*/
static const char * const fastboot_boot_cmds[] = {
[FASTBOOT_REBOOT_REASON_BOOTLOADER] = "bootonce-bootloader",
[FASTBOOT_REBOOT_REASON_FASTBOOTD] = "boot-fastboot",
[FASTBOOT_REBOOT_REASON_RECOVERY] = "boot-recovery"
};
/**
* fastboot_response() - Writes a response of the form "$tag$reason".
*