mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-13 05:47:11 +00:00
all: Apply new version logic (major * 100 + minor)
This commit is contained in:

committed by
BOT

parent
3c18cc482c
commit
1f9260d790
@@ -25,6 +25,7 @@
|
||||
#include "soc/extmem_reg.h"
|
||||
#include "soc/io_mux_reg.h"
|
||||
#include "soc/system_reg.h"
|
||||
#include "soc/chip_revision.h"
|
||||
#include "esp32c3/rom/efuse.h"
|
||||
#include "esp32c3/rom/ets_sys.h"
|
||||
#include "bootloader_common.h"
|
||||
@@ -252,7 +253,7 @@ static inline void bootloader_hardware_init(void)
|
||||
{
|
||||
// This check is always included in the bootloader so it can
|
||||
// print the minimum revision error message later in the boot
|
||||
if (efuse_hal_get_minor_chip_version() < 3) {
|
||||
if (!ESP_CHIP_REV_ABOVE(efuse_hal_chip_revision(), 3)) {
|
||||
REGI2C_WRITE_MASK(I2C_ULP, I2C_ULP_IR_FORCE_XPD_IPH, 1);
|
||||
REGI2C_WRITE_MASK(I2C_BIAS, I2C_BIAS_DREG_1P1_PVT, 12);
|
||||
}
|
||||
@@ -265,8 +266,7 @@ static inline void bootloader_ana_reset_config(void)
|
||||
For ECO2: fix brownout reset bug, support swt & brownout reset;
|
||||
For ECO3: fix clock glitch reset bug, support all reset, include: swt & brownout & clock glitch reset.
|
||||
*/
|
||||
uint8_t chip_version = efuse_hal_get_minor_chip_version();
|
||||
switch (chip_version) {
|
||||
switch (efuse_hal_chip_revision()) {
|
||||
case 0:
|
||||
case 1:
|
||||
//Enable WDT reset. Disable BOR and GLITCH reset
|
||||
|
Reference in New Issue
Block a user