summaryrefslogtreecommitdiffstatshomepage
path: root/stmhal/system_stm32f4xx.c
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2014-09-25 15:47:53 +0100
committerDamien George <damien.p.george@gmail.com>2014-09-25 15:47:53 +0100
commitac04a8a56a1591ddbaf6558b8eab9837a7d2f3cb (patch)
tree5e4e6ca0c3c3b45cb1bafff451920e60455069aa /stmhal/system_stm32f4xx.c
parente8ea0724da1b2fd6f6eb1cc99154072159fc2c8d (diff)
downloadmicropython-ac04a8a56a1591ddbaf6558b8eab9837a7d2f3cb.tar.gz
micropython-ac04a8a56a1591ddbaf6558b8eab9837a7d2f3cb.zip
stmhal: Enable 8-byte stack alignment for IRQ handlers.
Diffstat (limited to 'stmhal/system_stm32f4xx.c')
-rw-r--r--stmhal/system_stm32f4xx.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/stmhal/system_stm32f4xx.c b/stmhal/system_stm32f4xx.c
index 4f8090204f..e9742caf40 100644
--- a/stmhal/system_stm32f4xx.c
+++ b/stmhal/system_stm32f4xx.c
@@ -199,6 +199,9 @@ void SystemInit(void)
#else
SCB->VTOR = FLASH_BASE | VECT_TAB_OFFSET; /* Vector Table Relocation in Internal FLASH */
#endif
+
+ /* dpgeorge: enable 8-byte stack alignment for IRQ handlers, in accord with EABI */
+ SCB->CCR |= SCB_CCR_STKALIGN_Msk;
}
/**