Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change U-Boot memory map

The U-Boot(2009.03) on MS104-SH4 has the RAM memory map shown below.

0x8c000000 Not for use (4kB)
0x8c001000 for Linux kernel & root file system (3MB)
0x8c400000 for Linux process (28MB)

For me, 3MB for Linux kernel & root file system is too small because Linux kernel & ramdisk has 1MB and 3.5MB respectively. So I'd like to change above memory map, for example like shown below.

0x8c000000 Not for use (4KB)
0x8c001000 for Linux kernel & root file system (16MB)
0x8cf60000 for Linux process (16MB)

In my guess, I have to modify uboot source code, but cannot find where I should modify. Does somebody tell me if it is possible to modify u-boot memory map? If yes, please also tell me how to do it. Thanks for your help!

I found a similar question on How to find the memory map of a device?, but my SH4 iomem is empty (0 size) so looks like other topic.

like image 433
mura_no Avatar asked Feb 02 '12 06:02

mura_no


1 Answers

It is possible to modify U-boot memory map. you need to modify source code of U-boot .U-boot/include/configs/<board_name.h> is the place where you can configure memory map . where <board_name.h> is your architecture specific file and has #define entries which you can change to desirable values. u-boot/arch/<architecture_name>/lib/board.c perform the memory map initialization.

like image 154
raj_gt1 Avatar answered Oct 01 '22 21:10

raj_gt1