MIPS: Remove redundant check in device_tree_init()

In device_tree_init(), unflatten_and_copy_device_tree() checks
initial_boot_params, so remove the redundant check.

drivers/of/fdt.c
void __init unflatten_and_copy_device_tree(void)
{
	int size;
	void *dt;

	if (!initial_boot_params) {
		pr_warn("No valid device tree found, continuing without\n");
		return;
	}
	...
}

Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
This commit is contained in:
Tiezhu Yang 2022-03-10 14:50:10 +08:00 committed by Thomas Bogendoerfer
parent 2bc5bab9a7
commit 89fa126893
2 changed files with 0 additions and 6 deletions

View File

@ -39,8 +39,5 @@ void __init plat_mem_setup(void)
void __init device_tree_init(void)
{
if (!initial_boot_params)
return;
unflatten_and_copy_device_tree();
}

View File

@ -80,9 +80,6 @@ void __init prom_init(void)
void __init device_tree_init(void)
{
if (!initial_boot_params)
return;
unflatten_and_copy_device_tree();
}