[PATCH 1/1] efi_loader: fix efi_show_tables()
Heinrich Schuchardt
heinrich.schuchardt at canonical.com
Tue Nov 21 02:10:35 CET 2023
Since commit 041840eeeb12 ("efi: Split out table-listing code into a new
file") the `efi tables` command prints random numbers instead of GUIDs.
%pUl expects a pointer to a GUID not to a string.
Set maintainer for file cmd/efi_comon.c.
Fixes: 041840eeeb12 ("efi: Split out table-listing code into a new file")
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at canonical.com>
---
MAINTAINERS | 1 +
cmd/efi_common.c | 8 ++++----
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/MAINTAINERS b/MAINTAINERS
index 7c1cb2dc4d..40786023ee 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -993,6 +993,7 @@ S: Maintained
T: git https://source.denx.de/u-boot/custodians/u-boot-efi.git
F: arch/arm/lib/*_efi.*
F: cmd/bootefi.c
+F: cmd/efi_common.c
F: cmd/eficonfig.c
F: cmd/efidebug.c
F: cmd/nvedit_efi.c
diff --git a/cmd/efi_common.c b/cmd/efi_common.c
index f4056096cd..f6e3494892 100644
--- a/cmd/efi_common.c
+++ b/cmd/efi_common.c
@@ -17,10 +17,10 @@ void efi_show_tables(struct efi_system_table *systab)
for (i = 0; i < systab->nr_tables; i++) {
struct efi_configuration_table *tab = &systab->tables[i];
- char guid_str[37];
+ const char *guid_str;
- uuid_bin_to_str(tab->guid.b, guid_str, 1);
- printf("%p %pUl %s\n", tab->table, guid_str,
- uuid_guid_get_str(tab->guid.b) ?: "(unknown)");
+ guid_str = uuid_guid_get_str(tab->guid.b);
+ printf("%p %pUl %s\n", tab->table, tab->guid.b,
+ guid_str ? : "(unknown)");
}
}
--
2.40.1
More information about the U-Boot
mailing list