aboutsummaryrefslogtreecommitdiff
path: root/arch/powerpc/kernel
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2007-09-21 14:31:02 +1000
committerPaul Mackerras <paulus@samba.org>2007-10-03 11:48:43 +1000
commitc868078ed82e3651b16f68a420ae7568de2102db (patch)
treeff8ed1971307221a664910a36efea9512a89e655 /arch/powerpc/kernel
parentc546726293912c932f3c14d06b0f68e175d70781 (diff)
[POWERPC] Simplify vio_bus_init a little for legacy iSeries
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>
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r--arch/powerpc/kernel/vio.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/arch/powerpc/kernel/vio.c b/arch/powerpc/kernel/vio.c
index 54645baab65..ee15c2280ae 100644
--- a/arch/powerpc/kernel/vio.c
+++ b/arch/powerpc/kernel/vio.c
@@ -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) {