diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2008-04-12 13:56:29 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2008-04-12 13:56:29 +0000 |
commit | f0c8dde933f7fee21163d9831821dc524b56e6ef (patch) | |
tree | fb685ce542876f77ac7c350cfc225ea274ed313d /ports/ARMCM3/chcore.c | |
parent | e1613c5169d7c792015d6a0bd2224626873af4e2 (diff) | |
download | ChibiOS-f0c8dde933f7fee21163d9831821dc524b56e6ef.tar.gz ChibiOS-f0c8dde933f7fee21163d9831821dc524b56e6ef.tar.bz2 ChibiOS-f0c8dde933f7fee21163d9831821dc524b56e6ef.zip |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@260 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'ports/ARMCM3/chcore.c')
-rw-r--r-- | ports/ARMCM3/chcore.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ports/ARMCM3/chcore.c b/ports/ARMCM3/chcore.c index d691cee20..5a718abc0 100644 --- a/ports/ARMCM3/chcore.c +++ b/ports/ARMCM3/chcore.c @@ -75,9 +75,7 @@ void threadstart(void) { void SysTickVector(void) {
chSysIRQEnterI();
-
chSysTimerHandlerI();
-
chSysIRQExitI();
}
@@ -94,8 +92,9 @@ void chSysIRQExitI(void) { if (chSchRescRequiredI()) {
asm volatile ("mrs r0, PSP \n\t" \
- "ldr r1, =retaddr \n\t" \
"ldr r2, [r0, #24] \n\t" \
+ "orr r2, r2, #1 \n\t" \
+ "ldr r1, =retaddr \n\t" \
"str r2, [r1] \n\t" \
"ldr r1, =threadswitch \n\t" \
"str r1, [r0, #24] ");
@@ -117,8 +116,9 @@ void threadswitch(void) { "mrs r0, XPSR \n\t" \
"push {r0} \n\t" \
"ldr r0, =retaddr \n\t" \
+ "ldr r0, [r0] \n\t" \
"str r0, [sp, #28] \n\t" \
- "b chSchDoRescheduleI \n\t" \
+ "bl chSchDoRescheduleI \n\t" \
"pop {r0} \n\t" \
"msr XPSR, r0 \n\t" \
"pop {r0-r3, r12, lr} \n\t" \
|