[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240507-cm_probe-v1-1-11dbfd598f3c@flygoat.com>
Date: Tue, 07 May 2024 10:01:49 +0100
From: Jiaxun Yang <jiaxun.yang@...goat.com>
To: Paul Burton <paulburton@...nel.org>,
Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
Rob Herring <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>
Cc: linux-mips@...r.kernel.org, linux-kernel@...r.kernel.org,
devicetree@...r.kernel.org, Jiaxun Yang <jiaxun.yang@...goat.com>
Subject: [PATCH 1/5] MIPS: generic: Do __dt_setup_arch in prom_init
We want fdt parse functions to be available as early as possible,
thus do __dt_setup_arch immediately after we get fdt address in
prom_init.
Signed-off-by: Jiaxun Yang <jiaxun.yang@...goat.com>
---
arch/mips/generic/init.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/arch/mips/generic/init.c b/arch/mips/generic/init.c
index 1d712eac1617..9fd09061de78 100644
--- a/arch/mips/generic/init.c
+++ b/arch/mips/generic/init.c
@@ -26,8 +26,12 @@ static __initconst const void *mach_match_data;
void __init prom_init(void)
{
+ fw_init_cmdline();
plat_get_fdt();
BUG_ON(!fdt);
+ if (mach && mach->fixup_fdt)
+ fdt = mach->fixup_fdt(fdt, mach_match_data);
+ __dt_setup_arch((void *)fdt);
}
void __init *plat_get_fdt(void)
@@ -101,11 +105,6 @@ void __init plat_fdt_relocated(void *new_location)
void __init plat_mem_setup(void)
{
- if (mach && mach->fixup_fdt)
- fdt = mach->fixup_fdt(fdt, mach_match_data);
-
- fw_init_cmdline();
- __dt_setup_arch((void *)fdt);
}
void __init device_tree_init(void)
--
2.34.1
Powered by blists - more mailing lists