
From: Simon Glass <sjg@chromium.org> This function is only defined if CONFIG_OF_LIVE is enabled. Provide a static inline to handle it being disabled. Signed-off-by: Simon Glass <sjg@chromium.org> --- include/dm/ofnode.h | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/include/dm/ofnode.h b/include/dm/ofnode.h index 120393426db..cc6db4f5ae8 100644 --- a/include/dm/ofnode.h +++ b/include/dm/ofnode.h @@ -79,6 +79,16 @@ oftree oftree_from_fdt(void *fdt); */ ofnode noffset_to_ofnode(ofnode other_node, int of_offset); +/** + * oftree_dispose() - Dispose of an oftree + * + * This can be used to dispose of a tree that has been created (other than + * the control FDT which must not be disposed) + * + * @tree: Tree to dispose + */ +void oftree_dispose(oftree tree); + #else /* !OFNODE_MULTI_TREE */ static inline void oftree_reset(void) {} @@ -126,6 +136,8 @@ static inline ofnode noffset_to_ofnode(ofnode other_node, int of_offset) return node; } +static inline void oftree_dispose(oftree tree) {} + #endif /* OFNODE_MULTI_TREE */ /** @@ -375,16 +387,6 @@ static inline oftree oftree_from_np(struct device_node *root) return tree; } -/** - * oftree_dispose() - Dispose of an oftree - * - * This can be used to dispose of a tree that has been created (other than - * the control FDT which must not be disposed) - * - * @tree: Tree to dispose - */ -void oftree_dispose(oftree tree); - /** * ofnode_name_eq() - Check a node name ignoring its unit address * -- 2.43.0