Hi Nxp,
i need to modify ld file since the application ram usage exceeded. i mainly expand the int_sram size as followed. then the app failed to init and debug is abnormal , stucked, see attached image. could you give some advice what's wrong i've made.
i only change the MEMORY section as below:
MEMORY
{
int_pflash : ORIGIN = 0x00400000, LENGTH = 0x001D4000 /* 2048KB - 176KB (sBAF + HSE)*/
int_dflash : ORIGIN = 0x10000000, LENGTH = 0x00020000 /* 128KB */
int_itcm : ORIGIN = 0x00000000, LENGTH = 0x00008000 /* 32KB */
int_dtcm : ORIGIN = 0x20000000, LENGTH = 0x0000F000 /* 60KB */
int_stack_dtcm : ORIGIN = 0x2000F000, LENGTH = 0x00001000 /* 4KB */
int_sram : ORIGIN = 0x20400000, LENGTH = 0x00007F00 /* 32KB , needs to include int_sram_fls_rsv*/
int_sram_fls_rsv : ORIGIN = 0x20407F00, LENGTH = 0x00000100
int_sram_no_cacheable : ORIGIN = 0x20408000, LENGTH = 0x00007F00 /* 32KB , needs to include int_sram_results */
int_sram_results : ORIGIN = 0x2040FF00, LENGTH = 0x00000100
int_sram_shareable : ORIGIN = 0x20410000, LENGTH = 0x00008000 /* 32KB */
ram_rsvd2 : ORIGIN = 0x20418000, LENGTH = 0 /* End of SRAM */
}
-- my new settings-------
MEMORY
{
int_pflash : ORIGIN = 0x00400000, LENGTH = 0x001D4000 /* 2048KB - 176KB (sBAF + HSE)*/
int_dflash : ORIGIN = 0x10000000, LENGTH = 0x00020000 /* 128KB */
int_itcm : ORIGIN = 0x00000000, LENGTH = 0x00008000 /* 32KB */
int_dtcm : ORIGIN = 0x20000000, LENGTH = 0x0000F000 /* 60KB */
int_stack_dtcm : ORIGIN = 0x2000F000, LENGTH = 0x00001000 /* 4KB */
int_sram : ORIGIN = 0x20400000, LENGTH = 0x00011000 /* 32KB , needs to include int_sram_fls_rsv*/
int_sram_fls_rsv : ORIGIN = 0x20411000, LENGTH = 0x00000100
int_sram_no_cacheable : ORIGIN = 0x20411100, LENGTH = 0x00006A00 /* 32KB , needs to include int_sram_results */
int_sram_results : ORIGIN = 0x20417B00, LENGTH = 0x00000100
int_sram_shareable : ORIGIN = 0x20417C00, LENGTH = 0x00000400 /* 32KB */
ram_rsvd2 : ORIGIN = 0x20418000, LENGTH = 0 /* End of SRAM */
}
Hi @victory,
In that case, you should see a MemManage fault exception in the Configurable Fault Status Register (CSFR).
The base address of any MPU region must be aligned to the size of the region, it was discussed here:
BR, Daniel