]> git.sur5r.net Git - u-boot/blobdiff - lib/fdtdec.c
Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'
[u-boot] / lib / fdtdec.c
index 92fbefe04574787efa4dabdfce9e46aeb9eea979..ac1fe0be20dc2915038b67318f15d88746e354e1 100644 (file)
@@ -354,10 +354,11 @@ int fdtdec_check_fdt(void)
  */
 int fdtdec_prepare_fdt(void)
 {
-       if (((uintptr_t)gd->fdt_blob & 3) || fdt_check_header(gd->fdt_blob)) {
+       if (!gd->fdt_blob || ((uintptr_t)gd->fdt_blob & 3) ||
+           fdt_check_header(gd->fdt_blob)) {
                printf("No valid FDT found - please append one to U-Boot "
                        "binary, use u-boot-dtb.bin or define "
-                       "CONFIG_OF_EMBED\n");
+                       "CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>\n");
                return -1;
        }
        return 0;