aboutsummaryrefslogtreecommitdiff
path: root/lib/fdtdec.c
diff options
context:
space:
mode:
authorSimon Glass2022-09-06 20:27:19 -0600
committerTom Rini2022-09-29 22:43:43 -0400
commitee88ba71acce3455aadef18c725de715e6c9af21 (patch)
tree4c890e0501c5fdba9acf6a28407879ebc1dc659b /lib/fdtdec.c
parent66d0d0c188db9e816c5b18e8823a8d8bf5e9cd63 (diff)
dm: core: Provide a way to reset the device tree
At present there is only one device tree used by the ofnode functions, except for some esoteric use of live tree. In preparation for supporting more than one, add a way to reset the list of device trees. For now this does nothing. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'lib/fdtdec.c')
-rw-r--r--lib/fdtdec.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/fdtdec.c b/lib/fdtdec.c
index eca01081c5d..64c5b3da15e 100644
--- a/lib/fdtdec.c
+++ b/lib/fdtdec.c
@@ -13,7 +13,6 @@
#include <log.h>
#include <malloc.h>
#include <net.h>
-#include <dm/of_extra.h>
#include <env.h>
#include <errno.h>
#include <fdtdec.h>
@@ -24,6 +23,8 @@
#include <serial.h>
#include <asm/global_data.h>
#include <asm/sections.h>
+#include <dm/ofnode.h>
+#include <dm/of_extra.h>
#include <linux/ctype.h>
#include <linux/lzo.h>
#include <linux/ioport.h>
@@ -1668,6 +1669,8 @@ int fdtdec_setup(void)
ret = fdtdec_prepare_fdt();
if (!ret)
ret = fdtdec_board_setup(gd->fdt_blob);
+ oftree_reset();
+
return ret;
}