aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/sbus.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sparc64/kernel/sbus.c')
-rw-r--r--arch/sparc64/kernel/sbus.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/arch/sparc64/kernel/sbus.c b/arch/sparc64/kernel/sbus.c
index d403f3df2dc2..279758d56b29 100644
--- a/arch/sparc64/kernel/sbus.c
+++ b/arch/sparc64/kernel/sbus.c
@@ -26,16 +26,10 @@
26 26
27#define MAP_BASE ((u32)0xc0000000) 27#define MAP_BASE ((u32)0xc0000000)
28 28
29struct sbus_iommu_arena {
30 unsigned long *map;
31 unsigned int hint;
32 unsigned int limit;
33};
34
35struct sbus_iommu { 29struct sbus_iommu {
36 spinlock_t lock; 30 spinlock_t lock;
37 31
38 struct sbus_iommu_arena arena; 32 struct iommu_arena arena;
39 33
40 iopte_t *page_table; 34 iopte_t *page_table;
41 unsigned long strbuf_regs; 35 unsigned long strbuf_regs;
@@ -123,7 +117,7 @@ static void sbus_strbuf_flush(struct sbus_iommu *iommu, u32 base, unsigned long
123/* Based largely upon the ppc64 iommu allocator. */ 117/* Based largely upon the ppc64 iommu allocator. */
124static long sbus_arena_alloc(struct sbus_iommu *iommu, unsigned long npages) 118static long sbus_arena_alloc(struct sbus_iommu *iommu, unsigned long npages)
125{ 119{
126 struct sbus_iommu_arena *arena = &iommu->arena; 120 struct iommu_arena *arena = &iommu->arena;
127 unsigned long n, i, start, end, limit; 121 unsigned long n, i, start, end, limit;
128 int pass; 122 int pass;
129 123
@@ -162,7 +156,7 @@ again:
162 return n; 156 return n;
163} 157}
164 158
165static void sbus_arena_free(struct sbus_iommu_arena *arena, unsigned long base, unsigned long npages) 159static void sbus_arena_free(struct iommu_arena *arena, unsigned long base, unsigned long npages)
166{ 160{
167 unsigned long i; 161 unsigned long i;
168 162