mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-07 01:04:19 +08:00
HOTFIX:Backport Memory corruption due to stack coloring overreach complete (#6848)
Backport of upstream NuttX
86400a252dcbe6e4aef3ecca000b469a0fe96b67
08e92abb0ba744927ed0b32294859b0f47726f82
4b65817e99cbdf04fefad883eca0e7c8a9add63c
Improper rounding in redundant stack coloring
routines could overwriting the TOS+1 and BOS-1
depending on the value of CONFIG_ARCH_INTERRUPTSTACK
This applies the compelet upstream set of fixes from
David Cabecinhas <david.cab+bitbucket@gmail.com>
Improper rouding in redundant stack coloring
routines was overwriting the TOS+1 and BOS-1
The legacy OABI 4 byte stack alingment was removed
Only the EABI 8 byte alinement is supported
The redundant interrupt stack coloring. up_initalize
had the correct implemantation (last verson of patch)
and the redundant version in the
arch/arm/src/stmxxx/stmxx_irq.c was calculating the size
wrong.
This is fixed by rounding up CONFIG_ARCH_INTERRUPTSTACK
by 4 bytes when allocated and alining on a 8 byte boundry
This commit is contained in: