Hi Grant,

> diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
> index d61fda8..66401bc 100644
> --- a/drivers/of/fdt.c
> +++ b/drivers/of/fdt.c
> @@ -94,6 +94,8 @@ int __init of_scan_flat_dt(int (*it)(unsigned long node,
>                       break;
>       } while (1);
>  
> +     if (rc)
> +             pr_err("Failed to unflatten device tree blob.  rc=%i\n", rc);
>       return rc;
>  }

rc == 1 is perfectly valid - it indicates that the iterator callback
stopped the scan early.

How about we just check for the presence of OF_DT_HEADER instead?

Cheers,

Jeremy

_______________________________________________
devicetree-discuss mailing list
[email protected]
https://lists.ozlabs.org/listinfo/devicetree-discuss

Reply via email to