Home
last modified time | relevance | path

Searched hist:"3 aaa96e8af28dc2847ab3d76da567079c5ed14d6" (Results 1 – 1 of 1) sorted by relevance

/rk3399_rockchip-uboot/arch/arm/mach-rockchip/
H A Dboot_mode.c3aaa96e8af28dc2847ab3d76da567079c5ed14d6 Mon Nov 09 09:14:16 UTC 2020 Joseph Chen <chenjh@rock-chips.com> rockchip: boot-mode: reinitialize static variable "boot_mode"

Special handle:
Once the BCB offset changes, reinitialize "boot_mode".

Background:
1. there are two Android BCB at the 0x00 and 0x20 offset in
misc.img to compatible legacy(0x20) SDK.
2. android_bcb_msg_sector_offset() is for android image:
return 0x20 if image version < 10, otherwise 0x00.
3. If not android image, BCB at 0x20 is the valid one.

U-Boot can support booting both FIT & Android image, if FIT
boot flow enters here early than Android, the "boot_mode" is
set as BOOT_MODE_RECOVERY according to BCB at 0x20 offset.
After that, this function always return static variable "boot_mode"
as BOOT_MODE_RECOVERY even android(>=10) boot flow enter here.

Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I0ed05ba1b18447a58d3faff37ac50ecc79fab374