mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-06-13 15:03:58 +03:00
treewide: bcb: move ab_select command to bcb subcommands
To enhance code organization, it is beneficial to consolidate all A/B BCB management routines into a single super-command. The 'bcb' command is an excellent candidate for this purpose. This patch integrates the separate 'ab_select' command into the 'bcb' group as the 'ab_select' subcommand, maintaining the same parameter list for consistency. Signed-off-by: Dmitry Rokosov <ddrokosov@salutedevices.com> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> # vim3_android Link: https://lore.kernel.org/r/20241017-android_ab_master-v5-3-43bfcc096d95@salutedevices.com Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
This commit is contained in:
committed by
Mattijs Korpershoek
parent
a8ca7d46ea
commit
b523b4d2c3
@@ -12,7 +12,7 @@
|
||||
#define LOGO_UUID "43a3305d-150f-4cc9-bd3b-38fca8693846;"
|
||||
#define ROOT_UUID "ddb8c3f6-d94d-4394-b633-3134139cc2e0;"
|
||||
|
||||
#if defined(CONFIG_CMD_AB_SELECT)
|
||||
#if defined(CONFIG_CMD_BCB) && defined(CONFIG_ANDROID_AB)
|
||||
#define PARTS_DEFAULT \
|
||||
"uuid_disk=${uuid_gpt_disk};" \
|
||||
"name=logo,start=512K,size=2M,uuid=" LOGO_UUID \
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
#define LOGO_UUID "43a3305d-150f-4cc9-bd3b-38fca8693846;"
|
||||
#define ROOT_UUID "ddb8c3f6-d94d-4394-b633-3134139cc2e0;"
|
||||
|
||||
#if defined(CONFIG_CMD_AB_SELECT)
|
||||
#if defined(CONFIG_CMD_BCB) && defined(CONFIG_ANDROID_AB)
|
||||
#define PARTS_DEFAULT \
|
||||
"uuid_disk=${uuid_gpt_disk};" \
|
||||
"name=logo,start=512K,size=2M,uuid=" LOGO_UUID \
|
||||
|
||||
@@ -47,13 +47,13 @@
|
||||
#define AVB_VERIFY_CMD ""
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_CMD_AB_SELECT)
|
||||
#if defined(CONFIG_CMD_BCB) && defined(CONFIG_ANDROID_AB)
|
||||
#define ANDROIDBOOT_GET_CURRENT_SLOT_CMD "get_current_slot=" \
|
||||
"if part number mmc ${mmcdev} " CONTROL_PARTITION " control_part_number; " \
|
||||
"then " \
|
||||
"echo " CONTROL_PARTITION \
|
||||
" partition number:${control_part_number};" \
|
||||
"ab_select current_slot mmc ${mmcdev}:${control_part_number};" \
|
||||
"bcb ab_select current_slot mmc ${mmcdev}:${control_part_number};" \
|
||||
"else " \
|
||||
"echo " CONTROL_PARTITION " partition not found;" \
|
||||
"fi;\0"
|
||||
|
||||
@@ -93,13 +93,13 @@
|
||||
|
||||
#define CONTROL_PARTITION "misc"
|
||||
|
||||
#if defined(CONFIG_CMD_AB_SELECT)
|
||||
#if defined(CONFIG_CMD_BCB) && defined(CONFIG_ANDROID_AB)
|
||||
#define AB_SELECT_SLOT \
|
||||
"if part number mmc 1 " CONTROL_PARTITION " control_part_number; " \
|
||||
"then " \
|
||||
"echo " CONTROL_PARTITION \
|
||||
" partition number:${control_part_number};" \
|
||||
"ab_select slot_name mmc ${mmcdev}:${control_part_number};" \
|
||||
"bcb ab_select slot_name mmc ${mmcdev}:${control_part_number};" \
|
||||
"else " \
|
||||
"echo " CONTROL_PARTITION " partition not found;" \
|
||||
"exit;" \
|
||||
|
||||
Reference in New Issue
Block a user