[PATCH 2/4] ppc64: move iSeries vio iommu init

Stephen Rothwell sfr at canb.auug.org.au
Tue Jul 12 17:42:49 EST 2005


Hi all,

Since the iSeries vio iommu tables cannot be used until after the vio bus has
been initialised, move the initialisation of the tables to there.

Signed-off-by: Stephen Rothwell <sfr at canb.auug.org.au>
---
 arch/ppc64/kernel/iSeries_vio.c |    3 ++-
 arch/ppc64/mm/init.c            |    3 ---
 include/asm-ppc64/iommu.h       |    3 ---
 3 files changed, 2 insertions(+), 7 deletions(-)

-- 
Cheers,
Stephen Rothwell                    sfr at canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

diff -ruNp linus-vio-init.1/arch/ppc64/kernel/iSeries_vio.c linus-vio-init.2/arch/ppc64/kernel/iSeries_vio.c
--- linus-vio-init.1/arch/ppc64/kernel/iSeries_vio.c	2005-06-24 17:31:30.000000000 +1000
+++ linus-vio-init.2/arch/ppc64/kernel/iSeries_vio.c	2005-06-26 06:23:28.000000000 +1000
@@ -27,7 +27,7 @@ EXPORT_SYMBOL(iSeries_vio_dev);
 static struct iommu_table veth_iommu_table;
 static struct iommu_table vio_iommu_table;
 
-void __init iommu_vio_init(void)
+static void __init iommu_vio_init(void)
 {
 	struct iommu_table *t;
 	struct iommu_table_cb cb;
@@ -123,6 +123,7 @@ static int __init vio_bus_init_iseries(v
 
 	err = vio_bus_init();
 	if (err == 0) {
+		iommu_vio_init();
 		vio_bus_device.iommu_table = &vio_iommu_table;
 		iSeries_vio_dev = &vio_bus_device.dev;
 		probe_bus_iseries();
diff -ruNp linus-vio-init.1/arch/ppc64/mm/init.c linus-vio-init.2/arch/ppc64/mm/init.c
--- linus-vio-init.1/arch/ppc64/mm/init.c	2005-06-27 16:08:00.000000000 +1000
+++ linus-vio-init.2/arch/ppc64/mm/init.c	2005-06-27 18:01:17.000000000 +1000
@@ -685,9 +685,6 @@ void __init mem_init(void)
 
 	mem_init_done = 1;
 
-#ifdef CONFIG_PPC_ISERIES
-	iommu_vio_init();
-#endif
 	/* Initialize the vDSO */
 	vdso_init();
 }
diff -ruNp linus-vio-init.1/include/asm-ppc64/iommu.h linus-vio-init.2/include/asm-ppc64/iommu.h
--- linus-vio-init.1/include/asm-ppc64/iommu.h	2005-06-27 16:08:08.000000000 +1000
+++ linus-vio-init.2/include/asm-ppc64/iommu.h	2005-06-27 18:01:17.000000000 +1000
@@ -104,9 +104,6 @@ extern void iommu_devnode_init_pSeries(s
 
 #ifdef CONFIG_PPC_ISERIES
 
-/* Initializes tables for bio buses */
-extern void __init iommu_vio_init(void);
-
 struct iSeries_Device_Node;
 /* Creates table for an individual device node */
 extern void iommu_devnode_init_iSeries(struct iSeries_Device_Node *dn);



More information about the Linuxppc64-dev mailing list