diff options
author | Vegard Storheil Eriksen <zyp@jvnv.net> | 2013-07-07 19:58:47 +0200 |
---|---|---|
committer | Vegard Storheil Eriksen <zyp@jvnv.net> | 2013-07-07 19:58:47 +0200 |
commit | 06db8315c5a89ede9a6d8094f9dec73301ff1483 (patch) | |
tree | 77a43d342060f60efdc9a88648000914697f6e50 | |
parent | a8a0eb825ea7208502954865ab09e7ec8a90221c (diff) |
LSB should always be 0 on PC popped on exception return.
-rw-r--r-- | os/thread.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/os/thread.h b/os/thread.h index 2213d6f..7486d01 100644 --- a/os/thread.h +++ b/os/thread.h @@ -46,7 +46,7 @@ class Thread { sp->lr_ex = 0xfffffff9; // frame->lr = thread exit handler - sp->pc = (uint32_t)func; + sp->pc = (uint32_t)func & ~1; sp->psr = 0x01000000; } |