@@ -682,35 +682,6 @@ static void __init fdt_reserve_elfcorehdr(void)
elfcorehdr_size >> 10, elfcorehdr_addr);
}
-/**
- * early_init_fdt_scan_reserved_mem() - create reserved memory regions
- *
- * This function grabs memory from early allocator for device exclusive use
- * defined in device tree structures. It should be called by arch specific code
- * once the early allocator (i.e. memblock) has been fully activated.
- */
-void __init early_init_fdt_scan_reserved_mem(void)
-{
- int n;
- u64 base, size;
-
- if (!initial_boot_params)
- return;
-
- fdt_scan_reserved_mem();
- fdt_reserve_elfcorehdr();
-
- /* Process header /memreserve/ fields */
- for (n = 0; ; n++) {
- fdt_get_mem_rsv(initial_boot_params, n, &base, &size);
- if (!size)
- break;
- memblock_reserve(base, size);
- }
-
- fdt_init_reserved_mem();
-}
-
/**
* early_fdt_scan_reserved_mem() - create reserved memory regions
*
@@ -62,7 +62,6 @@ extern int early_init_dt_scan_chosen(char *cmdline);
extern int early_init_dt_scan_memory(void);
extern void early_init_dt_check_for_usable_mem_range(void);
extern int early_init_dt_scan_chosen_stdout(void);
-extern void early_init_fdt_scan_reserved_mem(void);
extern void early_fdt_scan_reserved_mem(void);
extern void early_init_fdt_reserve_self(void);
extern void early_init_dt_add_memory_arch(u64 base, u64 size);
@@ -88,7 +87,6 @@ extern void early_get_first_memblock_info(void *, phys_addr_t *);
#else /* CONFIG_OF_EARLY_FLATTREE */
static inline void early_init_dt_check_for_usable_mem_range(void) {}
static inline int early_init_dt_scan_chosen_stdout(void) { return -ENODEV; }
-static inline void early_init_fdt_scan_reserved_mem(void) {}
static inline void early_fdt_scan_reserved_mem(void) {}
static inline void early_init_fdt_reserve_self(void) {}
static inline const char *of_flat_dt_get_machine_name(void) { return NULL; }
Delete the early_init_fdt_scan_reserved_mem() function definition since this function is no longer being used anywhere in the kernel. Signed-off-by: Oreoluwa Babatunde <quic_obabatun@quicinc.com> --- drivers/of/fdt.c | 29 ----------------------------- include/linux/of_fdt.h | 2 -- 2 files changed, 31 deletions(-)