MA-18087-1 Enhance virtual A/B slot check
authorJi Luo <ji.luo@nxp.com>
Wed, 21 Oct 2020 02:11:51 +0000 (10:11 +0800)
committerJi Luo <ji.luo@nxp.com>
Thu, 13 May 2021 01:49:18 +0000 (09:49 +0800)
commit582ffab8332b1270a3eba7faf9a1091b32b4cad3
tree5ad3fca07188df59760bffd8526609b502a5e902
parentc3dd6b105d62a68a0222ee9f892e7502ee6fe6ad
MA-18087-1 Enhance virtual A/B slot check

Set the initial 'source_slot' in 'misc_virtual_ab_message' as
the current slot. At the same time, add slot checks before
erase data if virtual A/B is enabled.

Test: virtual A/B update and erase.

Signed-off-by: Ji Luo <ji.luo@nxp.com>
Change-Id: I84896335a95d9188b85e114037b470b3f4e7a209
(cherry picked from commit a522c2245c3e58adbbcb99c43e0917ce315cc1aa)
(cherry picked from commit 40a1e64ded230e1c2b3d76cccaea1f910ed0d6d6)
drivers/fastboot/fb_fsl/fb_fsl_command.c
drivers/fastboot/fb_fsl/fb_fsl_virtual_ab.c
drivers/fastboot/fb_fsl/fb_fsl_virtual_ab.h
lib/avb/fsl/fsl_bootctrl.c
lib/avb/fsl/fsl_bootctrl.h