
On Friday 16 May 2008, 甜瓜 wrote:
All Walnut boards have 512k of NOR FLASH. Do you really have an original IBM/AMCC Walnut or a different custom 405GP board?
Yes, my board is a custom board DHT-Walut with 32MB SDRAM and 512k of boot flash AMD 29LV040B. Details are listed in: http://elinux.org/DHT-Walnut
OK.
I wonder how to build a 512KB bin?
Generally this is possible. You need to change CONFIG_MONITOR_LEN & CFG_MONITOR_BASE in include/configs/walnut.h. And TEXT_BASE in board/amcc/walnut/config.mk.
Thank you very much. That's exact what I need!
Noooo! Please wait.
Is there any OPTION/SETTING targeting this problem? Anything else I should take care?
But please don't forget that the environment is also stored in the NOR FLASH. And by changing the U-Boot size to 512k you leave no space for the environment.
Do you mean that environment settings (eg: ip_addr, ethaddr...) are stored sperately from the bin?
Most of the boards do it this way, yes.
In my mind (with guess :p), env should be defined in bin code or data section, and it will be compiled together with other codes to form a single bin.
This can be done too. But its not the case on Walnut.
So why exactly do you want to change the U-Boot image size?
Well. The reason is:
- Both default config of u-boot and a DHT-Walut-patched config
generate 256KB bin, but the flash on board is 512KB. So I think I should get a 512KB bin for flash writing.
No. You definitely don't need a 512k image for this setup. You just need to flash the image at the "end" of the FLASH chip. So starting at 256k:
0...256k: Free and environment 256k...512k: U-Boot image
- The contents in the flash on my board is totally corrupted by
accident. It means the important last-4-bytes should be rewritten to a proper state. 3. Currenly, I have to use special hardware to write bin into flash. Therefore 256KB bin will only overwrite the first half. The last-4-bytes in the end of flash is still the old value. Booting will definitely fail.
See above. Don't increase the image size, but flash it with an offset of 256k.
Best regards, Stefan
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office@denx.de =====================================================================