If both SPI Flash support (`CONFIG_ESP32S3_SPIFLASH`) and PSRAM (`CONFIG_ESP32S3_SPIRAM`) are enabled, the PSRAM can only be assigned to the user's heap (`CONFIG_ESP32S3_SPIRAM_USER_HEAP`). Additionaly, `CONFIG_ESP32S3_SPI_FLASH_SUPPORT_PSRAM_STACK` must be set because the system will end up allocating tasks' stacks from the external PSRAM. This has an impact when dealing with SPI flash operations because the cache must be disabled and the running task should not rely on any data from the PSRAM. To accomplish that, It offloads the SPI flash operation to a work queue (which, by definition, allocates its heap from the kernel heap). The same (assigning the PSRAM to the user's heap) is valid when the Wi-Fi is enabled because the lower-half driver requires data being allocated from the internal memory (which can only be achieved by allocating from the kernel heap when both the kernel and user heaps exists). Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com> |
||
|---|---|---|
| .. | ||
| include | ||
| src | ||
| CMakeLists.txt | ||
| Kconfig | ||