From 163c5f60ebb492eb3bab75e299cb43e6d022653d Mon Sep 17 00:00:00 2001 From: Patrick Delaunay Date: Thu, 8 Jun 2023 17:16:38 +0200 Subject: fdt_support: add fdt_copy_fixed_partitions function Add a new function fdt_copy_fixed_partitions to copy the fixed partition nodes from U-Boot device tree to Linux kernel device tree and to dynamically configure the MTD partitions. This function fdt_copy_fixed_partitions is only based on device tree with livetree compatible function and replace the function fdt_fixup_mtdparts based on mtdparts variable. Signed-off-by: Patrick Delaunay Reviewed-by: Patrice Chotard --- include/fdt_support.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include/fdt_support.h') diff --git a/include/fdt_support.h b/include/fdt_support.h index eeb83e6251d..2cd83668982 100644 --- a/include/fdt_support.h +++ b/include/fdt_support.h @@ -256,6 +256,14 @@ static inline void fdt_fixup_mtdparts(void *fdt, } #endif +/** + * copy the fixed-partition nodes from U-Boot device tree to external blob + * + * @param blob FDT blob to update + * Return: 0 if ok, or non-zero on error + */ +int fdt_copy_fixed_partitions(void *blob); + void fdt_del_node_and_alias(void *blob, const char *alias); /** -- cgit v1.2.3