aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/mips/mm/pg-sb1.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/arch/mips/mm/pg-sb1.c b/arch/mips/mm/pg-sb1.c
index a3e98c243a89..89925ec57d6a 100644
--- a/arch/mips/mm/pg-sb1.c
+++ b/arch/mips/mm/pg-sb1.c
@@ -216,7 +216,7 @@ void sb1_dma_init(void)
216 int i; 216 int i;
217 217
218 for (i = 0; i < DM_NUM_CHANNELS; i++) { 218 for (i = 0; i < DM_NUM_CHANNELS; i++) {
219 const u64 base_val = CPHYSADDR(&page_descr[i]) | 219 const u64 base_val = CPHYSADDR((unsigned long)&page_descr[i]) |
220 V_DM_DSCR_BASE_RINGSZ(1); 220 V_DM_DSCR_BASE_RINGSZ(1);
221 void *base_reg = IOADDR(A_DM_REGISTER(i, R_DM_DSCR_BASE)); 221 void *base_reg = IOADDR(A_DM_REGISTER(i, R_DM_DSCR_BASE));
222 222
@@ -228,11 +228,11 @@ void sb1_dma_init(void)
228 228
229void clear_page(void *page) 229void clear_page(void *page)
230{ 230{
231 u64 to_phys = CPHYSADDR(page); 231 u64 to_phys = CPHYSADDR((unsigned long)page);
232 unsigned int cpu = smp_processor_id(); 232 unsigned int cpu = smp_processor_id();
233 233
234 /* if the page is not in KSEG0, use old way */ 234 /* if the page is not in KSEG0, use old way */
235 if ((long)KSEGX(page) != (long)CKSEG0) 235 if ((long)KSEGX((unsigned long)page) != (long)CKSEG0)
236 return clear_page_cpu(page); 236 return clear_page_cpu(page);
237 237
238 page_descr[cpu].dscr_a = to_phys | M_DM_DSCRA_ZERO_MEM | 238 page_descr[cpu].dscr_a = to_phys | M_DM_DSCRA_ZERO_MEM |
@@ -252,13 +252,13 @@ void clear_page(void *page)
252 252
253void copy_page(void *to, void *from) 253void copy_page(void *to, void *from)
254{ 254{
255 u64 from_phys = CPHYSADDR(from); 255 u64 from_phys = CPHYSADDR((unsigned long)from);
256 u64 to_phys = CPHYSADDR(to); 256 u64 to_phys = CPHYSADDR((unsigned long)to);
257 unsigned int cpu = smp_processor_id(); 257 unsigned int cpu = smp_processor_id();
258 258
259 /* if any page is not in KSEG0, use old way */ 259 /* if any page is not in KSEG0, use old way */
260 if ((long)KSEGX(to) != (long)CKSEG0 260 if ((long)KSEGX((unsigned long)to) != (long)CKSEG0
261 || (long)KSEGX(from) != (long)CKSEG0) 261 || (long)KSEGX((unsigned long)from) != (long)CKSEG0)
262 return copy_page_cpu(to, from); 262 return copy_page_cpu(to, from);
263 263
264 page_descr[cpu].dscr_a = to_phys | M_DM_DSCRA_L2C_DEST | 264 page_descr[cpu].dscr_a = to_phys | M_DM_DSCRA_L2C_DEST |