[U-Boot-Users] How to reduce the size of u-boot image file

Hi,
I have two questions here:
1. Because of the size of the flash memory constraint, I need to strip the u-boot to its minimum size. Right now by executing "make all" in the u-boot directory, I got a image file u-boot at around 700K-800K. It's too big for my target. So I am thinking about getting rid of some functionalities which u-boot provides. I do need u-boot to initialize my hardware. But after that, I only need to use tftp to get the linux image, decompress the image, put the decompressed image in RAM and jump to the linux entry point to let the linux take over the control. Is there any FAQ or manual explaining how to strip down the u-boot size?
2. Since my flash memory address starts from 0xFFC00020 instead of 0xFFF80000, so I changed the TEXT_BASE in board/walnut405/config.mk to 0xFFC00020. When I use "make u-boot", everything is fine. But if I use "make u-boot.bin", it ends up with a u-boot.bin more than 4MB. I think I didn't get the TEXT_BASE set correctly. Isn't TEXT_BASE the start point of the flash? If it isn't, what does TEXT_BASE mean? And where to indicate the start of the flash memory?
BTW, here is my environment: CPU: PPC 405 200MHz Flash: 4MB SDRAM: 16MB BOARD: walnut
Thanks a lot!
Frank
_________________________________________________________________ FREE pop-up blocking with the new MSN Toolbar get it now! http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/

Frank,
in message BAY2-F84Hoouifm0Sx700057af6@hotmail.com you wrote:
- Because of the size of the flash memory constraint, I need to strip the
u-boot to its minimum size. Right now by executing "make all" in the u-boot directory, I got a image file u-boot at around 700K-800K. It's too big for
You must be joking. I haven't seen any configuration yet which exceeds 256 kB.
Did you by any chance look at the ELF file which includes all the hewaders, symbol tables, debug informnation etc.?
Forget about this one. How big is your u-boot.bin file?
my target. So I am thinking about getting rid of some functionalities which u-boot provides. I do need u-boot to initialize my hardware. But after that, I only need to use tftp to get the linux image, decompress the image, put the decompressed image in RAM and jump to the linux entry point to let the linux take over the control. Is there any FAQ or manual explaining how to strip down the u-boot size?
Yes. The README explains how to enable or disable commands or command groups.
- Since my flash memory address starts from 0xFFC00020 instead of
Please check again. I think it is IMPOSSIBLE to have a flash start address of 0xFFC00020. I guess you mean 0xFFC00000 ?
0xFFF80000, so I changed the TEXT_BASE in board/walnut405/config.mk to 0xFFC00020. When I use "make u-boot", everything is fine. But if I use "make u-boot.bin", it ends up with a u-boot.bin more than 4MB. I think I didn't
This is normal. U-Boot includes the jump statement at the reset vector, 0xFFFFFFFC.
get the TEXT_BASE set correctly. Isn't TEXT_BASE the start point of the flash? If it isn't, what does TEXT_BASE mean? And where to indicate the
Yes, it is. And if you put U-Boot at the start of the flash, and the reset vector is in the last word, then the U-Boot image needs to cover your whole 4 MB of flash memory.
You just get what you ask for.
Best regards,
Wolfgang Denk
participants (2)
-
Frank Young
-
Wolfgang Denk