From ad188c38543e3aa47f88c900d2f70ffc93b7f69c Mon Sep 17 00:00:00 2001 From: liuzhifu Date: Wed, 24 Aug 2016 15:32:36 +0800 Subject: [PATCH] Remove the workaround that erase flash before calling nvs_flash_init --- components/esp32/cpu_start.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/components/esp32/cpu_start.c b/components/esp32/cpu_start.c index 23e4474810..d9076fb163 100644 --- a/components/esp32/cpu_start.c +++ b/components/esp32/cpu_start.c @@ -206,15 +206,7 @@ void user_start_cpu0(void) { ets_setup_syscalls(); do_global_ctors(); - // TODO: consider ethernet interface - #if CONFIG_WIFI_ENABLED -#if 1 //workaround - for (uint8_t i = 5; i < 8; i++) { - ets_printf("erase sector %d\n", i); - spi_flash_erase_sector(i); - } -#endif ets_printf("nvs_flash_init\n"); esp_err_t ret = nvs_flash_init(5, 3); if (ret != ESP_OK) { @@ -225,6 +217,7 @@ void user_start_cpu0(void) { esp_event_init(NULL); + // TODO: consider ethernet interface tcpip_adapter_init(); #endif -- 2.40.0