Long calls and data abort
Hello,
I would like to call a function in external SDRAM from within internal flash (LPC2468). The ENABLE LONG CALLS properties of both modules have been set to YES and the compiler does not "complain" any longer.
However, at address 0xA0008F40 a data abort exception occurs (see code below).
DWORD BootLoad(DWORD CmdLen) {
A0008F3C E3A03001 mov r3, #1
A0008F40 E5C53004 strb r3, [r5, #4] causes data abort
A000FF44 E58D4000 str r4, [sp]
A0008F48 E3A00004 mov r0, #4
The value of r5 is 0x2e4 and the value at adress 0x2e8 is 0xeaff fffe.
It looks to me as an write attempt to a forbidden memory location.
When I run the programme in internal flash everything is ok.
Does anybody have a suggestion how this problem can be solved?
Henry
-
The disassembly doesn't look like a valid function, is it not just what is hanging around in external SDRAM?
If the code is to be copied out of FLASH on startup and it is in the .text2 section (and you are using our startup code), make sure crt0.s has been built with the INITIALIZE_SECONDARY_SECTIONS preprocessor definition defined so that .text2 section is initialized correctly.
Please sign in to leave a comment.
Comments
1 comment