]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[POWERPC] Simplify vio_bus_init a little for legacy iSeries
authorStephen Rothwell <sfr@canb.auug.org.au>
Fri, 21 Sep 2007 04:31:02 +0000 (14:31 +1000)
committerPaul Mackerras <paulus@samba.org>
Wed, 3 Oct 2007 01:48:43 +0000 (11:48 +1000)
iSeries_vio_dev was already statically initialised and we can remove
one set of #ifdef CONFIG_PPC_ISERIES guards.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/vio.c

index 54645baab652f8d8bf4def258424ff9c7f33a2a4..ee15c2280aea667d3f0a8aa53632ab42001120ba 100644 (file)
@@ -64,6 +64,12 @@ static void __init iommu_vio_init(void)
                printk("Virtual Bus VETH TCE table failed.\n");
        if (!iommu_init_table(&vio_iommu_table, -1))
                printk("Virtual Bus VIO TCE table failed.\n");
+       vio_bus_device.dev.archdata.dma_ops = &dma_iommu_ops;
+       vio_bus_device.dev.archdata.dma_data = &vio_iommu_table;
+}
+#else
+static void __init iommu_vio_init(void)
+{
 }
 #endif
 
@@ -282,14 +288,8 @@ static int __init vio_bus_init(void)
        int err;
        struct device_node *node_vroot;
 
-#ifdef CONFIG_PPC_ISERIES
-       if (firmware_has_feature(FW_FEATURE_ISERIES)) {
+       if (firmware_has_feature(FW_FEATURE_ISERIES))
                iommu_vio_init();
-               vio_bus_device.dev.archdata.dma_ops = &dma_iommu_ops;
-               vio_bus_device.dev.archdata.dma_data = &vio_iommu_table;
-               iSeries_vio_dev = &vio_bus_device.dev;
-       }
-#endif /* CONFIG_PPC_ISERIES */
 
        err = bus_register(&vio_bus_type);
        if (err) {