diff options
Diffstat (limited to 'arch/sh/mm')
-rw-r--r-- | arch/sh/mm/cache-debugfs.c | 4 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh2.c | 12 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh2a.c | 20 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh3.c | 6 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh4.c | 10 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh7705.c | 8 | ||||
-rw-r--r-- | arch/sh/mm/pmb.c | 24 | ||||
-rw-r--r-- | arch/sh/mm/tlb-sh3.c | 6 | ||||
-rw-r--r-- | arch/sh/mm/tlb-sh4.c | 10 | ||||
-rw-r--r-- | arch/sh/mm/tlbflush_32.c | 4 |
10 files changed, 52 insertions, 52 deletions
diff --git a/arch/sh/mm/cache-debugfs.c b/arch/sh/mm/cache-debugfs.c index 48ce82ee9fd2..690ed010d002 100644 --- a/arch/sh/mm/cache-debugfs.c +++ b/arch/sh/mm/cache-debugfs.c | |||
@@ -36,7 +36,7 @@ static int cache_seq_show(struct seq_file *file, void *iter) | |||
36 | */ | 36 | */ |
37 | jump_to_uncached(); | 37 | jump_to_uncached(); |
38 | 38 | ||
39 | ccr = ctrl_inl(CCR); | 39 | ccr = __raw_readl(CCR); |
40 | if ((ccr & CCR_CACHE_ENABLE) == 0) { | 40 | if ((ccr & CCR_CACHE_ENABLE) == 0) { |
41 | back_to_cached(); | 41 | back_to_cached(); |
42 | 42 | ||
@@ -89,7 +89,7 @@ static int cache_seq_show(struct seq_file *file, void *iter) | |||
89 | for (addr = addrstart, line = 0; | 89 | for (addr = addrstart, line = 0; |
90 | addr < addrstart + waysize; | 90 | addr < addrstart + waysize; |
91 | addr += cache->linesz, line++) { | 91 | addr += cache->linesz, line++) { |
92 | unsigned long data = ctrl_inl(addr); | 92 | unsigned long data = __raw_readl(addr); |
93 | 93 | ||
94 | /* Check the V bit, ignore invalid cachelines */ | 94 | /* Check the V bit, ignore invalid cachelines */ |
95 | if ((data & 1) == 0) | 95 | if ((data & 1) == 0) |
diff --git a/arch/sh/mm/cache-sh2.c b/arch/sh/mm/cache-sh2.c index 699a71f46327..defcf719f2e8 100644 --- a/arch/sh/mm/cache-sh2.c +++ b/arch/sh/mm/cache-sh2.c | |||
@@ -28,10 +28,10 @@ static void sh2__flush_wback_region(void *start, int size) | |||
28 | unsigned long addr = CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0); | 28 | unsigned long addr = CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0); |
29 | int way; | 29 | int way; |
30 | for (way = 0; way < 4; way++) { | 30 | for (way = 0; way < 4; way++) { |
31 | unsigned long data = ctrl_inl(addr | (way << 12)); | 31 | unsigned long data = __raw_readl(addr | (way << 12)); |
32 | if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { | 32 | if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { |
33 | data &= ~SH_CACHE_UPDATED; | 33 | data &= ~SH_CACHE_UPDATED; |
34 | ctrl_outl(data, addr | (way << 12)); | 34 | __raw_writel(data, addr | (way << 12)); |
35 | } | 35 | } |
36 | } | 36 | } |
37 | } | 37 | } |
@@ -47,7 +47,7 @@ static void sh2__flush_purge_region(void *start, int size) | |||
47 | & ~(L1_CACHE_BYTES-1); | 47 | & ~(L1_CACHE_BYTES-1); |
48 | 48 | ||
49 | for (v = begin; v < end; v+=L1_CACHE_BYTES) | 49 | for (v = begin; v < end; v+=L1_CACHE_BYTES) |
50 | ctrl_outl((v & CACHE_PHYSADDR_MASK), | 50 | __raw_writel((v & CACHE_PHYSADDR_MASK), |
51 | CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0) | 0x00000008); | 51 | CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0) | 0x00000008); |
52 | } | 52 | } |
53 | 53 | ||
@@ -63,9 +63,9 @@ static void sh2__flush_invalidate_region(void *start, int size) | |||
63 | local_irq_save(flags); | 63 | local_irq_save(flags); |
64 | jump_to_uncached(); | 64 | jump_to_uncached(); |
65 | 65 | ||
66 | ccr = ctrl_inl(CCR); | 66 | ccr = __raw_readl(CCR); |
67 | ccr |= CCR_CACHE_INVALIDATE; | 67 | ccr |= CCR_CACHE_INVALIDATE; |
68 | ctrl_outl(ccr, CCR); | 68 | __raw_writel(ccr, CCR); |
69 | 69 | ||
70 | back_to_cached(); | 70 | back_to_cached(); |
71 | local_irq_restore(flags); | 71 | local_irq_restore(flags); |
@@ -78,7 +78,7 @@ static void sh2__flush_invalidate_region(void *start, int size) | |||
78 | & ~(L1_CACHE_BYTES-1); | 78 | & ~(L1_CACHE_BYTES-1); |
79 | 79 | ||
80 | for (v = begin; v < end; v+=L1_CACHE_BYTES) | 80 | for (v = begin; v < end; v+=L1_CACHE_BYTES) |
81 | ctrl_outl((v & CACHE_PHYSADDR_MASK), | 81 | __raw_writel((v & CACHE_PHYSADDR_MASK), |
82 | CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0) | 0x00000008); | 82 | CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0) | 0x00000008); |
83 | #endif | 83 | #endif |
84 | } | 84 | } |
diff --git a/arch/sh/mm/cache-sh2a.c b/arch/sh/mm/cache-sh2a.c index 975899d83564..1f51225426a2 100644 --- a/arch/sh/mm/cache-sh2a.c +++ b/arch/sh/mm/cache-sh2a.c | |||
@@ -32,10 +32,10 @@ static void sh2a__flush_wback_region(void *start, int size) | |||
32 | unsigned long addr = CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0); | 32 | unsigned long addr = CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0); |
33 | int way; | 33 | int way; |
34 | for (way = 0; way < 4; way++) { | 34 | for (way = 0; way < 4; way++) { |
35 | unsigned long data = ctrl_inl(addr | (way << 11)); | 35 | unsigned long data = __raw_readl(addr | (way << 11)); |
36 | if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { | 36 | if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { |
37 | data &= ~SH_CACHE_UPDATED; | 37 | data &= ~SH_CACHE_UPDATED; |
38 | ctrl_outl(data, addr | (way << 11)); | 38 | __raw_writel(data, addr | (way << 11)); |
39 | } | 39 | } |
40 | } | 40 | } |
41 | } | 41 | } |
@@ -58,7 +58,7 @@ static void sh2a__flush_purge_region(void *start, int size) | |||
58 | jump_to_uncached(); | 58 | jump_to_uncached(); |
59 | 59 | ||
60 | for (v = begin; v < end; v+=L1_CACHE_BYTES) { | 60 | for (v = begin; v < end; v+=L1_CACHE_BYTES) { |
61 | ctrl_outl((v & CACHE_PHYSADDR_MASK), | 61 | __raw_writel((v & CACHE_PHYSADDR_MASK), |
62 | CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); | 62 | CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); |
63 | } | 63 | } |
64 | back_to_cached(); | 64 | back_to_cached(); |
@@ -78,17 +78,17 @@ static void sh2a__flush_invalidate_region(void *start, int size) | |||
78 | jump_to_uncached(); | 78 | jump_to_uncached(); |
79 | 79 | ||
80 | #ifdef CONFIG_CACHE_WRITEBACK | 80 | #ifdef CONFIG_CACHE_WRITEBACK |
81 | ctrl_outl(ctrl_inl(CCR) | CCR_OCACHE_INVALIDATE, CCR); | 81 | __raw_writel(__raw_readl(CCR) | CCR_OCACHE_INVALIDATE, CCR); |
82 | /* I-cache invalidate */ | 82 | /* I-cache invalidate */ |
83 | for (v = begin; v < end; v+=L1_CACHE_BYTES) { | 83 | for (v = begin; v < end; v+=L1_CACHE_BYTES) { |
84 | ctrl_outl((v & CACHE_PHYSADDR_MASK), | 84 | __raw_writel((v & CACHE_PHYSADDR_MASK), |
85 | CACHE_IC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); | 85 | CACHE_IC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); |
86 | } | 86 | } |
87 | #else | 87 | #else |
88 | for (v = begin; v < end; v+=L1_CACHE_BYTES) { | 88 | for (v = begin; v < end; v+=L1_CACHE_BYTES) { |
89 | ctrl_outl((v & CACHE_PHYSADDR_MASK), | 89 | __raw_writel((v & CACHE_PHYSADDR_MASK), |
90 | CACHE_IC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); | 90 | CACHE_IC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); |
91 | ctrl_outl((v & CACHE_PHYSADDR_MASK), | 91 | __raw_writel((v & CACHE_PHYSADDR_MASK), |
92 | CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); | 92 | CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0) | 0x00000008); |
93 | } | 93 | } |
94 | #endif | 94 | #endif |
@@ -115,14 +115,14 @@ static void sh2a_flush_icache_range(void *args) | |||
115 | int way; | 115 | int way; |
116 | /* O-Cache writeback */ | 116 | /* O-Cache writeback */ |
117 | for (way = 0; way < 4; way++) { | 117 | for (way = 0; way < 4; way++) { |
118 | unsigned long data = ctrl_inl(CACHE_OC_ADDRESS_ARRAY | addr | (way << 11)); | 118 | unsigned long data = __raw_readl(CACHE_OC_ADDRESS_ARRAY | addr | (way << 11)); |
119 | if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { | 119 | if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { |
120 | data &= ~SH_CACHE_UPDATED; | 120 | data &= ~SH_CACHE_UPDATED; |
121 | ctrl_outl(data, CACHE_OC_ADDRESS_ARRAY | addr | (way << 11)); | 121 | __raw_writel(data, CACHE_OC_ADDRESS_ARRAY | addr | (way << 11)); |
122 | } | 122 | } |
123 | } | 123 | } |
124 | /* I-Cache invalidate */ | 124 | /* I-Cache invalidate */ |
125 | ctrl_outl(addr, | 125 | __raw_writel(addr, |
126 | CACHE_IC_ADDRESS_ARRAY | addr | 0x00000008); | 126 | CACHE_IC_ADDRESS_ARRAY | addr | 0x00000008); |
127 | } | 127 | } |
128 | 128 | ||
diff --git a/arch/sh/mm/cache-sh3.c b/arch/sh/mm/cache-sh3.c index faef80c98134..e37523f65195 100644 --- a/arch/sh/mm/cache-sh3.c +++ b/arch/sh/mm/cache-sh3.c | |||
@@ -50,12 +50,12 @@ static void sh3__flush_wback_region(void *start, int size) | |||
50 | p = __pa(v); | 50 | p = __pa(v); |
51 | addr = addrstart | (v & current_cpu_data.dcache.entry_mask); | 51 | addr = addrstart | (v & current_cpu_data.dcache.entry_mask); |
52 | local_irq_save(flags); | 52 | local_irq_save(flags); |
53 | data = ctrl_inl(addr); | 53 | data = __raw_readl(addr); |
54 | 54 | ||
55 | if ((data & CACHE_PHYSADDR_MASK) == | 55 | if ((data & CACHE_PHYSADDR_MASK) == |
56 | (p & CACHE_PHYSADDR_MASK)) { | 56 | (p & CACHE_PHYSADDR_MASK)) { |
57 | data &= ~SH_CACHE_UPDATED; | 57 | data &= ~SH_CACHE_UPDATED; |
58 | ctrl_outl(data, addr); | 58 | __raw_writel(data, addr); |
59 | local_irq_restore(flags); | 59 | local_irq_restore(flags); |
60 | break; | 60 | break; |
61 | } | 61 | } |
@@ -86,7 +86,7 @@ static void sh3__flush_purge_region(void *start, int size) | |||
86 | data = (v & 0xfffffc00); /* _Virtual_ address, ~U, ~V */ | 86 | data = (v & 0xfffffc00); /* _Virtual_ address, ~U, ~V */ |
87 | addr = CACHE_OC_ADDRESS_ARRAY | | 87 | addr = CACHE_OC_ADDRESS_ARRAY | |
88 | (v & current_cpu_data.dcache.entry_mask) | SH_CACHE_ASSOC; | 88 | (v & current_cpu_data.dcache.entry_mask) | SH_CACHE_ASSOC; |
89 | ctrl_outl(data, addr); | 89 | __raw_writel(data, addr); |
90 | } | 90 | } |
91 | } | 91 | } |
92 | 92 | ||
diff --git a/arch/sh/mm/cache-sh4.c b/arch/sh/mm/cache-sh4.c index 87115b3ee70e..2cfae81914aa 100644 --- a/arch/sh/mm/cache-sh4.c +++ b/arch/sh/mm/cache-sh4.c | |||
@@ -132,9 +132,9 @@ static void flush_icache_all(void) | |||
132 | jump_to_uncached(); | 132 | jump_to_uncached(); |
133 | 133 | ||
134 | /* Flush I-cache */ | 134 | /* Flush I-cache */ |
135 | ccr = ctrl_inl(CCR); | 135 | ccr = __raw_readl(CCR); |
136 | ccr |= CCR_CACHE_ICI; | 136 | ccr |= CCR_CACHE_ICI; |
137 | ctrl_outl(ccr, CCR); | 137 | __raw_writel(ccr, CCR); |
138 | 138 | ||
139 | /* | 139 | /* |
140 | * back_to_cached() will take care of the barrier for us, don't add | 140 | * back_to_cached() will take care of the barrier for us, don't add |
@@ -377,9 +377,9 @@ extern void __weak sh4__flush_region_init(void); | |||
377 | void __init sh4_cache_init(void) | 377 | void __init sh4_cache_init(void) |
378 | { | 378 | { |
379 | printk("PVR=%08x CVR=%08x PRR=%08x\n", | 379 | printk("PVR=%08x CVR=%08x PRR=%08x\n", |
380 | ctrl_inl(CCN_PVR), | 380 | __raw_readl(CCN_PVR), |
381 | ctrl_inl(CCN_CVR), | 381 | __raw_readl(CCN_CVR), |
382 | ctrl_inl(CCN_PRR)); | 382 | __raw_readl(CCN_PRR)); |
383 | 383 | ||
384 | local_flush_icache_range = sh4_flush_icache_range; | 384 | local_flush_icache_range = sh4_flush_icache_range; |
385 | local_flush_dcache_page = sh4_flush_dcache_page; | 385 | local_flush_dcache_page = sh4_flush_dcache_page; |
diff --git a/arch/sh/mm/cache-sh7705.c b/arch/sh/mm/cache-sh7705.c index 870293ee539e..f498da1cce7a 100644 --- a/arch/sh/mm/cache-sh7705.c +++ b/arch/sh/mm/cache-sh7705.c | |||
@@ -48,10 +48,10 @@ static inline void cache_wback_all(void) | |||
48 | unsigned long data; | 48 | unsigned long data; |
49 | int v = SH_CACHE_UPDATED | SH_CACHE_VALID; | 49 | int v = SH_CACHE_UPDATED | SH_CACHE_VALID; |
50 | 50 | ||
51 | data = ctrl_inl(addr); | 51 | data = __raw_readl(addr); |
52 | 52 | ||
53 | if ((data & v) == v) | 53 | if ((data & v) == v) |
54 | ctrl_outl(data & ~v, addr); | 54 | __raw_writel(data & ~v, addr); |
55 | 55 | ||
56 | } | 56 | } |
57 | 57 | ||
@@ -115,10 +115,10 @@ static void __flush_dcache_page(unsigned long phys) | |||
115 | addr += current_cpu_data.dcache.linesz) { | 115 | addr += current_cpu_data.dcache.linesz) { |
116 | unsigned long data; | 116 | unsigned long data; |
117 | 117 | ||
118 | data = ctrl_inl(addr) & (0x1ffffC00 | SH_CACHE_VALID); | 118 | data = __raw_readl(addr) & (0x1ffffC00 | SH_CACHE_VALID); |
119 | if (data == phys) { | 119 | if (data == phys) { |
120 | data &= ~(SH_CACHE_VALID | SH_CACHE_UPDATED); | 120 | data &= ~(SH_CACHE_VALID | SH_CACHE_UPDATED); |
121 | ctrl_outl(data, addr); | 121 | __raw_writel(data, addr); |
122 | } | 122 | } |
123 | } | 123 | } |
124 | 124 | ||
diff --git a/arch/sh/mm/pmb.c b/arch/sh/mm/pmb.c index 3d5eece7e6d0..3c9bf5b5c36f 100644 --- a/arch/sh/mm/pmb.c +++ b/arch/sh/mm/pmb.c | |||
@@ -112,7 +112,7 @@ static void pmb_free(struct pmb_entry *pmbe) | |||
112 | static void __set_pmb_entry(unsigned long vpn, unsigned long ppn, | 112 | static void __set_pmb_entry(unsigned long vpn, unsigned long ppn, |
113 | unsigned long flags, int pos) | 113 | unsigned long flags, int pos) |
114 | { | 114 | { |
115 | ctrl_outl(vpn | PMB_V, mk_pmb_addr(pos)); | 115 | __raw_writel(vpn | PMB_V, mk_pmb_addr(pos)); |
116 | 116 | ||
117 | #ifdef CONFIG_CACHE_WRITETHROUGH | 117 | #ifdef CONFIG_CACHE_WRITETHROUGH |
118 | /* | 118 | /* |
@@ -124,7 +124,7 @@ static void __set_pmb_entry(unsigned long vpn, unsigned long ppn, | |||
124 | flags |= PMB_WT; | 124 | flags |= PMB_WT; |
125 | #endif | 125 | #endif |
126 | 126 | ||
127 | ctrl_outl(ppn | flags | PMB_V, mk_pmb_data(pos)); | 127 | __raw_writel(ppn | flags | PMB_V, mk_pmb_data(pos)); |
128 | } | 128 | } |
129 | 129 | ||
130 | static void set_pmb_entry(struct pmb_entry *pmbe) | 130 | static void set_pmb_entry(struct pmb_entry *pmbe) |
@@ -146,10 +146,10 @@ static void clear_pmb_entry(struct pmb_entry *pmbe) | |||
146 | 146 | ||
147 | /* Clear V-bit */ | 147 | /* Clear V-bit */ |
148 | addr = mk_pmb_addr(entry); | 148 | addr = mk_pmb_addr(entry); |
149 | ctrl_outl(ctrl_inl(addr) & ~PMB_V, addr); | 149 | __raw_writel(__raw_readl(addr) & ~PMB_V, addr); |
150 | 150 | ||
151 | addr = mk_pmb_data(entry); | 151 | addr = mk_pmb_data(entry); |
152 | ctrl_outl(ctrl_inl(addr) & ~PMB_V, addr); | 152 | __raw_writel(__raw_readl(addr) & ~PMB_V, addr); |
153 | 153 | ||
154 | back_to_cached(); | 154 | back_to_cached(); |
155 | } | 155 | } |
@@ -395,7 +395,7 @@ int pmb_init(void) | |||
395 | unsigned long vpn, ppn, flags; | 395 | unsigned long vpn, ppn, flags; |
396 | 396 | ||
397 | addr = PMB_DATA + (i << PMB_E_SHIFT); | 397 | addr = PMB_DATA + (i << PMB_E_SHIFT); |
398 | data = ctrl_inl(addr); | 398 | data = __raw_readl(addr); |
399 | if (!(data & PMB_V)) | 399 | if (!(data & PMB_V)) |
400 | continue; | 400 | continue; |
401 | 401 | ||
@@ -408,7 +408,7 @@ int pmb_init(void) | |||
408 | data &= ~(PMB_C | PMB_WT); | 408 | data &= ~(PMB_C | PMB_WT); |
409 | #endif | 409 | #endif |
410 | } | 410 | } |
411 | ctrl_outl(data, addr); | 411 | __raw_writel(data, addr); |
412 | 412 | ||
413 | ppn = data & PMB_PFN_MASK; | 413 | ppn = data & PMB_PFN_MASK; |
414 | 414 | ||
@@ -416,7 +416,7 @@ int pmb_init(void) | |||
416 | flags |= data & PMB_SZ_MASK; | 416 | flags |= data & PMB_SZ_MASK; |
417 | 417 | ||
418 | addr = PMB_ADDR + (i << PMB_E_SHIFT); | 418 | addr = PMB_ADDR + (i << PMB_E_SHIFT); |
419 | data = ctrl_inl(addr); | 419 | data = __raw_readl(addr); |
420 | 420 | ||
421 | vpn = data & PMB_PFN_MASK; | 421 | vpn = data & PMB_PFN_MASK; |
422 | 422 | ||
@@ -424,12 +424,12 @@ int pmb_init(void) | |||
424 | WARN_ON(IS_ERR(pmbe)); | 424 | WARN_ON(IS_ERR(pmbe)); |
425 | } | 425 | } |
426 | 426 | ||
427 | ctrl_outl(0, PMB_IRMCR); | 427 | __raw_writel(0, PMB_IRMCR); |
428 | 428 | ||
429 | /* Flush out the TLB */ | 429 | /* Flush out the TLB */ |
430 | i = ctrl_inl(MMUCR); | 430 | i = __raw_readl(MMUCR); |
431 | i |= MMUCR_TI; | 431 | i |= MMUCR_TI; |
432 | ctrl_outl(i, MMUCR); | 432 | __raw_writel(i, MMUCR); |
433 | 433 | ||
434 | back_to_cached(); | 434 | back_to_cached(); |
435 | 435 | ||
@@ -454,8 +454,8 @@ static int pmb_seq_show(struct seq_file *file, void *iter) | |||
454 | unsigned int size; | 454 | unsigned int size; |
455 | char *sz_str = NULL; | 455 | char *sz_str = NULL; |
456 | 456 | ||
457 | addr = ctrl_inl(mk_pmb_addr(i)); | 457 | addr = __raw_readl(mk_pmb_addr(i)); |
458 | data = ctrl_inl(mk_pmb_data(i)); | 458 | data = __raw_readl(mk_pmb_data(i)); |
459 | 459 | ||
460 | size = data & PMB_SZ_MASK; | 460 | size = data & PMB_SZ_MASK; |
461 | sz_str = (size == PMB_SZ_16M) ? " 16MB": | 461 | sz_str = (size == PMB_SZ_16M) ? " 16MB": |
diff --git a/arch/sh/mm/tlb-sh3.c b/arch/sh/mm/tlb-sh3.c index ace8e6d2f59d..4f5f7cbdd508 100644 --- a/arch/sh/mm/tlb-sh3.c +++ b/arch/sh/mm/tlb-sh3.c | |||
@@ -41,14 +41,14 @@ void __update_tlb(struct vm_area_struct *vma, unsigned long address, pte_t pte) | |||
41 | 41 | ||
42 | /* Set PTEH register */ | 42 | /* Set PTEH register */ |
43 | vpn = (address & MMU_VPN_MASK) | get_asid(); | 43 | vpn = (address & MMU_VPN_MASK) | get_asid(); |
44 | ctrl_outl(vpn, MMU_PTEH); | 44 | __raw_writel(vpn, MMU_PTEH); |
45 | 45 | ||
46 | pteval = pte_val(pte); | 46 | pteval = pte_val(pte); |
47 | 47 | ||
48 | /* Set PTEL register */ | 48 | /* Set PTEL register */ |
49 | pteval &= _PAGE_FLAGS_HARDWARE_MASK; /* drop software flags */ | 49 | pteval &= _PAGE_FLAGS_HARDWARE_MASK; /* drop software flags */ |
50 | /* conveniently, we want all the software flags to be 0 anyway */ | 50 | /* conveniently, we want all the software flags to be 0 anyway */ |
51 | ctrl_outl(pteval, MMU_PTEL); | 51 | __raw_writel(pteval, MMU_PTEL); |
52 | 52 | ||
53 | /* Load the TLB */ | 53 | /* Load the TLB */ |
54 | asm volatile("ldtlb": /* no output */ : /* no input */ : "memory"); | 54 | asm volatile("ldtlb": /* no output */ : /* no input */ : "memory"); |
@@ -75,5 +75,5 @@ void local_flush_tlb_one(unsigned long asid, unsigned long page) | |||
75 | } | 75 | } |
76 | 76 | ||
77 | for (i = 0; i < ways; i++) | 77 | for (i = 0; i < ways; i++) |
78 | ctrl_outl(data, addr + (i << 8)); | 78 | __raw_writel(data, addr + (i << 8)); |
79 | } | 79 | } |
diff --git a/arch/sh/mm/tlb-sh4.c b/arch/sh/mm/tlb-sh4.c index 624c1daa9f3f..ccac77f504a8 100644 --- a/arch/sh/mm/tlb-sh4.c +++ b/arch/sh/mm/tlb-sh4.c | |||
@@ -29,7 +29,7 @@ void __update_tlb(struct vm_area_struct *vma, unsigned long address, pte_t pte) | |||
29 | 29 | ||
30 | /* Set PTEH register */ | 30 | /* Set PTEH register */ |
31 | vpn = (address & MMU_VPN_MASK) | get_asid(); | 31 | vpn = (address & MMU_VPN_MASK) | get_asid(); |
32 | ctrl_outl(vpn, MMU_PTEH); | 32 | __raw_writel(vpn, MMU_PTEH); |
33 | 33 | ||
34 | pteval = pte.pte_low; | 34 | pteval = pte.pte_low; |
35 | 35 | ||
@@ -41,13 +41,13 @@ void __update_tlb(struct vm_area_struct *vma, unsigned long address, pte_t pte) | |||
41 | * the protection bits (with the exception of the compat-mode SZ | 41 | * the protection bits (with the exception of the compat-mode SZ |
42 | * and PR bits, which are cleared) being written out in PTEL. | 42 | * and PR bits, which are cleared) being written out in PTEL. |
43 | */ | 43 | */ |
44 | ctrl_outl(pte.pte_high, MMU_PTEA); | 44 | __raw_writel(pte.pte_high, MMU_PTEA); |
45 | #else | 45 | #else |
46 | if (cpu_data->flags & CPU_HAS_PTEA) { | 46 | if (cpu_data->flags & CPU_HAS_PTEA) { |
47 | /* The last 3 bits and the first one of pteval contains | 47 | /* The last 3 bits and the first one of pteval contains |
48 | * the PTEA timing control and space attribute bits | 48 | * the PTEA timing control and space attribute bits |
49 | */ | 49 | */ |
50 | ctrl_outl(copy_ptea_attributes(pteval), MMU_PTEA); | 50 | __raw_writel(copy_ptea_attributes(pteval), MMU_PTEA); |
51 | } | 51 | } |
52 | #endif | 52 | #endif |
53 | 53 | ||
@@ -57,7 +57,7 @@ void __update_tlb(struct vm_area_struct *vma, unsigned long address, pte_t pte) | |||
57 | pteval |= _PAGE_WT; | 57 | pteval |= _PAGE_WT; |
58 | #endif | 58 | #endif |
59 | /* conveniently, we want all the software flags to be 0 anyway */ | 59 | /* conveniently, we want all the software flags to be 0 anyway */ |
60 | ctrl_outl(pteval, MMU_PTEL); | 60 | __raw_writel(pteval, MMU_PTEL); |
61 | 61 | ||
62 | /* Load the TLB */ | 62 | /* Load the TLB */ |
63 | asm volatile("ldtlb": /* no output */ : /* no input */ : "memory"); | 63 | asm volatile("ldtlb": /* no output */ : /* no input */ : "memory"); |
@@ -77,6 +77,6 @@ void local_flush_tlb_one(unsigned long asid, unsigned long page) | |||
77 | addr = MMU_UTLB_ADDRESS_ARRAY | MMU_PAGE_ASSOC_BIT; | 77 | addr = MMU_UTLB_ADDRESS_ARRAY | MMU_PAGE_ASSOC_BIT; |
78 | data = page | asid; /* VALID bit is off */ | 78 | data = page | asid; /* VALID bit is off */ |
79 | jump_to_uncached(); | 79 | jump_to_uncached(); |
80 | ctrl_outl(data, addr); | 80 | __raw_writel(data, addr); |
81 | back_to_cached(); | 81 | back_to_cached(); |
82 | } | 82 | } |
diff --git a/arch/sh/mm/tlbflush_32.c b/arch/sh/mm/tlbflush_32.c index 6f45c1f8a7fe..004bb3f25b5f 100644 --- a/arch/sh/mm/tlbflush_32.c +++ b/arch/sh/mm/tlbflush_32.c | |||
@@ -132,9 +132,9 @@ void local_flush_tlb_all(void) | |||
132 | * It's same position, bit #2. | 132 | * It's same position, bit #2. |
133 | */ | 133 | */ |
134 | local_irq_save(flags); | 134 | local_irq_save(flags); |
135 | status = ctrl_inl(MMUCR); | 135 | status = __raw_readl(MMUCR); |
136 | status |= 0x04; | 136 | status |= 0x04; |
137 | ctrl_outl(status, MMUCR); | 137 | __raw_writel(status, MMUCR); |
138 | ctrl_barrier(); | 138 | ctrl_barrier(); |
139 | local_irq_restore(flags); | 139 | local_irq_restore(flags); |
140 | } | 140 | } |