]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
efi_loader: use correct format string for unsigned long
authorHeinrich Schuchardt <xypron.glpk@gmx.de>
Fri, 22 Dec 2017 18:16:57 +0000 (19:16 +0100)
committerAlexander Graf <agraf@suse.de>
Mon, 22 Jan 2018 22:09:12 +0000 (23:09 +0100)
virt_size is of type unsigned long.
So it should be printed with %ul.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
lib/efi_loader/efi_image_loader.c

index af29cc4f04e9849c1ca5a84805a2eab01f28ed02..849d7ce3777dd1968c5ebe1ebf61840c644d806d 100644 (file)
@@ -133,8 +133,8 @@ void *efi_load_pe(void *efi, struct efi_loaded_image *loaded_image_info)
                image_size = opt->SizeOfImage;
                efi_reloc = efi_alloc(virt_size, EFI_LOADER_DATA);
                if (!efi_reloc) {
-                       printf("%s: Could not allocate %ld bytes\n",
-                               __func__, virt_size);
+                       printf("%s: Could not allocate %lu bytes\n",
+                              __func__, virt_size);
                        return NULL;
                }
                entry = efi_reloc + opt->AddressOfEntryPoint;
@@ -147,8 +147,8 @@ void *efi_load_pe(void *efi, struct efi_loaded_image *loaded_image_info)
                image_size = opt->SizeOfImage;
                efi_reloc = efi_alloc(virt_size, EFI_LOADER_DATA);
                if (!efi_reloc) {
-                       printf("%s: Could not allocate %ld bytes\n",
-                               __func__, virt_size);
+                       printf("%s: Could not allocate %lu bytes\n",
+                              __func__, virt_size);
                        return NULL;
                }
                entry = efi_reloc + opt->AddressOfEntryPoint;