Message ID | 1435095556-15924-48-git-send-email-sjg@chromium.org |
---|---|
State | Accepted |
Delegated to: | Simon Glass |
Headers | show |
On 23 June 2015 at 15:39, Simon Glass <sjg@chromium.org> wrote: > 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> > --- > > Changes in v3: None > Changes in v2: None > > lib/fdtdec.c | 7 +++++++ > 1 file changed, 7 insertions(+) Applied to u-boot-dm.
diff --git a/lib/fdtdec.c b/lib/fdtdec.c index add9adc..a78d577 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; }
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> --- Changes in v3: None Changes in v2: None lib/fdtdec.c | 7 +++++++ 1 file changed, 7 insertions(+)