]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
85xx: Add L2SRAM Register's macro definition
authorMingkai Hu <Mingkai.hu@freescale.com>
Tue, 18 Aug 2009 07:37:15 +0000 (15:37 +0800)
committerKumar Gala <galak@kernel.crashing.org>
Fri, 28 Aug 2009 22:12:41 +0000 (17:12 -0500)
Signed-off-by: Mingkai Hu <Mingkai.hu@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
cpu/mpc85xx/cpu_init.c
include/asm-ppc/immap_85xx.h

index 41de6942a62cf6448af6dd977639c72ef8aaaa03..c4d1a9dd9c7cffac1a761872f20ceaf7d1f5374e 100644 (file)
@@ -330,11 +330,12 @@ int cpu_init_r(void)
                break;
        }
 
-       if (l2cache->l2ctl & 0x80000000) {
+       if (l2cache->l2ctl & MPC85xx_L2CTL_L2E) {
                puts("already enabled");
                l2srbar = l2cache->l2srbar0;
 #ifdef CONFIG_SYS_INIT_L2_ADDR
-               if (l2cache->l2ctl & 0x00010000 && l2srbar >= CONFIG_SYS_FLASH_BASE) {
+               if (l2cache->l2ctl & MPC85xx_L2CTL_L2SRAM_ENTIRE
+                               && l2srbar >= CONFIG_SYS_FLASH_BASE) {
                        l2srbar = CONFIG_SYS_INIT_L2_ADDR;
                        l2cache->l2srbar0 = l2srbar;
                        printf("moving to 0x%08x", CONFIG_SYS_INIT_L2_ADDR);
index 0efef0521437ce4ab0e67d7074929fdce4bcea3a..375d80444f5e8047ac8bfe173c1dba9aba6ad0d8 100644 (file)
@@ -411,6 +411,11 @@ typedef struct ccsr_l2cache {
        char    res15[420];
 } ccsr_l2cache_t;
 
+#define MPC85xx_L2CTL_L2E                      0x80000000
+#define MPC85xx_L2CTL_L2SRAM_ENTIRE            0x00010000
+#define MPC85xx_L2ERRDIS_MBECC                 0x00000008
+#define MPC85xx_L2ERRDIS_SBECC                 0x00000004
+
 /*
  * DMA Registers(0x2_1000-0x2_2000)
  */