diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/mips/mm/init.c | 5 | ||||
-rw-r--r-- | arch/mips/sgi-ip22/ip22-platform.c | 4 | ||||
-rw-r--r-- | arch/mips/sgi-ip22/ip22-time.c | 4 |
3 files changed, 8 insertions, 5 deletions
diff --git a/arch/mips/mm/init.c b/arch/mips/mm/init.c index 09d91505b90c..5240432e6d1d 100644 --- a/arch/mips/mm/init.c +++ b/arch/mips/mm/init.c | |||
@@ -8,6 +8,7 @@ | |||
8 | * Kevin D. Kissell, kevink@mips.com and Carsten Langgaard, carstenl@mips.com | 8 | * Kevin D. Kissell, kevink@mips.com and Carsten Langgaard, carstenl@mips.com |
9 | * Copyright (C) 2000 MIPS Technologies, Inc. All rights reserved. | 9 | * Copyright (C) 2000 MIPS Technologies, Inc. All rights reserved. |
10 | */ | 10 | */ |
11 | #include <linux/bug.h> | ||
11 | #include <linux/init.h> | 12 | #include <linux/init.h> |
12 | #include <linux/module.h> | 13 | #include <linux/module.h> |
13 | #include <linux/signal.h> | 14 | #include <linux/signal.h> |
@@ -132,6 +133,8 @@ void *kmap_coherent(struct page *page, unsigned long addr) | |||
132 | pte_t pte; | 133 | pte_t pte; |
133 | int tlbidx; | 134 | int tlbidx; |
134 | 135 | ||
136 | BUG_ON(Page_dcache_dirty(page)); | ||
137 | |||
135 | inc_preempt_count(); | 138 | inc_preempt_count(); |
136 | idx = (addr >> PAGE_SHIFT) & (FIX_N_COLOURS - 1); | 139 | idx = (addr >> PAGE_SHIFT) & (FIX_N_COLOURS - 1); |
137 | #ifdef CONFIG_MIPS_MT_SMTC | 140 | #ifdef CONFIG_MIPS_MT_SMTC |
@@ -208,7 +211,7 @@ void copy_user_highpage(struct page *to, struct page *from, | |||
208 | void *vfrom, *vto; | 211 | void *vfrom, *vto; |
209 | 212 | ||
210 | vto = kmap_atomic(to, KM_USER1); | 213 | vto = kmap_atomic(to, KM_USER1); |
211 | if (cpu_has_dc_aliases) { | 214 | if (cpu_has_dc_aliases && !Page_dcache_dirty(from)) { |
212 | vfrom = kmap_coherent(from, vaddr); | 215 | vfrom = kmap_coherent(from, vaddr); |
213 | copy_page(vto, vfrom); | 216 | copy_page(vto, vfrom); |
214 | kunmap_coherent(); | 217 | kunmap_coherent(); |
diff --git a/arch/mips/sgi-ip22/ip22-platform.c b/arch/mips/sgi-ip22/ip22-platform.c index 78b608d2d4e1..28ffec8e5d1a 100644 --- a/arch/mips/sgi-ip22/ip22-platform.c +++ b/arch/mips/sgi-ip22/ip22-platform.c | |||
@@ -150,8 +150,8 @@ static int __init sgiseeq_devinit(void) | |||
150 | return res; | 150 | return res; |
151 | 151 | ||
152 | /* Second HPC is missing? */ | 152 | /* Second HPC is missing? */ |
153 | if (ip22_is_fullhouse() || | 153 | if (!ip22_is_fullhouse() || |
154 | !get_dbe(tmp, (unsigned int *)&hpc3c1->pbdma[1])) | 154 | get_dbe(tmp, (unsigned int *)&hpc3c1->pbdma[1])) |
155 | return 0; | 155 | return 0; |
156 | 156 | ||
157 | sgimc->giopar |= SGIMC_GIOPAR_MASTEREXP1 | SGIMC_GIOPAR_EXP164 | | 157 | sgimc->giopar |= SGIMC_GIOPAR_MASTEREXP1 | SGIMC_GIOPAR_EXP164 | |
diff --git a/arch/mips/sgi-ip22/ip22-time.c b/arch/mips/sgi-ip22/ip22-time.c index 8e88a442b22a..de3d01823ad5 100644 --- a/arch/mips/sgi-ip22/ip22-time.c +++ b/arch/mips/sgi-ip22/ip22-time.c | |||
@@ -114,8 +114,8 @@ static unsigned long dosample(void) | |||
114 | } while (msb); | 114 | } while (msb); |
115 | 115 | ||
116 | /* Stop the counter. */ | 116 | /* Stop the counter. */ |
117 | writeb(sgint->tcword, (SGINT_TCWORD_CNT2 | SGINT_TCWORD_CALL | | 117 | writeb(SGINT_TCWORD_CNT2 | SGINT_TCWORD_CALL | SGINT_TCWORD_MSWST, |
118 | SGINT_TCWORD_MSWST)); | 118 | &sgint->tcword); |
119 | /* | 119 | /* |
120 | * Return the difference, this is how far the r4k counter increments | 120 | * Return the difference, this is how far the r4k counter increments |
121 | * for every 1/HZ seconds. We round off the nearest 1 MHz of master | 121 | * for every 1/HZ seconds. We round off the nearest 1 MHz of master |