-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
tests/kernel/fatal/kernel.common.stack_sentinel fails on FRDM-KW41Z #18590
Comments
I don't have the board to test this. Does not seem to fail on frdm_k64f, @galak |
Agreed, this failure seemed unique to the FRDM-KW41Z. Which is a Cortex-M0+ so not sure if maybe a core or memory size issue. |
Cortex M0 fatal error handling code is incorrectly reporting this as a CPU exception instead of a stack overflow |
I'll try with another Cortex M0+ I have available, and report back |
Test passes on nrf51_pca10028 (Cortex-M0) but fails, similarly, on atsamr21_xpro (Cortex-M0+) |
Looks like the root cause of this is that an SVC is triggered inside an interrupt, and the interrupt has equal priority. @andrewboie @galak why do we not reserve an IRQ level for SVC in Cortex-m0? |
I know that without the BASEPRI, then, irq_lock() will disable SVC interrupts, as well; that might be the reason for not reserving the highest priority for SVC. But then, @andrewboie there is a bug in Z_ARCH_EXCEPT For ARM Cortex-M Baseline, cause svc's may not be blocked due to insufficient priority. |
Verified on FRDM-KW41Z that it fixes the issue. |
With commit: aed767a
Running via:
./scripts/sanitycheck -p frdm_kw41z --device-testing --device-serial /dev/serial/by-id/usb-ARM_DAPLink_CMSIS-DAP_0201000028634e45000b5002673a0032a101000097969900-if01 -s tests/kernel/fatal/kernel.common.stack_sentinel
Get the following output:
The text was updated successfully, but these errors were encountered: