diff options
Diffstat (limited to 'arch/sh/mm/pg-sh4.c')
-rw-r--r-- | arch/sh/mm/pg-sh4.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/arch/sh/mm/pg-sh4.c b/arch/sh/mm/pg-sh4.c index 07371ed7a313..e973ac3b13be 100644 --- a/arch/sh/mm/pg-sh4.c +++ b/arch/sh/mm/pg-sh4.c | |||
@@ -37,10 +37,6 @@ void clear_user_page(void *to, unsigned long address, struct page *page) | |||
37 | if (((address ^ (unsigned long)to) & CACHE_ALIAS) == 0) | 37 | if (((address ^ (unsigned long)to) & CACHE_ALIAS) == 0) |
38 | clear_page(to); | 38 | clear_page(to); |
39 | else { | 39 | else { |
40 | pgprot_t pgprot = __pgprot(_PAGE_PRESENT | | ||
41 | _PAGE_RW | _PAGE_CACHABLE | | ||
42 | _PAGE_DIRTY | _PAGE_ACCESSED | | ||
43 | _PAGE_HW_SHARED | _PAGE_FLAGS_HARD); | ||
44 | unsigned long phys_addr = PHYSADDR(to); | 40 | unsigned long phys_addr = PHYSADDR(to); |
45 | unsigned long p3_addr = P3SEG + (address & CACHE_ALIAS); | 41 | unsigned long p3_addr = P3SEG + (address & CACHE_ALIAS); |
46 | pgd_t *pgd = pgd_offset_k(p3_addr); | 42 | pgd_t *pgd = pgd_offset_k(p3_addr); |
@@ -50,7 +46,7 @@ void clear_user_page(void *to, unsigned long address, struct page *page) | |||
50 | pte_t entry; | 46 | pte_t entry; |
51 | unsigned long flags; | 47 | unsigned long flags; |
52 | 48 | ||
53 | entry = pfn_pte(phys_addr >> PAGE_SHIFT, pgprot); | 49 | entry = pfn_pte(phys_addr >> PAGE_SHIFT, PAGE_KERNEL); |
54 | down(&p3map_sem[(address & CACHE_ALIAS)>>12]); | 50 | down(&p3map_sem[(address & CACHE_ALIAS)>>12]); |
55 | set_pte(pte, entry); | 51 | set_pte(pte, entry); |
56 | local_irq_save(flags); | 52 | local_irq_save(flags); |
@@ -77,10 +73,6 @@ void copy_user_page(void *to, void *from, unsigned long address, | |||
77 | if (((address ^ (unsigned long)to) & CACHE_ALIAS) == 0) | 73 | if (((address ^ (unsigned long)to) & CACHE_ALIAS) == 0) |
78 | copy_page(to, from); | 74 | copy_page(to, from); |
79 | else { | 75 | else { |
80 | pgprot_t pgprot = __pgprot(_PAGE_PRESENT | | ||
81 | _PAGE_RW | _PAGE_CACHABLE | | ||
82 | _PAGE_DIRTY | _PAGE_ACCESSED | | ||
83 | _PAGE_HW_SHARED | _PAGE_FLAGS_HARD); | ||
84 | unsigned long phys_addr = PHYSADDR(to); | 76 | unsigned long phys_addr = PHYSADDR(to); |
85 | unsigned long p3_addr = P3SEG + (address & CACHE_ALIAS); | 77 | unsigned long p3_addr = P3SEG + (address & CACHE_ALIAS); |
86 | pgd_t *pgd = pgd_offset_k(p3_addr); | 78 | pgd_t *pgd = pgd_offset_k(p3_addr); |
@@ -90,7 +82,7 @@ void copy_user_page(void *to, void *from, unsigned long address, | |||
90 | pte_t entry; | 82 | pte_t entry; |
91 | unsigned long flags; | 83 | unsigned long flags; |
92 | 84 | ||
93 | entry = pfn_pte(phys_addr >> PAGE_SHIFT, pgprot); | 85 | entry = pfn_pte(phys_addr >> PAGE_SHIFT, PAGE_KERNEL); |
94 | down(&p3map_sem[(address & CACHE_ALIAS)>>12]); | 86 | down(&p3map_sem[(address & CACHE_ALIAS)>>12]); |
95 | set_pte(pte, entry); | 87 | set_pte(pte, entry); |
96 | local_irq_save(flags); | 88 | local_irq_save(flags); |