esp-idf/components/xtensa
Jakob Hasse aba87df4f2 [system]: Made longjmp save for context switch
* Patched longjmp to be context-switch safe
  longjmp modifies the windowbase and windowstart
  registers, which isn't safe if a context switch
  occurs during the modification. After a context
  switch, windowstart and windowbase will be
  different, leading to a wrongly set windowstart
  bit due to longjmp writing it based on the
  windowbase before the context switch. This
  corrupts the registers at the next window
  overflow reaching that wrongly set bit.

  The solution is to disable interrupts during
  this code. It is only 6 instructions long,
  the impact shouldn't be significant.

  The fix is implemented as a wrapper which
  replaces the original first instructions of
  longjmp which are buggy. Then, it jumps back
  to execute the rest of the original longjmp
  function.

  Added a comparably reliable test to the
  test apps.
2021-06-01 07:38:50 +00:00
..
esp32 misc adjustment of esp32 component 2019-04-03 19:57:46 +08:00
esp32s2beta fix errors when ci testing for esp32 2019-06-19 15:31:47 +08:00
include esp32: Switch SPIRAM stack in esp_restart_noos() to internal stack 2020-11-21 07:14:38 +00:00
CMakeLists.txt esp_expression_with_stack: added fake stack frame plus some cleanup on main macro 2019-12-20 13:18:13 -03:00
component.mk [system]: Made longjmp save for context switch 2021-06-01 07:38:50 +00:00
debug_helpers_asm.S esp32: Refactor backtrace and add esp_backtrace_print() 2019-06-19 18:30:18 +08:00
debug_helpers.c esp_rom: Fail immediately if the wrong SoC's header file is included 2019-08-12 16:57:40 +10:00
eri.c create xtensa component 2019-03-27 20:24:28 +08:00
expression_with_stack_xtensa_asm.S expression_with_stack: added a tweak on TCB stackpointers to avoid false trigger of stack overflow 2020-09-10 10:00:32 -03:00
expression_with_stack_xtensa.c expression_with_stack: added a tweak on TCB stackpointers to avoid false trigger of stack overflow 2020-09-10 10:00:32 -03:00
linker.lf ldgen: update component linker fragment files 2019-04-04 15:57:34 +08:00
stdatomic.c ASIO: fixed undefined ref to atomic functions and enabled examples for CI (esp32s2beta) 2019-11-01 11:12:47 +08:00
trax.c create xtensa component 2019-03-27 20:24:28 +08:00