esp-idf/components/xtensa
Jakob Hasse 19eab31660 [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-05-10 19:21:56 +08:00
..
esp32 misc adjustment of esp32 component 2019-04-03 19:57:46 +08:00
include esp32: Switch SPIRAM stack in esp_restart_noos() to internal stack 2020-12-08 16:55:50 +00:00
CMakeLists.txt cmake: some formatting fixes 2019-06-21 19:53:29 +08:00
component.mk [system]: Made longjmp save for context switch 2021-05-10 19:21:56 +08:00
debug_helpers_asm.S esp32: Refactor backtrace and add esp_backtrace_print() 2019-06-19 18:30:18 +08:00
debug_helpers.c esp32: Refactor backtrace and add esp_backtrace_print() 2019-06-19 18:30:18 +08:00
eri.c create xtensa component 2019-03-27 20:24:28 +08:00
linker.lf ldgen: update component linker fragment files 2019-04-04 15:57:34 +08:00
trax.c create xtensa component 2019-03-27 20:24:28 +08:00