m68knommu: fix 528x ColdFire cache settings
authorGreg Ungerer <gerg@snapgear.com>
Fri, 1 Feb 2008 07:38:24 +0000 (17:38 +1000)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 1 Feb 2008 10:00:01 +0000 (21:00 +1100)
Fix problems with the 528x ColdFire CPU cache setup.
Do not cache the flash region (if present), and make the runtime
settings consistent with the init setting.

Problems pointed out by Bernd Buttner <b.buettner@mkc-gmbh.de>

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/asm-m68knommu/cacheflush.h
include/asm-m68knommu/mcfcache.h

index 163dcb1a9689d3687aa6e5775bcaf82eee65932f..29bc0aad2ebc7fb5c69bdcf34ebbd739a9a9f18a 100644 (file)
@@ -53,7 +53,7 @@ static inline void __flush_cache_all(void)
 #endif /* CONFIG_M5407 */
 #if defined(CONFIG_M527x) || defined(CONFIG_M528x)
        __asm__ __volatile__ (
-               "movel  #0x81400100, %%d0\n\t"
+               "movel  #0x81000200, %%d0\n\t"
                "movec  %%d0, %%CACR\n\t"
                "nop\n\t"
                : : : "d0" );
index 7b61a8a529f52063fa01b760a78ca125b4e3235a..c042634fadaa0cecb2c83d0ea9e3feac3ecc91d5 100644 (file)
@@ -60,7 +60,7 @@
        nop
        movel   #0x0000c020, %d0        /* Set SDRAM cached only */
        movec   %d0, %ACR0
-       movel   #0xff00c000, %d0        /* Cache Flash also */
+       movel   #0x00000000, %d0        /* No other regions cached */
        movec   %d0, %ACR1
        movel   #0x80000200, %d0        /* Setup cache mask */
        movec   %d0, %CACR              /* Enable cache */