aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm64/kernel/setup.c
diff options
context:
space:
mode:
authorDavid Daney <david.daney@cavium.com>2016-04-08 18:50:26 -0400
committerWill Deacon <will.deacon@arm.com>2016-04-15 13:06:08 -0400
commit3194ac6e66cc7a00c1fa9fecf33a7c376b489497 (patch)
tree2820041003af28ce17b7d07ca23e25ab459a681e /arch/arm64/kernel/setup.c
parent298535c00a2cbcd59e38f8f1c0c9ae7b9911e946 (diff)
arm64: Move unflatten_device_tree() call earlier.
In order to extract NUMA information from the device tree, we need to have the tree in its unflattened form. Move the call to bootmem_init() in the tail of paging_init() into setup_arch, and adjust header files so that its declaration is visible. Move the unflatten_device_tree() call between the calls to paging_init() and bootmem_init(). Follow on patches add NUMA handling to bootmem_init(). Signed-off-by: David Daney <david.daney@cavium.com> Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'arch/arm64/kernel/setup.c')
-rw-r--r--arch/arm64/kernel/setup.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/arch/arm64/kernel/setup.c b/arch/arm64/kernel/setup.c
index 7b85b1d6a6fb..432bc7f1dc45 100644
--- a/arch/arm64/kernel/setup.c
+++ b/arch/arm64/kernel/setup.c
@@ -265,18 +265,22 @@ void __init setup_arch(char **cmdline_p)
265 265
266 paging_init(); 266 paging_init();
267 267
268 if (acpi_disabled)
269 unflatten_device_tree();
270
271 bootmem_init();
272
268 kasan_init(); 273 kasan_init();
269 274
270 request_standard_resources(); 275 request_standard_resources();
271 276
272 early_ioremap_reset(); 277 early_ioremap_reset();
273 278
274 if (acpi_disabled) { 279 if (acpi_disabled)
275 unflatten_device_tree();
276 psci_dt_init(); 280 psci_dt_init();
277 } else { 281 else
278 psci_acpi_init(); 282 psci_acpi_init();
279 } 283
280 xen_early_init(); 284 xen_early_init();
281 285
282 cpu_read_bootcpu_ops(); 286 cpu_read_bootcpu_ops();