" isb \n"\r
" pop {r0-r5} \n" /* Pop the registers that are saved automatically. */\r
" mov lr, r5 \n" /* lr is now in r5. */\r
+ " pop {r3} \n" /* Return address is now in r3. */\r
+ " pop {r2} \n" /* Pop and discard XPSR. */\r
" cpsie i \n" /* The first task has its context and interrupts can be enabled. */\r
- " pop {pc} \n" /* Finally, pop the PC to jump to the user defined task code. */\r
+ " bx r3 \n" /* Finally, jump to the user defined task code. */\r
" \n"\r
" .align 4 \n"\r
"pxCurrentTCBConst2: .word pxCurrentTCB "\r