From: Gabe Black <gabebl...@chromium.org>

If the device tree pointer isn't set to anything, which could happen if the
device tree isn't found, for instance, or simply never set up, the pointer
could be set to something arbitrary. This change forces initializes it to NULL
so that it's more obviously not set.

Signed-off-by: Gabe Black <gabebl...@chromium.org>
Signed-off-by: Simon Glass <s...@chromium.org>
---
 arch/x86/cpu/cpu.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/arch/x86/cpu/cpu.c b/arch/x86/cpu/cpu.c
index e8bfe6f..8b6d4cf 100644
--- a/arch/x86/cpu/cpu.c
+++ b/arch/x86/cpu/cpu.c
@@ -93,6 +93,7 @@ static void load_gdt(const u64 *boot_gdt, u16 num_entries)
 void init_gd(gd_t *id, u64 *gdt_addr)
 {
        id->gd_addr = (ulong)id;
+       gd->fdt_blob = NULL;
        setup_gdt(id, gdt_addr);
 }
 
-- 
1.7.7.3

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to