[PATCH v4 0/3] Restore support of short name for type UUID parameter
Patrick Delaunay
patrick.delaunay at foss.st.com
Mon Jun 16 13:27:46 CEST 2025
V4 update the test print_guid, as "ESP" is a known part type UUID under
CONFIG_EFI_PARTITION flag and no more CONFIG_EFI or CONFIG_CMD_EFIDEBUG
or CONFIG_CMD_EFIDEBUG
test result:
https://source.denx.de/u-boot/custodians/u-boot-stm/-/pipelines/26699
V3 version solve issue for "ESP" support when
CONFIG_CMD_EFIDEBUG and CONFIG_EFI is not activated
for example for test with qemu-arm-sbsa defconfig
Fix and add documentation/tests for selection by string for known
partition type GUID introduced by bcb41dcaefac ("uuid: add
selection by string for known partition type GUID"):
- split list_guid for short name (used also for partiton
description with type parameter) and full name to display
information
- as the function are uuid_str_to_bin() / uuid_guid_get_str()
are no more under CONFIG_PARTITION_TYPE_GUID, since commit
31ce367cd100 ("lib/uuid.c: change prototype of uuid_guid_get_str()")
and commit c1528f324c60 ("lib: compile uuid_guid_get_str if
CONFIG_LIB_UUID=y") move the content of array under EFI_PARTITION
and linker will remove it is not used it (in SPL)
- Add and fix documentation for gpt command
- Add test test_gpt_write_part_type to test "type=" parameters
This first patch solves an issue for the "system" shortcut for ESP,
removed by commit d54V3 version solve issue for "ESP" support when
CONFIG_CMD_EFIDEBUG and CONFIG_EFI is not activated
for example for test with qemu-arm-sbsa defconfige1004b8b1 ("lib/uuid.c: use unique name
for PARTITION_SYSTEM_GUID") but used in 2 location (at least):
1- board/samsung/e850-96/e850-96.env:10:
partitions=name=esp,start=512K,size=128M,bootable,type=system;
partitions+=name=rootfs,size=-,bootable,type=linux
2- arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c:1151
case PART_ESP:
/* EFI System Partition */
459219 type_str = "system"
....
offset += snprintf(buf + offset,
buflen - offset,
",type=%s", type_str);
Changes in v4:
- update compilation flag used in the test print_guid for
"EFI System Partition" known part type UUID
Changes in v3:
- The definition for ESP = "system" partition in list_guid[]
is no more under CONFIG_CMD_EFIDEBUG or CONFIG_EFI flags,
and restore the initial level (always support for display)
as it is done for MBR partition or when U-Boot is a UEFI
loader (CONFIG_CMD_BOOTEFI).
Changes in v2:
- change 'string' to 'type' in struct for list_guid[]
- clarify the usage of struct field 'type' and 'description' in
comment and in commit message
- use 'type' for EFI_XXX description as these string have
no space and size is lower than 36 characters.
Patrick Delaunay (3):
lib/uuid.c: restore support of system partition type for ESP
doc: cmd: gpt: add information on type partition
test/py: tests: gpt: add test_gpt_write_part_type
doc/usage/cmd/gpt.rst | 93 +++++++++++++++++++---
lib/uuid.c | 162 +++++++++++++++++++++-----------------
test/common/print.c | 3 +-
test/py/tests/test_gpt.py | 27 +++++++
4 files changed, 201 insertions(+), 84 deletions(-)
--
2.25.1
base-commit: c5afa1fef49f55146e78d6157470520391c40eca
branch: sdsdfsfdsddf
More information about the U-Boot
mailing list