diff options
Diffstat (limited to 'hdata')
-rw-r--r-- | hdata/test/hdata_to_dt.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/hdata/test/hdata_to_dt.c b/hdata/test/hdata_to_dt.c index fd2957c..a5f152e 100644 --- a/hdata/test/hdata_to_dt.c +++ b/hdata/test/hdata_to_dt.c @@ -253,8 +253,23 @@ static void squash_blobs(struct dt_node *root) static void dump_hdata_fdt(struct dt_node *root) { + struct dt_node *n; void *fdt_blob; + /* delete some properties that hardcode pointers */ + dt_for_each_node(dt_root, n) { + struct dt_property *base; + + /* + * sml-base is a raw pointer into the HDAT area so it changes + * on each execution of hdata_to_dt. Work around this by + * zeroing it. + */ + base = __dt_find_property(n, "linux,sml-base"); + if (base) + memset(base->prop, 0, base->len); + } + fdt_blob = create_dtb(root, false); if (!fdt_blob) { |