Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable STM32 abort #886

Merged
merged 2 commits into from
Oct 24, 2023
Merged

Enable STM32 abort #886

merged 2 commits into from
Oct 24, 2023

Conversation

UncleGrumpy
Copy link
Collaborator

These changes are made under both the "Apache 2.0" and the "GNU Lesser General
Public License 2.1 or later" license terms (dual license).

SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later

Copy link
Collaborator

@fadushin fadushin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one (potential, but benign?) memory leak

src/platforms/stm32/src/main.c Show resolved Hide resolved
src/platforms/stm32/src/main.c Show resolved Hide resolved
@UncleGrumpy UncleGrumpy force-pushed the stm32_abort branch 2 times, most recently from bbfe6c3 to 025a007 Compare October 24, 2023 14:41
- Impliment newlib stubs to support `getpid()` and `kill()` needed for
`AVM_ABORT()` to work properly.
- Redefine weak linked `hard_fault_handler` defined in libopencm3/cm3/nvic.h to
use `AVM_ABORT()` rather than get trapped in the default do nothing `while(1)`
loop.

Signed-off-by: Winford <[email protected]>
Adds the cmake configuration option `AVM_CONFIG_REBOOT_ON_NOT_OK` to allow the
automatic rebooting of the device if the user application exits with any return
value other than `ok`.

Signed-off-by: Winford <[email protected]>
@fadushin fadushin merged commit 33da149 into atomvm:master Oct 24, 2023
5 checks passed
@UncleGrumpy UncleGrumpy deleted the stm32_abort branch October 26, 2023 03:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants