瀏覽代碼

Fix U-Boot enviroenment sector protection on MCC200 board

Wolfgang Denk 19 年之前
父節點
當前提交
5d7022b041
共有 2 個文件被更改,包括 3 次插入1 次删除
  1. 2 0
      CHANGELOG
  2. 1 1
      board/mcc200/mcc200.c

+ 2 - 0
CHANGELOG

@@ -2,6 +2,8 @@
 Changes since U-Boot 1.1.4:
 Changes since U-Boot 1.1.4:
 ======================================================================
 ======================================================================
 
 
+* Fix U-Boot enviroenment sector protection on MCC200 board
+
 * Minor cleanup for PCS440EP board
 * Minor cleanup for PCS440EP board
 
 
 * Update PCS440EP port to fit into one flash device (incl. environment)
 * Update PCS440EP port to fit into one flash device (incl. environment)

+ 1 - 1
board/mcc200/mcc200.c

@@ -242,7 +242,7 @@ int misc_init_r (void)
 		/* Unprotect the upper bank of the Flash */
 		/* Unprotect the upper bank of the Flash */
 		*(volatile int*)MPC5XXX_CS0_CFG |= (1 << 6);
 		*(volatile int*)MPC5XXX_CS0_CFG |= (1 << 6);
 		flash_protect (FLAG_PROTECT_CLEAR,
 		flash_protect (FLAG_PROTECT_CLEAR,
-			       flash_info[0].start[0],
+			       flash_info[0].start[0] + flash_info[0].size / 2,
 			       (flash_info[0].start[0] + flash_info[0].size) / 2 - 1,
 			       (flash_info[0].start[0] + flash_info[0].size) / 2 - 1,
 			       &flash_info[0]);
 			       &flash_info[0]);
 		*(volatile int*)MPC5XXX_CS0_CFG &= ~(1 << 6);
 		*(volatile int*)MPC5XXX_CS0_CFG &= ~(1 << 6);