aboutsummaryrefslogtreecommitdiff
path: root/include/efi_loader.h
diff options
context:
space:
mode:
authorHeinrich Schuchardt <xypron.glpk@gmx.de>2021-01-17 07:52:09 +0100
committerHeinrich Schuchardt <xypron.glpk@gmx.de>2021-01-20 08:17:17 +0100
commit0a7e5165ec21d8092565a833211b21b356195398 (patch)
treec527113797caefc3942769c1aae17b7d4622a6d1 /include/efi_loader.h
parentd56013d37c829254e181c93dfefa745b9a1347d5 (diff)
downloadu-boot-0a7e5165ec21d8092565a833211b21b356195398.zip
u-boot-0a7e5165ec21d8092565a833211b21b356195398.tar.gz
u-boot-0a7e5165ec21d8092565a833211b21b356195398.tar.bz2
efi_loader: efi_size_in_pages() missing parentheses
Add parentheses around size to avoid possible operator precedence problems. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'include/efi_loader.h')
-rw-r--r--include/efi_loader.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/efi_loader.h b/include/efi_loader.h
index f759cfe..f470bbd 100644
--- a/include/efi_loader.h
+++ b/include/efi_loader.h
@@ -561,7 +561,7 @@ struct efi_file_handle *efi_file_from_path(struct efi_device_path *fp);
* @size: size in bytes
* Return: size in pages
*/
-#define efi_size_in_pages(size) ((size + EFI_PAGE_MASK) >> EFI_PAGE_SHIFT)
+#define efi_size_in_pages(size) (((size) + EFI_PAGE_MASK) >> EFI_PAGE_SHIFT)
/* Generic EFI memory allocator, call this to get memory */
void *efi_alloc(uint64_t len, int memory_type);
/* More specific EFI memory allocator, called by EFI payloads */