]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
efi_loader: correct a definition of struct efi_capsule_header
authorAKASHI Takahiro <takahiro.akashi@linaro.org>
Tue, 17 Mar 2020 02:12:37 +0000 (11:12 +0900)
committerHeinrich Schuchardt <xypron.glpk@gmx.de>
Tue, 17 Mar 2020 07:29:52 +0000 (08:29 +0100)
See UEFI specification, section 8.5.3.
In addition, the structure, efi_capsule_header, should be "packed"
as it is a serialized binary format in a capsule file.

Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
include/efi_api.h

index 3b0845aafda7163cb65d975800bc6372b1c1f133..4713da2e1d000542268b71b238f19dab6fbed804 100644 (file)
@@ -217,11 +217,11 @@ enum efi_reset_type {
 #define CAPSULE_FLAGS_INITIATE_RESET           0x00040000
 
 struct efi_capsule_header {
-       efi_guid_t *capsule_guid;
+       efi_guid_t capsule_guid;
        u32 header_size;
        u32 flags;
        u32 capsule_image_size;
-};
+} __packed;
 
 #define EFI_RT_SUPPORTED_GET_TIME                      0x0001
 #define EFI_RT_SUPPORTED_SET_TIME                      0x0002