Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> --- common/oftree.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/common/oftree.c b/common/oftree.c index 28a3b965ffee..09cb66021217 100644 --- a/common/oftree.c +++ b/common/oftree.c @@ -145,6 +145,7 @@ static int of_fixup_bootargs(struct device_node *root, void *unused) const char *str; int err; int instance = reset_source_get_instance(); + struct device_d *dev; str = linux_bootargs_get(); if (!str) @@ -164,6 +165,19 @@ static int of_fixup_bootargs(struct device_node *root, void *unused) if (instance >= 0) of_property_write_u32(node, "reset-source-instance", instance); + + dev = reset_source_get_device(); + if (dev && dev->device_node) { + phandle phandle; + + phandle = of_node_create_phandle(dev->device_node); + + err = of_property_write_u32(node, + "reset-source-device", phandle); + if (err) + return err; + } + return of_fixup_bootargs_bootsource(root, node); } -- 2.20.1 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox