Restart sequence requires set up for app cpu.

This commit is contained in:
Dmitry Yakovlev 2017-04-26 07:47:37 +03:00
parent 32fc0a62b9
commit 00aa73c6cf
2 changed files with 4 additions and 0 deletions

View File

@ -262,6 +262,8 @@ void bootloader_main()
memset(&bs, 0, sizeof(bs)); memset(&bs, 0, sizeof(bs));
ESP_LOGI(TAG, "compile time " __TIME__ ); ESP_LOGI(TAG, "compile time " __TIME__ );
ets_set_appcpu_boot_addr(0);
/* disable watch dog here */ /* disable watch dog here */
REG_CLR_BIT( RTC_CNTL_WDTCONFIG0_REG, RTC_CNTL_WDT_FLASHBOOT_MOD_EN ); REG_CLR_BIT( RTC_CNTL_WDTCONFIG0_REG, RTC_CNTL_WDT_FLASHBOOT_MOD_EN );
REG_CLR_BIT( TIMG_WDTCONFIG0_REG(0), TIMG_WDT_FLASHBOOT_MOD_EN ); REG_CLR_BIT( TIMG_WDTCONFIG0_REG(0), TIMG_WDT_FLASHBOOT_MOD_EN );

View File

@ -173,6 +173,8 @@ void IRAM_ATTR call_start_cpu1()
"wsr %0, vecbase\n" \ "wsr %0, vecbase\n" \
::"r"(&_init_start)); ::"r"(&_init_start));
ESP_EARLY_LOGI(TAG, "Set ets_set_appcpu_boot_addr.");
ets_set_appcpu_boot_addr(0);
cpu_configure_region_protection(); cpu_configure_region_protection();
#if CONFIG_CONSOLE_UART_NONE #if CONFIG_CONSOLE_UART_NONE