]> granicus.if.org Git - esp-idf/commit
bootloader: check previously used clock frequency at run time
authorIvan Grokhotkov <ivan@espressif.com>
Thu, 29 Nov 2018 07:18:11 +0000 (15:18 +0800)
committerIvan Grokhotkov <ivan@espressif.com>
Tue, 26 Feb 2019 09:02:34 +0000 (17:02 +0800)
commit178e5b25e6b6a254e40cca6b0663c398ab732ca5
tree69d331777064caf8a8949a67939307f7e61b9958
parentdda0208614dc418068779780b5eb1bad57579718
bootloader: check previously used clock frequency at run time

In the situation when bootloader was compiled for 240MHz, and app was
compiled for 160MHz, and the chip is a revision 0 chip, the
bootloader will assume that the application has also been running at
240MHz. This will cause the chip to lock up later. Modify this to use
a run time check of DPORT_CPUPERIOD_SEL, which indicates which of the
PLL frequencies was used.

Closes https://github.com/espressif/esp-idf/issues/2731.
components/bootloader_support/src/bootloader_clock.c