Skip to content

arm-v7m: beware of stack alignment depending on chip rev.  #8

@Fabo

Description

@Fabo

Depending on the chip revision, the stack alignment is different. For instance with Cortex-M3 rev. 2, the stack is aligned on double word, but for rev. 0 to rev. 1 it is aligned on a single word.

Make sure to support both revisions:
* check every function call made from assembly, and make sure the stack is aligned on double word.
* for the svc instruction, svcall handler is modifying the stack to insert a fake stack frame. Make sure it will work for all revisions.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions