Blame SOURCES/0014-arm64-set-correct-length-of-device-path-end-entry.patch

6b3c76
From dc589e298bf6aa12be88ef88ca95e90dee3a729a Mon Sep 17 00:00:00 2001
a85e8e
From: Leif Lindholm <leif.lindholm@linaro.org>
a85e8e
Date: Tue, 7 Jan 2014 17:52:50 +0000
6b3c76
Subject: [PATCH 014/261] arm64: set correct length of device path end entry
a85e8e
a85e8e
The length of the Device Path End entry in the grub_linux_boot()
a85e8e
function was incorrectly set to 0. This triggers an assert failure
a85e8e
in debug builds of Tianocore.
a85e8e
a85e8e
Set it to sizeof (grub_efi_device_path_t).
a85e8e
---
d41074
 ChangeLog                      | 4 ++++
6b3c76
 grub-core/loader/arm64/linux.c | 2 +-
a85e8e
 2 files changed, 5 insertions(+), 1 deletion(-)
a85e8e
6b3c76
diff --git a/ChangeLog b/ChangeLog
6b3c76
index 0b9fa05b2..4ec5517bd 100644
6b3c76
--- a/ChangeLog
6b3c76
+++ b/ChangeLog
6b3c76
@@ -1,3 +1,7 @@
6b3c76
+2014-01-07  Leif Lindholm <leif.lindholm@linaro.org>
6b3c76
+
6b3c76
+	* grub-core/loader/arm64/linux.c: correctly set device path end length.
6b3c76
+
6b3c76
 2014-01-07  Andrey Borzenkov <arvidjaar@gmail.com>
6b3c76
 
6b3c76
 	* util/grub-install.c: Use bootaa64.efi instead of bootaarch64.efi on
a85e8e
diff --git a/grub-core/loader/arm64/linux.c b/grub-core/loader/arm64/linux.c
6b3c76
index 9d15aad62..75ad871a8 100644
a85e8e
--- a/grub-core/loader/arm64/linux.c
a85e8e
+++ b/grub-core/loader/arm64/linux.c
a85e8e
@@ -268,7 +268,7 @@ grub_linux_boot (void)
a85e8e
 
a85e8e
   mempath[1].header.type = GRUB_EFI_END_DEVICE_PATH_TYPE;
a85e8e
   mempath[1].header.subtype = GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE;
a85e8e
-  mempath[1].header.length = 0;
a85e8e
+  mempath[1].header.length = sizeof (grub_efi_device_path_t);
a85e8e
 
a85e8e
   b = grub_efi_system_table->boot_services;
a85e8e
   status = b->load_image (0, grub_efi_image_handle,
6b3c76
-- 
6b3c76
2.13.5
6b3c76