diff options
Diffstat (limited to 'arch/sparc/mm/sun4c.c')
| -rw-r--r-- | arch/sparc/mm/sun4c.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/arch/sparc/mm/sun4c.c b/arch/sparc/mm/sun4c.c index 731f19603cad..49f28c1bdc6d 100644 --- a/arch/sparc/mm/sun4c.c +++ b/arch/sparc/mm/sun4c.c | |||
| @@ -1589,7 +1589,10 @@ static void sun4c_flush_tlb_page(struct vm_area_struct *vma, unsigned long page) | |||
| 1589 | 1589 | ||
| 1590 | static inline void sun4c_mapioaddr(unsigned long physaddr, unsigned long virt_addr) | 1590 | static inline void sun4c_mapioaddr(unsigned long physaddr, unsigned long virt_addr) |
| 1591 | { | 1591 | { |
| 1592 | unsigned long page_entry; | 1592 | unsigned long page_entry, pg_iobits; |
| 1593 | |||
| 1594 | pg_iobits = _SUN4C_PAGE_PRESENT | _SUN4C_READABLE | _SUN4C_WRITEABLE | | ||
| 1595 | _SUN4C_PAGE_IO | _SUN4C_PAGE_NOCACHE; | ||
| 1593 | 1596 | ||
| 1594 | page_entry = ((physaddr >> PAGE_SHIFT) & SUN4C_PFN_MASK); | 1597 | page_entry = ((physaddr >> PAGE_SHIFT) & SUN4C_PFN_MASK); |
| 1595 | page_entry |= ((pg_iobits | _SUN4C_PAGE_PRIV) & ~(_SUN4C_PAGE_PRESENT)); | 1598 | page_entry |= ((pg_iobits | _SUN4C_PAGE_PRIV) & ~(_SUN4C_PAGE_PRESENT)); |
| @@ -2134,6 +2137,13 @@ void __init sun4c_paging_init(void) | |||
| 2134 | printk("SUN4C: %d mmu entries for the kernel\n", cnt); | 2137 | printk("SUN4C: %d mmu entries for the kernel\n", cnt); |
| 2135 | } | 2138 | } |
| 2136 | 2139 | ||
| 2140 | static pgprot_t sun4c_pgprot_noncached(pgprot_t prot) | ||
| 2141 | { | ||
| 2142 | prot |= __pgprot(_SUN4C_PAGE_IO | _SUN4C_PAGE_NOCACHE); | ||
| 2143 | |||
| 2144 | return prot; | ||
| 2145 | } | ||
| 2146 | |||
| 2137 | /* Load up routines and constants for sun4c mmu */ | 2147 | /* Load up routines and constants for sun4c mmu */ |
| 2138 | void __init ld_mmu_sun4c(void) | 2148 | void __init ld_mmu_sun4c(void) |
| 2139 | { | 2149 | { |
| @@ -2156,10 +2166,9 @@ void __init ld_mmu_sun4c(void) | |||
| 2156 | BTFIXUPSET_INT(page_readonly, pgprot_val(SUN4C_PAGE_READONLY)); | 2166 | BTFIXUPSET_INT(page_readonly, pgprot_val(SUN4C_PAGE_READONLY)); |
| 2157 | BTFIXUPSET_INT(page_kernel, pgprot_val(SUN4C_PAGE_KERNEL)); | 2167 | BTFIXUPSET_INT(page_kernel, pgprot_val(SUN4C_PAGE_KERNEL)); |
| 2158 | page_kernel = pgprot_val(SUN4C_PAGE_KERNEL); | 2168 | page_kernel = pgprot_val(SUN4C_PAGE_KERNEL); |
| 2159 | pg_iobits = _SUN4C_PAGE_PRESENT | _SUN4C_READABLE | _SUN4C_WRITEABLE | | ||
| 2160 | _SUN4C_PAGE_IO | _SUN4C_PAGE_NOCACHE; | ||
| 2161 | 2169 | ||
| 2162 | /* Functions */ | 2170 | /* Functions */ |
| 2171 | BTFIXUPSET_CALL(pgprot_noncached, sun4c_pgprot_noncached, BTFIXUPCALL_NORM); | ||
| 2163 | BTFIXUPSET_CALL(___xchg32, ___xchg32_sun4c, BTFIXUPCALL_NORM); | 2172 | BTFIXUPSET_CALL(___xchg32, ___xchg32_sun4c, BTFIXUPCALL_NORM); |
| 2164 | BTFIXUPSET_CALL(do_check_pgt_cache, sun4c_check_pgt_cache, BTFIXUPCALL_NORM); | 2173 | BTFIXUPSET_CALL(do_check_pgt_cache, sun4c_check_pgt_cache, BTFIXUPCALL_NORM); |
| 2165 | 2174 | ||
