1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

20 Commits

Author SHA1 Message Date
Marian Buschsieweke
59f37cd8f8
cpu/esp_common: fix compilation with modern newlib/gcc 2024-06-02 18:51:07 +02:00
chrysn
756a384442 makefiles, treewide: Remove MCU variable 2024-02-18 20:46:09 +01:00
Gunar Schorcht
e1a613ac5c cpu/esp_common: improve thread safety for locking functions
For ESP32x, the operations on recursive locking variables have to be guarded by disabling interrupts to prevent unintended context switches. For ESP8266, interrupts must not be disabled, otherwise the intended context switch doesn't work when trying to lock a rmutex that is already locked by another thread.
2022-09-02 08:54:31 +02:00
Gunar Schorcht
1eb18c2949 cpu/esp_common: improve thread safety for locking functions
Dynamic allocation and initialization of the mutex used by a newlib locking variable must not be interrupted. Since a thread context switch can occur on exit from an ISR, the allocation and initialization of the mutex must be guarded by disabling interrupts. The same must be done for the release of such a locking variable.
2022-09-01 15:50:26 +02:00
Gunar Schorcht
270001a42e cpu/esp_common: move ESP32 specific locking variables to cpu/esp32 2022-09-01 15:09:58 +02:00
Gunar Schorcht
84893c672b cpu/esp_common: fix lock handling
Assertions for uninitialized locks must not be triggered as long as the scheduler is not running. Furthemore, the handling of the __malloc_static_object lock is only necessary for ESP8266.
2022-06-01 13:31:00 +02:00
Gunar Schorcht
d63c116eba cpu/esp_esp8266: move missing _rename_r function to esp_common 2022-06-01 13:31:00 +02:00
Gunar Schorcht
443f3b87df cpu/esp_common: missing heap functions for ESP-IDF v4.4 2022-06-01 13:27:31 +02:00
Gunar Schorcht
e1c6306bf4 cpu/esp32: replace bzero by memset 2022-01-25 00:36:51 +01:00
Gunar Schorcht
839cf4223d cpu/esp32: changes for retagetable locking 2022-01-25 00:36:51 +01:00
Erik Ekman
e5d60176e4 cpu/esp: Suppress cppcheck errors
cpu/esp_common/syscalls.c💯 error (memleak): Memory leak: mtx
cpu/esp_common/syscalls.c:131: error (memleak): Memory leak: rmtx
cpu/esp_common/syscalls.c:365: error (comparePointers): Subtracting pointers that point to different objects

cpu/esp_common/thread_arch.c:355: error (comparePointers): Comparing pointers that point to different objects

cpu/esp8266/startup.c:59: error (comparePointers): Subtracting pointers that point to different objects
2021-11-25 13:08:51 +01:00
Marian Buschsieweke
6c4f0da7a7
cpu/esp_common: fix bootloop on ESP8266 2021-07-13 20:48:01 +02:00
Marian Buschsieweke
a9dea12eb8
cpu/esp_common: add overflow detection to calloc
If esp_idf_heap is not used, implement calloc through a custom wrapper
function on top of malloc to add overflow detection, which is not
present in the newlib forks with xtensa support yet.
2021-05-10 15:29:48 +02:00
Marian Buschsieweke
2f08f676dc
cpu/esp_common: fix possible overflow in calloc implementation 2021-05-05 08:58:34 +02:00
Bas Stottelaar
22243aec7a cpu/*: realign ENABLE_DEBUG 2020-10-23 00:46:26 +02:00
Bas Stottelaar
ab6188cea3 cpu/*: add missing include of assert.h 2020-10-22 11:13:08 +02:00
Marian Buschsieweke
35d46e6dc3
cpu/esp: Use API to access sched internals
Replace access to `sched_active_task` and `sched_active_pid` with calls to
`thread_getpid()` and `thread_get_active()`.
2020-08-17 14:05:05 +02:00
Gunar Schorcht
fb47f094d3 cpu/esp32: support multiple heaps for newlib
Several unsused DRAM sections are added to the heap.
2020-07-10 08:42:12 +02:00
Gunar Schorcht
33fd259115 cpu/esp: platform heap_stats only used with esp_idf_heap 2020-02-29 12:21:09 +01:00
Gunar Schorcht
90dc2ce846 cpu/esp*: common parts of syscalls in cpu/esp_common 2020-02-21 09:09:34 +01:00