diff options
Diffstat (limited to 'scripts/dtc/livetree.c')
-rw-r--r-- | scripts/dtc/livetree.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/dtc/livetree.c b/scripts/dtc/livetree.c index b61465f..e229b84 100644 --- a/scripts/dtc/livetree.c +++ b/scripts/dtc/livetree.c @@ -511,7 +511,9 @@ struct node *get_node_by_phandle(struct node *tree, cell_t phandle) struct node *get_node_by_ref(struct node *tree, const char *ref) { - if (ref[0] == '/') + if (streq(ref, "/")) + return tree; + else if (ref[0] == '/') return get_node_by_path(tree, ref); else return get_node_by_label(tree, ref); |