From c193d9bd284565df4ddcdd1e9190d2ce718e9eb7 Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Sat, 15 May 2021 18:07:47 +0200 Subject: smbios: error handling for invalid addresses SMBIOS tables only support 32bit addresses. If we don't have memory here handle the error gracefully: * on x86_64 fail to start U-Boot * during UEFI booting ignore the missing table Signed-off-by: Heinrich Schuchardt Reviewed-by: Simon Glass --- include/smbios.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/smbios.h b/include/smbios.h index fc49fc10b9..aa6b6f3849 100644 --- a/include/smbios.h +++ b/include/smbios.h @@ -229,8 +229,11 @@ static inline void fill_smbios_header(void *table, int type, * This writes SMBIOS table at a given address. * * @addr: start address to write SMBIOS table. If this is not - * 16-byte-aligned then it will be aligned before the table is written - * @return: end address of SMBIOS table (and start address for next entry) + * 16-byte-aligned then it will be aligned before the table is + * written. + * Return: end address of SMBIOS table (and start address for next entry) + * or NULL in case of an error + * */ ulong write_smbios_table(ulong addr); -- cgit v1.2.3 From 86a3d43bff414f30089b1b9a7b01234aca58763d Mon Sep 17 00:00:00 2001 From: AKASHI Takahiro Date: Tue, 20 Jul 2021 14:57:02 +0900 Subject: efi_loader: remove asm/setjmp.h from efi_api.h In the commit c982874e930d ("efi_loader: refactor efi_setup_loaded_image()"), setjmp-related definitions were moved to efi_loaded_image_obj in efi_loader.h. So setjmp.h is no longer refererenced in efi_api.h. This also fixes some error when efi_api.h will be included in mkeficapsule.c. Fixes: c982874e930d ("efi_loader: refactor efi_setup_loaded_image()") Signed-off-by: AKASHI Takahiro Reviewed-by: Heinrich Schuchardt --- include/efi_api.h | 4 ---- include/efi_loader.h | 1 + 2 files changed, 1 insertion(+), 4 deletions(-) (limited to 'include') diff --git a/include/efi_api.h b/include/efi_api.h index 18a1adf023..e854a8b3a1 100644 --- a/include/efi_api.h +++ b/include/efi_api.h @@ -20,10 +20,6 @@ #include #include -#ifdef CONFIG_EFI_LOADER -#include -#endif - /* UEFI spec version 2.8 */ #define EFI_SPECIFICATION_VERSION (2 << 16 | 80) diff --git a/include/efi_loader.h b/include/efi_loader.h index b81180cfda..e6d41cfb35 100644 --- a/include/efi_loader.h +++ b/include/efi_loader.h @@ -17,6 +17,7 @@ #include struct blk_desc; +struct jmp_buf_data; static inline int guidcmp(const void *g1, const void *g2) { -- cgit v1.2.3