Commit Graph

199 Commits

Author SHA1 Message Date
KonstantinKondrashov
6d11c57b2a efuse: Adds ERR_RST_ENABLE efuse for C3 and S3
Closes https://github.com/espressif/esp-idf/issues/8357
2022-03-02 18:48:42 +08:00
wuzhenghui
1a4d4b9cd6 remove esp32h2 rev1/2 unsupported efuse field 2022-02-28 19:37:43 +08:00
wuzhenghui
95418fd22e remove esp32c3 unsupported efuse field 2022-02-28 19:37:38 +08:00
KonstantinKondrashov
9605f3eb1a soc: Adds efuse hal
Replaced eFuse ROM funcs with hal layer
2022-02-24 22:20:09 +08:00
Darian Leung
57fd78f5ba freertos: Remove legacy data types
This commit removes the usage of all legacy FreeRTOS data types that
are exposed via configENABLE_BACKWARD_COMPATIBILITY. Legacy types can
still be used by enabling CONFIG_FREERTOS_ENABLE_BACKWARD_COMPATIBILITY.
2022-02-09 23:05:45 +08:00
Mahavir Jain
68f67db984 Merge branch 'feature/efuse_esp8684' into 'master'
efuse(esp32c2): Support eFuse key APIs

Closes IDF-3818

See merge request espressif/esp-idf!16290
2022-02-01 11:30:00 +00:00
KonstantinKondrashov
ebdc52d4e2 efuse(esp32c2): Support eFuse key APIs 2022-02-01 17:30:31 +08:00
KonstantinKondrashov
45d2d2470b efuse: Fixes eFuse timesettings issue on esp32S3 2022-01-25 22:09:14 +08:00
Mahavir Jain
c4ddfc9f06 Merge branch 'bugfix/efuse_timesettigs_in_burn_op' into 'master'
efuse: Fixes eFuse timesettings issue on esp32c3

Closes FCS-849

See merge request espressif/esp-idf!16885
2022-01-25 03:44:51 +00:00
KonstantinKondrashov
4ede9aaa26 efuse: Fixes eFuse timesettings issue on esp32c3 2022-01-21 16:45:50 +08:00
laokaiyao
cf049e15ed esp8684: rename target to esp32c2 2022-01-19 11:08:57 +08:00
chenjianxing
7a9947f3c6 esp_phy: Update ESP32S2 phy lib to support eco1 chip 2022-01-07 19:59:41 +08:00
Cao Sen Miao
d397464fc4 spi_flash: refactor spi_flash.h to esp_rom_spiflash.h but keep the content in spi_flash.h 2021-12-30 14:12:31 +08:00
Cao Sen Miao
b0decda1e3 bootloader: move bootloader flash support to isolate folders 2021-12-30 14:05:12 +08:00
Armando
4dc0d6b2fe adc: support adc dma driver on all chips 2021-12-16 00:19:15 +00:00
Armando
bfb2a264c6 adc: update adc calibration efuse version
ADC calibration scheme and algorithm are not changed. Only the eFuse bit BLOCK1_VERSION is changed. This MR updated the logic to recognize the adc efuse version
2021-12-13 13:00:13 +08:00
Cao Sen Miao
eddc196081 esp_clk: refactor target/clk.h to private/esp_clk.h 2021-11-26 14:56:30 +08:00
Michael (XIAO Xufeng)
c4310fb0db Merge branch 'feature/add_h2_beta2_target_support' into 'master'
esp32h2: Add support for esp32h2 beta2 version

Closes IDF-4230

See merge request espressif/esp-idf!15630
2021-11-26 03:56:01 +00:00
laokaiyao
f21020ce04 esp32h2: update reg and struct for beta2 2021-11-24 12:34:17 +08:00
Mahavir Jain
9cecde6fb4 bootloader: add anti-FI checks around secure version in anti-rollback scheme 2021-11-24 11:37:27 +08:00
morris
2e008825a9 Merge branch 'feat/rm_makefiles' into 'master'
Build & config: Remove leftover files from the unsupported make build system

Closes IDF-4273 and IDF-2827

See merge request espressif/esp-idf!15829
2021-11-16 03:44:41 +00:00
Gustavo Henrique Nihei
626d78c2e0 efuse: Add missing esp_rom_sys.h include file
This prevents the compiler error for the implicit declaration of
function "esp_rom_printf".

Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-11-12 17:35:59 -03:00
Gustavo Henrique Nihei
5f0e213d9d efuse: Enable C++ linkage for the include headers on esp_efuse.h
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-11-12 09:17:02 -03:00
Gustavo Henrique Nihei
77a6347849 efuse: Add missing stdbool.h include file
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-11-11 18:04:26 -03:00
Roland Dobai
766aa57084 Build & config: Remove leftover files from the unsupported "make" build system 2021-11-11 15:32:36 +01:00
Cao Sen Miao
3934e24d22 ESP8684: add spi_flash, efuse, hw_support support 2021-11-06 17:33:44 +08:00
KonstantinKondrashov
f45d25d380 efuse_table_gen: Fixes wrong joining fields with omitted names
The issue is related to the non-sequential way of description when
such fields going together sequential.

Related to esp32h2 chip for eFuses: MAC_FACTORY and MAC_EXT.
The issue is in wrong indexes of MAC_EXT.
MAC_EXT got indexes like it is joined to MAC_FACTORY.

const esp_efuse_desc_t* ESP_EFUSE_MAC_FACTORY[] = {
    &MAC_FACTORY[0],
    &MAC_FACTORY[1],
    &MAC_FACTORY[2],
    &MAC_FACTORY[3],
    &MAC_FACTORY[4],
    &MAC_FACTORY[5],
    NULL
};

const esp_efuse_desc_t* ESP_EFUSE_MAC_EXT[] = {
    &MAC_EXT[6],
    &MAC_EXT[7],
    NULL
};

This commit fixed it to:

const esp_efuse_desc_t* ESP_EFUSE_MAC_EXT[] = {
    &MAC_EXT[0],
    &MAC_EXT[1],
    NULL
};
2021-10-28 23:53:38 +08:00
zhangwenxu
55fd8cb685 efuse: fix esp32h2 get ext_mac 2021-10-28 23:53:38 +08:00
Marek Fiala
ff18a96f7d tools: replace _ with - in idf.py
Closes https://github.com/espressif/esp-idf/issues/5126
2021-10-13 17:30:38 +08:00
Wu Zheng Hui
85651b4791 efuse: remove DIS_RTC_RAM_BOOT efuse bit 2021-09-18 14:58:43 +08:00
Wu Zheng Hui
1080e4f6a2 rename APB_CTRL ro SYS_CON
save
2021-09-16 20:57:57 +08:00
Armando
c45c6f52f1 adc: support adc efuse-based calibration on esp32s3 2021-09-14 11:42:50 +08:00
KonstantinKondrashov
3cf4fbc150 efuse(esp32s2): Added flash_ver, psram_ver, pkg_ver efuses 2021-08-06 13:14:54 +08:00
Zim Kalinowski
1fd56e0b87 Merge branch 'feature/systimer_generate_rtos_tick' into 'master'
freertos(esp32s3): SysTick uses systimer

Closes IDF-2613

See merge request espressif/esp-idf!12246
2021-08-04 12:33:52 +00:00
Konstantin Kondrashov
29f581fc70 freertos(esp32s3): SysTick uses systimer 2021-08-04 20:33:44 +08:00
KonstantinKondrashov
40c360a096 efuse: Add CUSTOM_MAC address for ESP32-C3/-S2/-S3/-H2 2021-08-02 14:43:27 +05:00
KonstantinKondrashov
b8dd163149 efuse: Fix len of SOFT_DIS_JTAG for esp32c3 and esp32h2 2021-07-21 12:10:09 +05:00
zhangwenxu
d5b9078e23 efuse: add mac extension address for esp32h2 2021-07-20 12:03:17 +08:00
Angus Gratton
fcd193b024 docs: Use soc_caps instead of chip names for flash encryption docs
Clears the way for ESP32-S3 and future chips.
2021-07-14 16:57:31 +10:00
Shu Chen
2df4ddf998 esp32h2: fixes after rebase 2021-07-01 19:53:50 +08:00
Shu Chen
ee23a489b9 esp32h2: code clean up 2021-07-01 19:53:50 +08:00
Shu Chen
e9a51e410a esp32h2: add stub code for efuse/esp_gdbstub/esp_phy
Only stub code for these components:
 * efuse
 * esp_gdbstub
 * esp_phy
2021-07-01 19:53:11 +08:00
Roland Dobai
407053592e Drop support for unsupported Python versions 2021-06-21 21:48:49 +02:00
Konstantin Kondrashov
4c0cf40a39 efuse: Burn operation does not block reading 2021-06-18 11:52:47 +08:00
Konstantin Kondrashov
f339b3fc96 efuse(esp32): Deprecate esp_efuse_burn_new_values() & esp_efuse_write_random_key()
These functions were used only for esp32 in secure_boot and flash encryption.
Use idf efuse APIs instead of efuse regs.
2021-06-17 07:21:36 +08:00
Angus Gratton
fe94de0310 Merge branch 'update_copyright_notice_efuse' into 'master'
efuse: update copyright notice

See merge request espressif/esp-idf!13782
2021-06-01 06:54:49 +00:00
KonstantinKondrashov
4d35b1fc5b efuse: Updates common_efuse_table for all chips 2021-05-31 08:42:57 +00:00
KonstantinKondrashov
29f853633d efuse: Adds support structure of efuses in efuse_table
Supported a new format of efuse description using '.' in the name.
It means that RD_DIS.KEYx belongs to the range of the RD_DIS name.
RD_DIS,                           EFUSE_BLK0,   32,    7,     Read protection
    RD_DIS.KEY0,                  EFUSE_BLK0,   32,    1,     Read protection for EFUSE_BLK4.
    RD_DIS.KEY1,                  EFUSE_BLK0,   33,    1,     Read protection for EFUSE_BLK5.
2021-05-31 08:42:57 +00:00
Jan Brudný
1bac0d1e42 efuse: update copyright notice 2021-05-31 06:43:23 +02:00
Jiang Jiang Jian
3c30e688c4 Merge branch 'feature/support_auto_adjust_voltage_storingInEfuse_openGlitchRst' into 'master'
ESP32C3: auto adjust voltage dbias storing in efuse and open glitch reset for ECO3

See merge request espressif/esp-idf!13395
2021-05-13 03:49:59 +00:00
chaijie
eea76d14bb ESP32C3: auto adjust voltage dbias storing in efuse and open glitch reset for ECO3
1. add some efuse api to get rtc & digital voltage
2. set dig_rtc voltage to a fix value storing in efuse no mater which cpu frequency
3. modify hardware code in bootloader to fit all c3 ECO3 version
2021-05-08 17:56:54 +08:00
KonstantinKondrashov
9490d78f49 efuse/esp32s3: Update efuse table 2021-05-04 14:40:15 +08:00
Angus Gratton
7bb5c8cc82 esp32c3 espefuse: Fix efuse programming timing on ESP32-C3 ECO3
Without this timing change, efuse programming occasionally appears to fail
(although the efuse is programmed correctly).
2021-04-23 13:42:23 +10:00
Armando
c05fde2cbf efuse: revert ESP_LOG to ESP_EARLY_LOG in src/esp_efuse_utility.c
Closes https://github.com/espressif/esp-idf/issues/6660
2021-03-24 11:28:45 +00:00
Angus Gratton
d6f4d99d93 core system: Fix warnings in compilation when assertions are disabled
Adds a CI config for hello world that sets this, to catch future regressions
2021-03-03 10:26:57 +11:00
Angus Gratton
501af6dfa2 Merge branch 'feature/secure_boot_revoke_check' into 'master'
secure_boot: Checks secure boot efuses

Closes IDF-2609

See merge request espressif/esp-idf!12148
2021-02-25 22:38:42 +00:00
Michael (XIAO Xufeng)
db1c635db4 Merge branch 'feature/esp32c3_rtc_temp_calibration' into 'master'
temperature_sensor: calibration for esp32c3

Closes IDF-2502

See merge request espressif/esp-idf!12158
2021-02-24 03:27:49 +00:00
Cao Sen Miao
85855ad8a6 temp_sensor: add calibration for esp32c3 2021-02-23 10:48:17 +08:00
KonstantinKondrashov
90f2d3199a secure_boot: Checks secure boot efuses
ESP32 V1 and V2 - protection bits.
ESP32xx V2: revoke bits, protection bits

- refactor efuse component
- adds some APIs for esp32 chips as well as for esp32xx chips
2021-02-23 03:56:21 +08:00
morris
bf2480f62d efuse: can disable boot ROM log from Kconfig 2021-02-22 20:56:43 +08:00
KonstantinKondrashov
43ebb8ea61 efuse: Updates description of uart_print_control efuse 2021-02-08 18:02:55 +08:00
Angus Gratton
018d7c2551 Merge branch 'feature/add_pkg_and_revision_for_c3' into 'master'
efuse(esp32c3): Adds getting chip_revision and chip_pkg

See merge request espressif/esp-idf!12060
2021-02-04 16:04:36 +08:00
Fu Hanxi
0146f258d7 style: format python files with isort and double-quote-string-fixer 2021-01-26 10:49:01 +08:00
KonstantinKondrashov
3ed226c362 efuse(esp32c3): Adds getting chip_revision and chip_pkg 2021-01-25 19:37:40 +08:00
Armando
f5f0461264 tmpsensor: add temp_sensor.h for c3 2021-01-25 04:51:40 +00:00
Michael (XIAO Xufeng)
d7d1dee208 system: reset dma when soft reset 2021-01-25 04:51:40 +00:00
Mahavir Jain
2cdc1fcdbf efuse: change prints to ESP_EARLY_LOG for function called from startup code 2021-01-22 18:00:03 +05:30
Angus Gratton
fe8a891de9 Merge branch 'feature/support_esp32c3_master_cmake_secure_boot' into 'master'
bootloader/esp32c3: Support secure boot

Closes IDF-2115

See merge request espressif/esp-idf!11797
2021-01-21 08:42:49 +08:00
KonstantinKondrashov
98f726fa4b bootloader/esp32c3: Adds secure boot (not yet supported) 2021-01-19 20:51:13 +08:00
Krzysztof
90c0876b8a docs: Update typos in 'esp_efuse.h' header file to show function descriptions 2021-01-08 15:29:52 +08:00
Michael (XIAO Xufeng)
707b1bd9b1 efuse: revert EARLY_LOGD to LOGD
introduced in 5cc329b9d0
2020-12-30 12:37:44 +08:00
jiangguangming
867255bbab efuse: Add support ESP32-C3
Updated:
- CSV eFuse table
- Kconfig
- efuse_table_gen.py
- UTs
- espefuse.py

efuse/c3: Fix the burn order of BLOCKs (MAX->0)

efuse/c3: Support efuse API with keys, protection, purpose bits

tool/ci: Adds test_efuse_table_on_host for esp32s3 and esp32c3
2020-12-23 18:39:18 +08:00
Konstantin Kondrashov
4a487af43a efuse: Add new APIs for keys, purposes, wr/rd protection
- the batch mode can be called recursively
2020-12-04 10:42:57 +08:00
Wu Bo Wen
5cc329b9d0 driver/adc: support for esp32s2 adc calibration scheme V2
notice that the o_code is now pulled from efuse instead of automatically calibrated. This may influence other parts of the system.

Closes https://github.com/espressif/esp-idf/issues/5455
2020-12-03 20:08:59 +08:00
martin.gano
f4ea2dcb74 Tools: add Python 2 deprecation warning 2020-12-02 11:08:48 +01:00
Angus Gratton
5228d9f9ce esp32c3: Apply one-liner/small changes for ESP32-C3 2020-12-01 10:58:50 +11:00
Angus Gratton
66fb5a29bb Whitespace: Automated whitespace fixes (large commit)
Apply the pre-commit hook whitespace fixes to all files in the repo.

(Line endings, blank lines at end of file, trailing whitespace)
2020-11-11 07:36:35 +00:00
Angus Gratton
e82eac4354 cmake: Apply cmakelint fixes 2020-11-11 07:36:35 +00:00
KonstantinKondrashov
f2c9c1e4ab efuse: Fix the order of writing in batch mode for esp32s2 and s3 2020-11-06 07:25:35 +00:00
KonstantinKondrashov
66b9b589cb efuse: Adds support for esp32-s2 chip 2020-10-14 16:26:51 +08:00
morris
9fa06719fa global: enable build uinit test for esp32-s3 2020-09-22 15:15:03 +08:00
morris
61f89b97c6 bringup esp32-s3 on FPGA 2020-09-22 15:15:03 +08:00
Marius Vikhammer
ae0931be06 CI: Increase stack size for efuse unit test
"Batch mode is thread-safe" case would occasionally cause a stackoverflow.
Increased stack size.
2020-09-21 12:23:14 +08:00
Michael (XIAO Xufeng)
3b2e8648eb bootloader: create public bootloader_flash.h header
Move non-public functions into bootloader_flash_priv.h header
2020-09-19 10:52:02 +08:00
KonstantinKondrashov
2373f115fc efuse/esp32: Expands PKG_VER from 3 bit to 4 bits
Closes: IDF-1919
2020-09-17 07:44:37 +00:00
Jakob Hasse
20c068ef3b cmock: added cmock as component
* changing dependencies from unity->cmock
* added component.mk and Makefile.projbuild
* ignore test dir in gen_esp_err_to_name.py
* added some brief introduction of CMock in IDF
2020-09-02 16:38:37 +08:00
Sachin Billore
f1dae0d6e1 ESP32 SecureBoot V2: eFuse write operations are updated to use the eFuse Manager APIs
Closes IDF-2034

Closes https://github.com/espressif/esp-idf/issues/5771
2020-08-27 04:24:04 +00:00
morris
458b14a8ea esp_rom: extract common efuse apis into esp_rom_efuse.h 2020-07-15 10:40:50 +08:00
Renz Christian Bagaporo
362d7b8f71 efuse: spelling fix 2020-06-19 18:40:10 +10:00
Angus Gratton
a5683f2263 Merge branch 'bugfix/efuse_logs' into 'master'
esp32/esp32s2: Reduce using ESP_EARLY_LOGx and move some code after the stdout initialization in startup code

Closes IDFGH-3367

See merge request espressif/esp-idf!8904
2020-06-16 13:47:02 +08:00
KonstantinKondrashov
5cfdf1aa70 efuse: Add some fields in efuse_table and update esp_efuse_get_pkg_ver()
Closes: IDF-1077
2020-06-08 22:35:08 +08:00
KonstantinKondrashov
3bb2d581c6 esp32: Reduce using ESP_EARLY_LOGx and move some code after the stdout initialization
After setting _GLOBAL_REENT, ESP_LOGIx can be used instead of ESP_EARLY_LOGx.

Closes: https://github.com/espressif/esp-idf/issues/5343
2020-06-01 20:36:08 +08:00
Angus Gratton
f4edc52fa0 efuse: Have support for secure DL mode depend on a soc_caps flag 2020-05-28 18:02:02 +10:00
Angus Gratton
f64ae4fa99 efuse: Add 'disable Download Mode' & ESP32-S2 'Secure Download Mode' functionality 2020-05-28 17:50:45 +10:00
Angus Gratton
48d9c14c28 efuse: Add new esp_efuse_read_field_bit() convenience function 2020-05-28 17:45:09 +10:00
Angus Gratton
1dd5a4dba4 efuse: Add new esp_efuse_write_field_bit() convenience function 2020-05-28 17:45:09 +10:00
Angus Gratton
158ab5a9b9 Remove "disable ROM BASIC boot mode" from ESP32-S2
Feature removed from ESP32-S2 ROM (was present in S2 Beta ROM)
2020-05-01 16:16:47 +10:00
Angus Gratton
9300f0e7b0 Merge branch 'bugfix/logging_compilation_fix_anti_rollback' into 'master'
Minor fix logging issue hindering compilation on anti rollback.

See merge request espressif/esp-idf!8105
2020-04-08 15:53:48 +08:00
Angus Gratton
16ad24dd00 efuse: Add an API to return the efuse descriptor for a key block's purpose field 2020-04-06 18:33:11 +10:00
Supreet Deshpande
0a52f2db50 Fixes logging issue hindering compilation on anti rollback. 2020-03-31 11:19:27 +05:30