aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/mm/ioremap.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sh/mm/ioremap.c')
-rw-r--r--arch/sh/mm/ioremap.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/sh/mm/ioremap.c b/arch/sh/mm/ioremap.c
index 9f490c2742f0..e794e27a72f1 100644
--- a/arch/sh/mm/ioremap.c
+++ b/arch/sh/mm/ioremap.c
@@ -57,7 +57,7 @@ static inline int remap_area_pmd(pmd_t * pmd, unsigned long address,
57 if (address >= end) 57 if (address >= end)
58 BUG(); 58 BUG();
59 do { 59 do {
60 pte_t * pte = pte_alloc_kernel(&init_mm, pmd, address); 60 pte_t * pte = pte_alloc_kernel(pmd, address);
61 if (!pte) 61 if (!pte)
62 return -ENOMEM; 62 return -ENOMEM;
63 remap_area_pte(pte, address, end - address, address + phys_addr, flags); 63 remap_area_pte(pte, address, end - address, address + phys_addr, flags);
@@ -79,7 +79,6 @@ int remap_area_pages(unsigned long address, unsigned long phys_addr,
79 flush_cache_all(); 79 flush_cache_all();
80 if (address >= end) 80 if (address >= end)
81 BUG(); 81 BUG();
82 spin_lock(&init_mm.page_table_lock);
83 do { 82 do {
84 pmd_t *pmd; 83 pmd_t *pmd;
85 pmd = pmd_alloc(&init_mm, dir, address); 84 pmd = pmd_alloc(&init_mm, dir, address);
@@ -93,7 +92,6 @@ int remap_area_pages(unsigned long address, unsigned long phys_addr,
93 address = (address + PGDIR_SIZE) & PGDIR_MASK; 92 address = (address + PGDIR_SIZE) & PGDIR_MASK;
94 dir++; 93 dir++;
95 } while (address && (address < end)); 94 } while (address && (address < end));
96 spin_unlock(&init_mm.page_table_lock);
97 flush_tlb_all(); 95 flush_tlb_all();
98 return error; 96 return error;
99} 97}