aboutsummaryrefslogtreecommitdiff
path: root/include/of_live.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2023-06-01 10:22:42 -0600
committerTom Rini <trini@konsulko.com>2023-07-14 12:54:51 -0400
commita8f2ac2ae6f15b675a55bcf3a20181f3bb223562 (patch)
tree022b4468cec581d4b7457507dd787d656a709eb1 /include/of_live.h
parentc8a4e293863348c27d0119cbbe425b91d500cec1 (diff)
downloadu-boot-a8f2ac2ae6f15b675a55bcf3a20181f3bb223562.zip
u-boot-a8f2ac2ae6f15b675a55bcf3a20181f3bb223562.tar.gz
u-boot-a8f2ac2ae6f15b675a55bcf3a20181f3bb223562.tar.bz2
fdt: Allow more general use of livetree
At present livetree can only be used for the control FDT. It is useful to be able to use the ofnode API for other FDTs, e.g. those used by the upcoming configuration editor. We already have most of the support present, and tests can be marked with the UT_TESTF_OTHER_FDT flag to use another FDT as a special case. But with this change, the functionality becomes more generally available. Plumb in the require support. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/of_live.h')
-rw-r--r--include/of_live.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/of_live.h b/include/of_live.h
index f59d6af..05e86ac 100644
--- a/include/of_live.h
+++ b/include/of_live.h
@@ -36,4 +36,14 @@ int of_live_build(const void *fdt_blob, struct device_node **rootp);
*/
int unflatten_device_tree(const void *blob, struct device_node **mynodes);
+/**
+ * of_live_free() - Dispose of a livetree
+ *
+ * This frees memory used by the tree, after which @root becomes invalid and
+ * cannot be used
+ *
+ * @root: Tree to dispose
+ */
+void of_live_free(struct device_node *root);
+
#endif