-
Notifications
You must be signed in to change notification settings - Fork 3k
Closed
Labels
Description
Description
If the fault handler is hit before the stdio console is used and initialised, the initialisation code causes a "mutex in ISR" trap, stopping the register dump from happening. eg (in GCC, if it matters), this won't show a dump:
int *ptr;
int main()
{
*ptr = 1;
}
This tends to hit Greentea tests, which don't use the stdio console (they use their own RawSerial).
These mutex traps are disabled by the error_in_progress flag set when mbed_error is entered, but that doesn't help with the register dump printed by the fault handler before entering mbed_error.
Possible fix might be to temporarily set the error_in_progress at the top of the fault handler, and restore it before calling mbed_error.
Issue request type
[ ] Question
[ ] Enhancement
[X] Bug
0Grit