Fix the SPIRAM_BANKSWITCH that was defined incorrectly

This commit is contained in:
Alan C. Assis 2020-11-18 11:50:20 -03:00 committed by Abdelatif Guettouche
parent e7c99480ea
commit 50e1a49c6e
3 changed files with 5 additions and 4 deletions

View file

@ -591,7 +591,7 @@ config ESP32_SPIRAM_2T_MODE
Applications will not be affected unless the use the esp_himem
APIs, which are not supported in 2T mode.
config SPIRAM_BANKSWITCH_ENABLE
config ESP32_SPIRAM_BANKSWITCH_ENABLE
bool "Enable bank switching for >4MiB external RAM"
default y
help
@ -610,7 +610,7 @@ config SPIRAM_BANKSWITCH_ENABLE
config SPIRAM_BANKSWITCH_RESERVE
int "Amount of 32K pages to reserve for bank switching"
depends on SPIRAM_BANKSWITCH_ENABLE
depends on ESP32_SPIRAM_BANKSWITCH_ENABLE
default 8
range 1 62
help

View file

@ -70,7 +70,7 @@
/* How many 32KB pages will be reserved for bank switch */
#if CONFIG_SPIRAM_BANKSWITCH_ENABLE
#if CONFIG_ESP32_SPIRAM_BANKSWITCH_ENABLE
# define SPIRAM_BANKSWITCH_RESERVE CONFIG_SPIRAM_BANKSWITCH_RESERVE
#else
# define SPIRAM_BANKSWITCH_RESERVE 0

View file

@ -143,7 +143,8 @@ int esp32_bringup(void)
#endif
#if defined(CONFIG_ESP32_SPIRAM)
#if defined(CONFIG_ESP32_SPIRAM) && \
defined(CONFIG_ESP32_SPIRAM_BANKSWITCH_ENABLE)
ret = esp_himem_init();
if (ret < 0)
{