MPC5200LITE saveenv issue
Hi,
I did a download of the latest u-boot from the SourceForge CVS 2004-03-10. After building u-boot with MPC5200LITE_LOWBOOT_config, I downloaded it with DBUG, moved the L/H jumper jumper to low boot, performed reset and u-boot was up. Unfortunately, u-boot didn't went up again after doing saveenv. I found that the binary was 209192 bytes and that the environment was located at 0xff030000 so I reckoned that the application used part of the environment area. I modified IceCube.h to have the environment start at 0xff040000 and changed the monitor length to 256 kB
(see diff at end of mail). This seems to work and I was able to save the environment and boot Linux. Is there something which I have missed?
I am using ELDK 2.0 and I am not sure if the newer gcc of ELDK 3.0 might generate more optimized code, which might fit into the original setup. Any feedback would be appreciated. Note! I have only changed the lowboot code. If the same size issue also affects high boot, this might also have to be changed.
Kind regards,
Tord Andersson
IceCube.h Sun Mar 14 20:04:15 2004 renamed from IceCube_old.h Thu Mar 11 23:16:12 2004 +2 -3
@@ -180,10 +180,10 @@ #define CFG_ENV_ADDR (CFG_FLASH_BASE + 0x740000 + 0x800000) #else /* CFG_LOWBOOT */ #if defined(CFG_LOWBOOT08) -#define CFG_ENV_ADDR (CFG_FLASH_BASE + 0x30000 + 0x800000) +#define CFG_ENV_ADDR (CFG_FLASH_BASE + 0x40000 + 0x800000) #endif #if defined(CFG_LOWBOOT16) -#define CFG_ENV_ADDR (CFG_FLASH_BASE + 0x30000) +#define CFG_ENV_ADDR (CFG_FLASH_BASE + 0x40000) #endif #endif /* CFG_LOWBOOT */ #define CFG_MAX_FLASH_BANKS 2 /* max num of memory banks */
@@ -225,7 +225,7 @@ # define CFG_RAMBOOT 1 #endif -#define CFG_MONITOR_LEN (192 << 10) /* Reserve 192 kB for Moni
tor */
+#define CFG_MONITOR_LEN (256 << 10) /* Reserve 256 kB for Moni
tor */
#define CFG_MALLOC_LEN (128 << 10) /* Reserve 128 kB for malloc() */ #define CFG_BOOTMAPSZ (8 << 20) /* Initial Memory map for Linux */
Quoted 2 lines · In message <026001c40a07$9830cb80$952f7f3e@emil> you wrote:
I did a download of the latest u-boot from the SourceForge CVS 2004-03-10.
This is not the "latest" U-boot. Tha latest U-Boot is always "-Dnow" :-)
Quoted 6 lines
After building u-boot with
MPC5200LITE_LOWBOOT_config, I downloaded it with DBUG, moved the L/H jumper jumper to low boot, performed reset and u-boot was up. Unfortunately, u-boot didn't went up again after doing saveenv. I found that the binary was 209192 bytes and that the environment was located at0xff030000so I reckoned that the application used part of the environment area. I modifiedIceCube.hto have the environment
This has already been fixed. Please update your sources.
Quoted 2 lines
I am using ELDK 2.0 and I am not sure if the newer gcc of ELDK 3.0 might generate more optimized code, which might fit into the original setup.
No, some features were added, and the code has grown. We need the additional sector for code, no matter if you use the old or the new compiler.
Best regards,
Wolfgang Denk
Signature · 3 lines
Software Engineering: Embedded and Realtime Systems, Embedded Linux Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: wd at denx.de I program, therefore I am.