[PATCH 9/19] ppc64: Incorporate the iSeries device tree into the bootup sequence

Michael Ellerman michael at ellerman.id.au
Tue Jul 26 18:58:41 EST 2005


This patch adds a call to early_init_devtree() on the fake device tree, and
also changes some ifdefs in setup_system() so we call unflatten_device_tree()
on iSeries also.

---

 arch/ppc64/kernel/iSeries_setup.c |    1 +
 arch/ppc64/kernel/setup.c         |    8 ++------
 include/asm-ppc64/prom.h          |    1 +
 3 files changed, 4 insertions(+), 6 deletions(-)

Index: work/arch/ppc64/kernel/setup.c
===================================================================
--- work.orig/arch/ppc64/kernel/setup.c
+++ work/arch/ppc64/kernel/setup.c
@@ -447,6 +447,7 @@ void __init early_setup(unsigned long dt
 	DBG(" <- early_setup()\n");
 }
 
+#endif /* CONFIG_PPC_MULTIPLATFORM */
 
 /*
  * Initialize some remaining members of the ppc64_caches and systemcfg structures
@@ -563,8 +564,6 @@ static void __init check_for_initrd(void
 #endif /* CONFIG_BLK_DEV_INITRD */
 }
 
-#endif /* CONFIG_PPC_MULTIPLATFORM */
-
 /*
  * Do some initial setup of the system.  The parameters are those which 
  * were passed in from the bootloader.
@@ -577,9 +576,7 @@ void __init setup_system(void)
 	/* pSeries systems are identified in prom.c via OF. */
 	if (itLpNaca.xLparInstalled == 1)
 		systemcfg->platform = PLATFORM_ISERIES_LPAR;
-
-	ppc_md.init_early();
-#else /* CONFIG_PPC_ISERIES */
+#endif /* CONFIG_PPC_ISERIES */
 
 	/*
 	 * Unflatten the device-tree passed by prom_init or kexec
@@ -639,7 +636,6 @@ void __init setup_system(void)
 	strlcpy(saved_command_line, cmd_line, COMMAND_LINE_SIZE);
 
 	parse_early_param();
-#endif /* !CONFIG_PPC_ISERIES */
 
 #if defined(CONFIG_SMP) && !defined(CONFIG_PPC_ISERIES)
 	/*
Index: work/arch/ppc64/kernel/iSeries_setup.c
===================================================================
--- work.orig/arch/ppc64/kernel/iSeries_setup.c
+++ work/arch/ppc64/kernel/iSeries_setup.c
@@ -1082,6 +1082,7 @@ void __init iSeries_early_setup(void)
 	build_iSeries_Memory_Map();
 
 	build_flat_dt(&iseries_dt);
+	early_init_devtree(&iseries_dt);
 
 	/* Bolt mappings for all of memory (or some if we've got a limit) */
 	iSeries_bolt_kernel(0, systemcfg->physicalMemorySize);
Index: work/include/asm-ppc64/prom.h
===================================================================
--- work.orig/include/asm-ppc64/prom.h
+++ work/include/asm-ppc64/prom.h
@@ -215,5 +215,6 @@ extern int prom_n_size_cells(struct devi
 extern int prom_n_intr_cells(struct device_node* np);
 extern void prom_get_irq_senses(unsigned char *senses, int off, int max);
 extern void prom_add_property(struct device_node* np, struct property* prop);
+extern void early_init_devtree(void *params);
 
 #endif /* _PPC64_PROM_H */



More information about the Linuxppc64-dev mailing list