summaryrefslogtreecommitdiffstats
path: root/include/asm-mips/edac.h
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw2@infradead.org>2007-10-13 14:43:54 +0100
committerDavid Woodhouse <dwmw2@infradead.org>2007-10-13 14:43:54 +0100
commitb160292cc216a50fd0cd386b0bda2cd48352c73b (patch)
treeef07cf98f91353ee4c9ec1e1ca7a2a5d9d4b538a /include/asm-mips/edac.h
parentb37bde147890c8fea8369a5a4e230dabdea4ebfb (diff)
parentbbf25010f1a6b761914430f5fca081ec8c7accd1 (diff)
downloadop-kernel-dev-b160292cc216a50fd0cd386b0bda2cd48352c73b.zip
op-kernel-dev-b160292cc216a50fd0cd386b0bda2cd48352c73b.tar.gz
Merge Linux 2.6.23
Diffstat (limited to 'include/asm-mips/edac.h')
-rw-r--r--include/asm-mips/edac.h17
1 files changed, 8 insertions, 9 deletions
diff --git a/include/asm-mips/edac.h b/include/asm-mips/edac.h
index 83719ee..4da0c1f 100644
--- a/include/asm-mips/edac.h
+++ b/include/asm-mips/edac.h
@@ -9,8 +9,7 @@ static inline void atomic_scrub(void *va, u32 size)
unsigned long temp;
u32 i;
- for (i = 0; i < size / sizeof(unsigned long); i++, virt_addr++) {
-
+ for (i = 0; i < size / sizeof(unsigned long); i++) {
/*
* Very carefully read and write to memory atomically
* so we are interrupt, DMA and SMP safe.
@@ -19,16 +18,16 @@ static inline void atomic_scrub(void *va, u32 size)
*/
__asm__ __volatile__ (
- " .set mips3 \n"
- "1: ll %0, %1 # atomic_add \n"
- " ll %0, %1 # atomic_add \n"
- " addu %0, $0 \n"
- " sc %0, %1 \n"
- " beqz %0, 1b \n"
- " .set mips0 \n"
+ " .set mips2 \n"
+ "1: ll %0, %1 # atomic_scrub \n"
+ " addu %0, $0 \n"
+ " sc %0, %1 \n"
+ " beqz %0, 1b \n"
+ " .set mips0 \n"
: "=&r" (temp), "=m" (*virt_addr)
: "m" (*virt_addr));
+ virt_addr++;
}
}
OpenPOWER on IntegriCloud