Index: c/src/lib/libbsp/bfin/eZKit533/ChangeLog
===================================================================
--- c/src/lib/libbsp/bfin/eZKit533/ChangeLog	(revision c613270df6836c41503ceb010975d9d05a5dbc2e)
+++ c/src/lib/libbsp/bfin/eZKit533/ChangeLog	(revision 39ee40db4ff520325b432b1e9ba270de5b151b02)
@@ -1,2 +1,8 @@
+2007-09-10	Alain Schaefer <alani@easc.ch>
+
+	* preinstall.am, startup/bspstart.c, startup/linkcmds: Complete earlier
+	patch.
+	* include/cplb.h: New file.
+
 2007-09-10	Alain Schaefer <alani@easc.ch>
 
Index: c/src/lib/libbsp/bfin/eZKit533/include/cplb.h
===================================================================
--- c/src/lib/libbsp/bfin/eZKit533/include/cplb.h	(revision 39ee40db4ff520325b432b1e9ba270de5b151b02)
+++ c/src/lib/libbsp/bfin/eZKit533/include/cplb.h	(revision 39ee40db4ff520325b432b1e9ba270de5b151b02)
@@ -0,0 +1,34 @@
+/*  cplb.h
+ *  
+ *  Copyright (c) 2006 by Atos Automacao Industrial Ltda.
+ *             written by Alain Schaefer <alain.schaefer@easc.ch>
+ *
+ *  The license and distribution terms for this file may be
+ *  found in the file LICENSE in this distribution or at
+ *  http://www.rtems.com/license/LICENSE.
+ *
+ *  $Id$
+ */
+#ifndef _CPLB_H
+#define _CPLB_H
+
+/* CPLB configurations */
+#define CPLB_DEF_CACHE_WT	CPLB_L1_CHBL | CPLB_WT
+#define CPLB_DEF_CACHE_WB	CPLB_L1_CHBL 
+#define CPLB_CACHE_ENABLED	CPLB_L1_CHBL | CPLB_DIRTY
+
+#define CPLB_DEF_CACHE		CPLB_L1_CHBL | CPLB_WT
+#define CPLB_ALL_ACCESS	CPLB_SUPV_WR | CPLB_USER_RD | CPLB_USER_WR
+
+#define CPLB_I_PAGE_MGMT	CPLB_LOCK | CPLB_VALID
+#define CPLB_D_PAGE_MGMT	CPLB_LOCK | CPLB_ALL_ACCESS | CPLB_VALID
+
+#define CPLB_DNOCACHE		CPLB_ALL_ACCESS | CPLB_VALID
+#define CPLB_DDOCACHE		CPLB_DNOCACHE | CPLB_DEF_CACHE
+#define CPLB_INOCACHE   	CPLB_USER_RD | CPLB_VALID
+#define CPLB_IDOCACHE   	CPLB_INOCACHE | CPLB_L1_CHBL
+
+#define CPLB_DDOCACHE_WT	CPLB_DNOCACHE | CPLB_DEF_CACHE_WT
+#define CPLB_DDOCACHE_WB	CPLB_DNOCACHE | CPLB_DEF_CACHE_WB
+
+#endif /* _CPLB_H */
Index: c/src/lib/libbsp/bfin/eZKit533/preinstall.am
===================================================================
--- c/src/lib/libbsp/bfin/eZKit533/preinstall.am	(revision c613270df6836c41503ceb010975d9d05a5dbc2e)
+++ c/src/lib/libbsp/bfin/eZKit533/preinstall.am	(revision 39ee40db4ff520325b432b1e9ba270de5b151b02)
@@ -37,4 +37,8 @@
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp.h
 
+$(PROJECT_INCLUDE)/cplb.h: include/cplb.h $(PROJECT_INCLUDE)/$(dirstamp)
+	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/cplb.h
+PREINSTALL_FILES += $(PROJECT_INCLUDE)/cplb.h
+
 $(PROJECT_INCLUDE)/tm27.h: include/tm27.h $(PROJECT_INCLUDE)/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/tm27.h
Index: c/src/lib/libbsp/bfin/eZKit533/startup/bspstart.c
===================================================================
--- c/src/lib/libbsp/bfin/eZKit533/startup/bspstart.c	(revision c613270df6836c41503ceb010975d9d05a5dbc2e)
+++ c/src/lib/libbsp/bfin/eZKit533/startup/bspstart.c	(revision 39ee40db4ff520325b432b1e9ba270de5b151b02)
@@ -21,4 +21,5 @@
 
 #include <bsp.h>
+#include <cplb.h>
 #include <rtems/libio.h>
 #include <rtems/libcsupport.h>
@@ -39,22 +40,23 @@
 
 
-const unsigned int dcplbs_table[][] = {  
-
-       { 0xFF900000,   (PAGE_SIZE_1MB | CPLB_D_PAGE_MGMT | CPLB_WT) }, // L1 Data B
-       { 0xFF800000,   (PAGE_SIZE_1MB | CPLB_D_PAGE_MGMT | CPLB_WT) }, // L1 Data A
-
-       { 0x20300000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      // Async Memory Bank 3
-       { 0x20200000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      // Async Memory Bank 2 (Secnd)
-       { 0x20100000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      // Async Memory Bank 1 (Prim B)
-       { 0x20000000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      // Async Memory Bank 0 (Prim A)
-
-       { 0x02400000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },      // 
-       { 0x02000000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },      // 
-       { 0x00C00000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },      // 
-       { 0x00800000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },      // 
-       { 0x00400000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },      // 
-       { 0x00000000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },      // 
-
-       { 0xffffffff, 0xffffffff }                                                      // end of section - termination
+const unsigned int dcplbs_table[16][2] = {  
+	{ 0xFFA00000,   (PAGE_SIZE_1MB | CPLB_D_PAGE_MGMT | CPLB_WT) },
+        { 0xFF900000,   (PAGE_SIZE_1MB | CPLB_D_PAGE_MGMT | CPLB_WT) }, /* L1 Data B */
+        { 0xFF800000,   (PAGE_SIZE_1MB | CPLB_D_PAGE_MGMT | CPLB_WT) }, /* L1 Data A */
+        { 0xFFB00000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },
+
+        { 0x20300000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      /* Async Memory Bank 3 */
+        { 0x20200000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      /* Async Memory Bank 2 (Secnd)  */
+        { 0x20100000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      /* Async Memory Bank 1 (Prim B) */
+        { 0x20000000,   (PAGE_SIZE_1MB | CPLB_DNOCACHE) },      /* Async Memory Bank 0 (Prim A) */
+
+        { 0x02400000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },
+        { 0x02000000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },
+        { 0x00C00000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },
+        { 0x00800000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },
+        { 0x00400000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },
+        { 0x00000000,   (PAGE_SIZE_4MB | CPLB_DNOCACHE) },
+
+        { 0xffffffff, 0xffffffff }                                                      /* end of section - termination */
 
        }
@@ -62,22 +64,22 @@
 
 
-const unsigned int _icplbs_table[][] = { 
-       { 0xFFA00000,   (PAGE_SIZE_1MB | CPLB_I_PAGE_MGMT) },   // L1 Code
-
-       { 0xEF000000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      // AREA DE BOOT
-
-       { 0x20300000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      // Async Memory Bank 3
-       { 0x20200000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      // Async Memory Bank 2 (Secnd)
-       { 0x20100000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      // Async Memory Bank 1 (Prim B)
-       { 0x20000000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      // Async Memory Bank 0 (Prim A)
-
-       { 0x02400000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },      // 
-       { 0x02000000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },      // 
-       { 0x00C00000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },      // 
-       { 0x00800000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },      // 
-       { 0x00400000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },      // 
-       { 0x00000000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },      // 
-
-       { 0xffffffff, 0xffffffff  }                                                     // end of section - termination
+const unsigned int _icplbs_table[16][2] = { 
+        { 0xFFA00000,   (PAGE_SIZE_1MB | CPLB_I_PAGE_MGMT | CPLB_I_PAGE_MGMT | 0x4) },  /* L1 Code */
+        { 0xEF000000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      /* AREA DE BOOT */
+        { 0xFFB00000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      
+
+        { 0x20300000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      /* Async Memory Bank 3 */
+        { 0x20200000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      /* Async Memory Bank 2 (Secnd) */
+        { 0x20100000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      /* Async Memory Bank 1 (Prim B) */
+        { 0x20000000,   (PAGE_SIZE_1MB | CPLB_INOCACHE) },      /* Async Memory Bank 0 (Prim A) */
+
+        { 0x02400000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },
+        { 0x02000000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },
+        { 0x00C00000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },
+        { 0x00800000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },
+        { 0x00400000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },
+        { 0x00000000,   (PAGE_SIZE_4MB | CPLB_INOCACHE) },
+
+        { 0xffffffff, 0xffffffff }                                                      /* end of section - termination */
 
        }
Index: c/src/lib/libbsp/bfin/eZKit533/startup/linkcmds
===================================================================
--- c/src/lib/libbsp/bfin/eZKit533/startup/linkcmds	(revision c613270df6836c41503ceb010975d9d05a5dbc2e)
+++ c/src/lib/libbsp/bfin/eZKit533/startup/linkcmds	(revision 39ee40db4ff520325b432b1e9ba270de5b151b02)
@@ -15,7 +15,7 @@
 MEMORY
 {
+      sdram(rwx)    : ORIGIN = 0x00001000, LENGTH = 0x01000000
       l1code(rwx)   : ORIGIN = 0xffa08000, LENGTH = 0x00008000
       l1data(rwx)   : ORIGIN = 0xff804000, LENGTH = 0x00004000
-      sdram(rwx)    : ORIGIN = 0x00001000, LENGTH = 0x01000000
 }
 
