diff options
author | Elizabeth Oldham <beth@mips.com> | 2006-06-06 05:57:09 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2006-06-19 12:39:13 -0400 |
commit | 734996820fd02b52a3fa0fcc09bdb914934bea4c (patch) | |
tree | 7d12e625c842bfc605b83506fd2423a44fad53ed /arch/mips | |
parent | 427abfa28afedffadfca9dd8b067eb6d36bac53f (diff) |
[MIPS] Malta: Handle byteswapping hardare bug in big endian mode.
The SOC-it system controller running in big endian mode might forget
byteswapping when DMAing to the last word of physical memory. Fixed by
ignoring the last page of memory.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips')
-rw-r--r-- | arch/mips/mips-boards/generic/memory.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/mips/mips-boards/generic/memory.c b/arch/mips/mips-boards/generic/memory.c index bc4d093685bb..fd492562584a 100644 --- a/arch/mips/mips-boards/generic/memory.c +++ b/arch/mips/mips-boards/generic/memory.c | |||
@@ -76,6 +76,15 @@ struct prom_pmemblock * __init prom_getmdesc(void) | |||
76 | memsize = simple_strtol(memsize_str, NULL, 0); | 76 | memsize = simple_strtol(memsize_str, NULL, 0); |
77 | } | 77 | } |
78 | } | 78 | } |
79 | |||
80 | #ifdef CONFIG_CPU_BIG_ENDIAN | ||
81 | /* | ||
82 | * SOC-it swaps, or perhaps doesn't swap, when DMA'ing the last | ||
83 | * word of physical memory | ||
84 | */ | ||
85 | memsize -= PAGE_SIZE; | ||
86 | #endif | ||
87 | |||
79 | memset(mdesc, 0, sizeof(mdesc)); | 88 | memset(mdesc, 0, sizeof(mdesc)); |
80 | 89 | ||
81 | mdesc[0].type = yamon_dontuse; | 90 | mdesc[0].type = yamon_dontuse; |