aboutsummaryrefslogtreecommitdiffstats
path: root/os/ports/GCC/AVR
diff options
context:
space:
mode:
Diffstat (limited to 'os/ports/GCC/AVR')
-rw-r--r--os/ports/GCC/AVR/chcore.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/os/ports/GCC/AVR/chcore.c b/os/ports/GCC/AVR/chcore.c
index f84e6aed1..32e48ce52 100644
--- a/os/ports/GCC/AVR/chcore.c
+++ b/os/ports/GCC/AVR/chcore.c
@@ -67,14 +67,14 @@ void port_switch(Thread *ntp, Thread *otp) {
asm volatile ("movw r30, r22");
asm volatile ("in r0, 0x3d");
- asm volatile ("std Z+6, r0");
+ asm volatile ("std Z+5, r0");
asm volatile ("in r0, 0x3e");
- asm volatile ("std Z+7, r0");
+ asm volatile ("std Z+6, r0");
asm volatile ("movw r30, r24");
- asm volatile ("ldd r0, Z+6");
+ asm volatile ("ldd r0, Z+5");
asm volatile ("out 0x3d, r0");
- asm volatile ("ldd r0, Z+7");
+ asm volatile ("ldd r0, Z+6");
asm volatile ("out 0x3e, r0");
asm volatile ("pop r29");