esp-idf/components/esp_system
Ivan Grokhotkov b7b9ea4361 newlib: add _RETARGETABLE_LOCKING support
This adds support for the retargetable locking implementation in
newlib 3. This feature will be enabled in the future toolchain builds.
With the present version of the toolchain, this code doesn't get used.

When _RETARGETABLE_LOCKING gets enabled, newlib locking implementation
will be modified as follows:

- Legacy ESP-specific _lock_xxx functions are preserved. This is done
  because ROM copies of newlib in ESP32 and ESP32-S2 rely on these
  functions through the function pointer table. Also there is some
  code in IDF which still uses these locking functions.

- New __retarget_lock_xxx functions are introduced. Newlib expects
  these functions to be provided by the system. These functions work
  pretty much the same way as the ESP-specific _lock_xxx functions,
  except one major difference: _lock_acquire receives the lock pointer
  by value, and as such doesn't support lazy initialization.

- Static locks used by newlib are now explicitly initialized at
  startup. Since it is unlikely that these static locks are used at
  the same time, all compatible locks are set to point to the same
  mutex. This saves a bit of RAM. Note that there are still many locks
  not initialized statically, in particular those inside FILE
  structures.
2020-12-29 16:18:04 +01:00
..
include esp32c3: Add new esp_sleep_is_valid_wakeup_gpio() function 2020-12-24 13:40:01 +11:00
port esp_system: Add port-specific esp32c3 files 2020-12-24 13:40:01 +11:00
test freertos: always enable static allocation 2020-12-29 16:18:04 +01:00
CMakeLists.txt esp_system: remove remaining use of old gdbstub header 2020-12-18 09:32:24 +08:00
component.mk esp_system: support riscv panic 2020-11-13 07:49:11 +11:00
esp_async_memcpy.c async_mcp: add DMA capability to allocated memory 2020-11-17 20:09:14 +08:00
intr_alloc.c Updates for riscv support 2020-11-13 07:49:11 +11:00
Kconfig esp_system: make rtc fast memory to heap configuration unified across chips 2020-12-24 09:46:35 +05:30
linker.lf components/pm: Add sleep related code iram opt chioce 2020-12-23 14:45:36 +08:00
panic.c esp_system: remove remaining use of old gdbstub header 2020-12-18 09:32:24 +08:00
sdkconfig.rename Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
sleep_modes.c Merge branch 'feature/unify_rtc_fast_mem_as_heap_config_across_chips' into 'master' 2020-12-29 11:41:05 +08:00
startup.c newlib: add _RETARGETABLE_LOCKING support 2020-12-29 16:18:04 +01:00
system_api.c esp32c3: Apply one-liner/small changes for ESP32-C3 2020-12-01 10:58:50 +11:00
system_time.c esp32c3: Apply one-liner/small changes for ESP32-C3 2020-12-01 10:58:50 +11:00