diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2008-07-25 19:34:12 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2008-07-25 19:34:12 +0000 |
commit | 868866157762bc5ad7644fcaa45111ecf6ed1899 (patch) | |
tree | 6f94054f92af18de0f63cf5987bb58161fa5f0d6 /ports | |
parent | b5a9dd2cb3af60dca2e83a0c45cd7186eb8af510 (diff) | |
download | ChibiOS-868866157762bc5ad7644fcaa45111ecf6ed1899.tar.gz ChibiOS-868866157762bc5ad7644fcaa45111ecf6ed1899.tar.bz2 ChibiOS-868866157762bc5ad7644fcaa45111ecf6ed1899.zip |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@358 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'ports')
-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 16560842a..1a631e36b 100644 --- a/ports/ARMCM3/chcore.c +++ b/ports/ARMCM3/chcore.c @@ -129,7 +129,8 @@ void SVCallVector(Thread *otp, Thread *ntp) { #define POP_CONTEXT(sp) { \ asm volatile ("ldmia %0!, {r3-r6,r8-r11, lr} \n\t" \ "msr PSP, %0 \n\t" \ - "msr BASEPRI, r3" : "=r" (sp) : "r" (sp)); \ + "msr BASEPRI, r3 \n\t" \ + "bx lr" : "=r" (sp) : "r" (sp)); \ } #else #define PUSH_CONTEXT(sp) { \ @@ -142,7 +143,8 @@ void SVCallVector(Thread *otp, Thread *ntp) { #define POP_CONTEXT(sp) { \ asm volatile ("ldmia %0!, {r3-r11, lr} \n\t" \ "msr PSP, %0 \n\t" \ - "msr BASEPRI, r3" : "=r" (sp) : "r" (sp)); \ + "msr BASEPRI, r3 \n\t" \ + "bx lr" : "=r" (sp) : "r" (sp)); \ } #endif @@ -177,6 +179,4 @@ void PendSVVector(void) { sp_thd = currp->p_ctx.r13; POP_CONTEXT(sp_thd); - - asm volatile ("bx lr"); } |