Closed andresag01 closed 8 years ago
I would like for the two assembly sequences (for ARMCC and GCC) to be identical. It would also be nice to relocate the MOV r0, r6 out of the sequence involved in the check of IPSR; the MOV doesn't belong in that sequence. Can we try with the MOV r0, r6 immediately following the LDR into r6?
@rgrover I have made the change mentioned in your comment and tested the DFU process once more using S130 in both ARMCC and GCC.
hi, could you please resubmit this against the 'develop' branch? otherwise it will mess up our release process if I merge it directly into master.
The assemble sequence within an mbedOS application that starts the nordic bootloader was being modified by the compiler. The result is that DFU enabled applications could never start the bootloader correctly. This is because the GCC compiler was translating a MOV instruction into a ADDS, which sets the conditional flags in APSR before a conditional branch was executed. The result of the incorrect branch caused the program to believe that it was in interrupt mode when this was not the case.
@rgrover