diff options
author | David S. Miller <davem@davemloft.net> | 2008-08-26 07:47:20 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-08-29 11:13:11 +0200 |
commit | e003934876e75f96f1445565d8c9084c07943253 (patch) | |
tree | ef44d634c4c1c98248bf3976a9ab0fa7231fd393 /arch/sparc/kernel | |
parent | sparc: Kill SBUS DVMA layer. (diff) | |
download | linux-e003934876e75f96f1445565d8c9084c07943253.tar.xz linux-e003934876e75f96f1445565d8c9084c07943253.zip |
sparc32: Make IOMMU and IO-UNIT init work with device nodes.
And stick the iommu archdata pointer into the generic OF device tree
of_device struct as well.
We still have to pass the sbus_bus object down into the routines so
that the SBUS bus objects get the iommu cookies set properly. After
drivers get converted to being pure OF drivers, that can go away.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel')
-rw-r--r-- | arch/sparc/kernel/ioport.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/arch/sparc/kernel/ioport.c b/arch/sparc/kernel/ioport.c index 2a8a847764d8..f6158c4a3995 100644 --- a/arch/sparc/kernel/ioport.c +++ b/arch/sparc/kernel/ioport.c @@ -46,6 +46,8 @@ #include <asm/page.h> #include <asm/pgalloc.h> #include <asm/dma.h> +#include <asm/iommu.h> +#include <asm/io-unit.h> #define mmu_inval_dma_area(p, l) /* Anton pulled it out for 2.4.0-xx */ @@ -515,18 +517,11 @@ void __init sbus_setup_iommu(struct sbus_bus *sbus, struct device_node *dp) if (sparc_cpu_model != sun4d && parent != NULL && - !strcmp(parent->name, "iommu")) { - extern void iommu_init(int iommu_node, struct sbus_bus *sbus); + !strcmp(parent->name, "iommu")) + iommu_init(parent, sbus); - iommu_init(parent->node, sbus); - } - - if (sparc_cpu_model == sun4d) { - extern void iounit_init(int sbi_node, int iounit_node, - struct sbus_bus *sbus); - - iounit_init(dp->node, parent->node, sbus); - } + if (sparc_cpu_model == sun4d) + iounit_init(sbus); #endif } |