
Dear Jens Scharsig, dear Andreas Bießmann
---8<---
@@ -65,7 +65,8 @@ LoopOsc: ldr r0, =SMRDATA ldr r1, _MTEXT_BASE sub r0, r0, r1
- add r2, r0, #80
- ldr r2, =SMRDATAE
- add r2, r2, r1
--->8---
Ok,this is wrong, But it is code from version 1. The V2 use the correct sub instruction.
Then we subtract TEXT_BASE from absolute address of SMRDATA. This lead to some value about 0x500 in r0 which is completely wrong which in turn leads to data abort. ... It would make sense to me to do some construct like this for relocated code, but here we are before relocation and therefore it would be sufficient to
At boot time flash memory is mapded to 0x0. So the address 0x500 and 0x10000500 points the same location in flash.
Is there going to be a V3 soon? And please note, when "checkpatching" V2 there are style problems:
ERROR: trailing whitespace #56: FILE: arch/arm/cpu/arm920t/at91/lowlevel_init.S:119: +SMRDATAE:^I$
ERROR: trailing whitespace #64: FILE: arch/arm/cpu/arm920t/at91/lowlevel_init.S:166: +SMRDATA1E:^I^I$
total: 2 errors, 0 warnings, 31 lines checked
I find it a very valuable tool to do a ../linux-2.6/scripts/checkpatch.pl" before sending the patch ;)
Best Regards, Reinhard