diff options
author | Simon Glass <sjg@chromium.org> | 2015-06-23 15:39:09 -0600 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2015-07-21 17:39:28 -0600 |
commit | cb5f97f70766fdabc90847bbbc25eb759b2b4797 (patch) | |
tree | d529ed0452d9fe19a022b99c95f97e3b1ce99ea3 | |
parent | c4af6732c4021ffe8b3d0c82bdcf1eebb263bfc3 (diff) | |
download | u-boot-imx-cb5f97f70766fdabc90847bbbc25eb759b2b4797.zip u-boot-imx-cb5f97f70766fdabc90847bbbc25eb759b2b4797.tar.gz u-boot-imx-cb5f97f70766fdabc90847bbbc25eb759b2b4797.tar.bz2 |
fdt: Provide debug info when a device tree cannot be found
It can be quite confusing with a new platform to figure out why the device
tree cannot be located. Add some debug information for this case.
Signed-off-by: Simon Glass <sjg@chromium.org>
-rw-r--r-- | lib/fdtdec.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/fdtdec.c b/lib/fdtdec.c index f6c2b19..232ca74 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -568,6 +568,13 @@ int fdtdec_prepare_fdt(void) puts("Missing DTB\n"); #else puts("No valid device tree binary found - please append one to U-Boot binary, use u-boot-dtb.bin or define CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>\n"); +# ifdef DEBUG + if (gd->fdt_blob) { + printf("fdt_blob=%p\n", gd->fdt_blob); + print_buffer((ulong)gd->fdt_blob, gd->fdt_blob, 4, + 32, 0); + } +# endif #endif return -1; } |