esp-idf/components/xtensa
Jakob Hasse fc22e3c645 [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-04-23 15:55:31 +08:00
..
esp32 xtensa: move out trax 2021-02-26 19:45:48 +08:00
esp32s2 xtensa: move out trax 2021-02-26 19:45:48 +08:00
esp32s3 xtensa: move out trax 2021-02-26 19:45:48 +08:00
include xtensa: move out trax 2021-02-26 19:45:48 +08:00
trax style: format python files with isort and double-quote-string-fixer 2021-01-26 10:49:01 +08:00
CMakeLists.txt xtensa: simplify build script 2021-02-26 19:45:48 +08:00
component.mk [system]: Made longjmp save for context switch 2021-04-23 15:55:31 +08:00
eri.c Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
linker.lf arch: move stdatomic 2021-02-26 18:40:00 +08:00
project_include.cmake esp32: move toolchain check 2021-03-31 19:17:33 +08:00
xt_trax.c xtensa: move out trax 2021-02-26 19:45:48 +08:00
xtensa_intr_asm.S Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
xtensa_intr.c Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00