aboutsummaryrefslogtreecommitdiff
path: root/dtc.c
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2008-02-29 16:51:28 +1100
committerJon Loeliger <jdl@loeliger.com>2008-03-23 08:00:33 -0500
commitb2de518b80eb01b1004e137ff2435b03dc40018d (patch)
treee3da6823a2856c6aff2710cd33f43b4da4dae471 /dtc.c
parent5ac97df149a171d63804a889ffcaa85e0feb400b (diff)
downloaddtc-b2de518b80eb01b1004e137ff2435b03dc40018d.zip
dtc-b2de518b80eb01b1004e137ff2435b03dc40018d.tar.gz
dtc-b2de518b80eb01b1004e137ff2435b03dc40018d.tar.bz2
dtc: Make -I dtb mode use fill_fullpaths()
At present -I dts and -I fs modes both use the fill_fullpaths() helper function to fill in the fullpath and basenamelen fields of struct node, which are useful in later parts of the code. -I dtb mode, however, fills these in itself. This patch simplifies flattree.c by making -I dtb mode use fill_fullpaths() like the others. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'dtc.c')
-rw-r--r--dtc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/dtc.c b/dtc.c
index c1814c1..90e1cce 100644
--- a/dtc.c
+++ b/dtc.c
@@ -55,7 +55,7 @@ char *join_path(const char *path, const char *name)
return str;
}
-void fill_fullpaths(struct node *tree, const char *prefix)
+static void fill_fullpaths(struct node *tree, const char *prefix)
{
struct node *child;
const char *unit;
@@ -208,6 +208,7 @@ int main(int argc, char *argv[])
if (! bi || ! bi->dt || bi->error)
die("Couldn't read input tree\n");
+ fill_fullpaths(bi->dt, "");
process_checks(force, bi);
if (streq(outname, "-")) {