esp32: Core dump sanity checks were added

- CRC for core dump flash partition config
 - Tasks with corrupted TCBs are skipped
 - Assertions to check that nothing is written beyond core dump flash partition
This commit is contained in:
Alexey Gerenkov
2017-04-20 19:38:38 +03:00
parent 90c8bd93e0
commit 98895af68b
3 changed files with 159 additions and 68 deletions

View File

@@ -67,6 +67,13 @@ void esp_clear_watchpoint(int no);
*/
void esp_panic_wdt_stop(void);
/**
* @brief Checks stack pointer
*/
static inline bool esp_stack_ptr_is_sane(uint32_t sp)
{
return !(sp < 0x3ffae010UL || sp > 0x3ffffff0UL || ((sp & 0xf) != 0));
}
#endif
#ifdef __cplusplus