diff options
author | leo chung <gewalalb@gmail.com> | 2021-09-16 17:02:14 +0800 |
---|---|---|
committer | Damien George <damien@micropython.org> | 2021-09-24 12:12:03 +1000 |
commit | 4fdf795efa4eca3a9f8166e33b991a762569ae20 (patch) | |
tree | 88054f79c606e33493d81b812642e649a575274d /docs/esp32/tutorial | |
parent | a39a596b791f14e277ba526f9b6bd8ce2da36550 (diff) | |
download | micropython-4fdf795efa4eca3a9f8166e33b991a762569ae20.tar.gz micropython-4fdf795efa4eca3a9f8166e33b991a762569ae20.zip |
esp32/mpthreadport: Fix TCB cleanup function so thread_mutex is ready.
Because vPortCleanUpTCB is called by the FreeRTOS idle task, and it checks
thread, but didn't check the thread_mutex.
And if thread is not NULL, but thread_mutex not ready then it will crash
with an error when calling mp_thread_mutex_lock(&thread_mutex, 1).
As suggested by @dpgeorge, move the thread = &thread_entry0 line to the end
of mp_thread_init().
Signed-off-by: leo chung <gewalalb@gmail.com>
Diffstat (limited to 'docs/esp32/tutorial')
0 files changed, 0 insertions, 0 deletions