Can you help me understand the meaning of Code_length in Application boot code image?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Can you help me understand the meaning of Code_length in Application boot code image?

Jump to solution
905 Views
SandalWood
Contributor III

I checked the startup instructions of S32G. It was written above that in EMMC startup mode, the IVT was written to 0x1000h. So I Use the hexadecimal tool to view the image file of uboot.s32.

haoluo_0-1665643901048.pnghaoluo_1-1665643907707.png

 

The offset of the application boot image is 0x20-0x23h. It is found that the address of the Application boot code image is 0x3200h.

 

haoluo_2-1665643923383.png

haoluo_5-1665644006903.png

So,we can get the informatition:

 

RAM Start pointer:0x3408FE40h

RAM entry pointer:0x340A0000h

Code Length:0xBEC00h = 781,312 (Bytes) =  763KB

 

If I want to start the uboot of core A, the uboot must be placed after the Application boot code image offset of 0x40, right? The meaning of Code_length in Application boot code image  is that the actual binary such as uboot.bin location?

 

 

0 Kudos
1 Solution
880 Views
stone_shi
NXP Employee
NXP Employee

You only need to put the header of your bin at 0x200 aligned address. The bin file is after header.

View solution in original post

0 Kudos
4 Replies
888 Views
stone_shi
NXP Employee
NXP Employee

Please refer to uboot/tools/s32gen1image.c. 

0 Kudos
883 Views
SandalWood
Contributor III

Can I understand that after the app code, it must be the actual running image of the app, such as uboot. bin or m7. bin, but because 0x200h is aligned (512 bytes), it must be placed at 0x3400 in my example hexdump image?

haoluo_0-1665747668693.png

 

 

 

 

0 Kudos
881 Views
stone_shi
NXP Employee
NXP Employee

You only need to put the header of your bin at 0x200 aligned address. The bin file is after header.

0 Kudos
877 Views
SandalWood
Contributor III

Thanks,I get it!

0 Kudos