Commit Graph
806 Commits
Author SHA1 Message Date
yanzihan@espressif.com d0b1371e34 feat(esp_hw_support): use pvt to auto control digital ldo and rtc ldo for esp32c5 2026-02-01 13:24:49 +08:00
morris da14c42596 Merge branch 'fix/esp32_flash_cache_crash_v6.0' into 'release/v6.0'
fix(hw_support): Fix crash when reconfiguring flash from 40 to 80 MHz on ESP32 (v6.0)

See merge request espressif/esp-idf!44898
2026-02-01 10:20:19 +08:00
Mahavir Jain 78464dfab7 Merge branch 'refactor/create_esp_hal_security_v6.0' into 'release/v6.0'
refactor: Created esp_hal_security component (v6.0)

See merge request espressif/esp-idf!45349
2026-01-31 10:28:48 +05:30
Mahavir Jain ee2da28726 Merge branch 'feat/esp_tee_backports_v6.0' into 'release/v6.0'
feat(esp_tee): Feature/fixes backports to `release/v6.0`

See merge request espressif/esp-idf!45095
2026-01-31 10:27:34 +05:30
Aditya Patwardhan 4d3cfefc2e refactor(esp_hal_security): Updated esp_hal_security build and includes 2026-01-30 17:12:54 +05:30
Jiang Jiang Jian d3e1887bbc Merge branch 'fix/p4_min_rev_usage_v6.0' into 'release/v6.0'
P4: fix wrong rev_min usage in rom and other places (v6.0)

See merge request espressif/esp-idf!45223
2026-01-30 10:50:51 +08:00
Laukik Hase 421246323a feat(esp_tee): Add support for the RISC-V H/W stack guard mechanism 2026-01-29 11:49:14 +05:30
Xiao Xufeng 79f7427729 fix(esp32p4): fix efuse, encryption and other rev_min usage 2026-01-28 21:46:00 +08:00
Xiao Xufeng 32e4e83f84 Revert "fix(esp_system): limit CPU clock to 160MHz in ESP32-C5 for flash encryption"
This reverts commit cca0ac8c56.
2026-01-15 23:44:05 +08:00
Xiao Xufeng 206274d298 refactor(startup): make flash_init_state static 2026-01-13 18:01:32 +08:00
Mattias Schäffersmann 5faff98cc5 fix(hw_support): Fix crash when reconfiguring flash from 40 to 80 MHz
Reading from the flash while it is being reconfigured leads to data
corruption and a crash when the reconfiguration code is located in flash.
This is only an issue if a device has a bootloader that runs with 40 MHz
flash and an application flashed via OTA that runs with 80 MHz flash.
If bootloader and application run with the same flash speed, the
reconfiguration is basically a no-op and no data corruption occurs.
Fix reconfiguration by placing the code back into IRAM.

Issue introduced in: 7549d08

Closes: https://github.com/espressif/esp-idf/pull/17905
2026-01-13 18:01:32 +08:00
Jiang Jiang Jian 12d0df2537 Merge branch 'bugfix/fix_pvt_after_sleep_v6.0' into 'release/v6.0'
fix(pvt): fix pvt retention bug,replace pvt_retention with pvt_init

See merge request espressif/esp-idf!44927
2026-01-12 15:38:56 +08:00
zlq 1d41de96d8 fix(pvt): fix pvt retention bug,replace pvt_retention with pvt_init 2026-01-09 15:44:53 +08:00
Xiao Xufeng cca0ac8c56 fix(esp_system): limit CPU clock to 160MHz in ESP32-C5 for flash encryption
This reverts commit 7145fc9558.
2025-12-24 02:31:42 +08:00
Jiang Jiang Jian f409428bf3 Merge branch 'bugfix/esp32c5_encrypted_flash_write_v6.0' into 'release/v6.0'
fix(spi_flash): Add CPU frequency switching during flash encrypted write (v6.0)

See merge request espressif/esp-idf!44304
2025-12-21 15:28:33 +08:00
Jiang Jiang Jian ac1e81f980 Merge branch 'fix/esp32p4_eco5_multicore_wfi_autoclock_gating_v6.0' into 'release/v6.0'
fix(esp_hw_support): enable core1 auto clock gating for esp32p4 rev3+ multicore (v6.0)

See merge request espressif/esp-idf!44255
2025-12-21 15:22:15 +08:00
Xiao Xufeng 469953bd04 Revert "fix(esp_system): limit CPU clock to 160MHz in ESP32-C5 for flash encryption"
This reverts commit 3c5d2e6b58.
2025-12-17 01:21:46 +08:00
Xiao Xufeng ae7124abe3 feat(spi_flash): implement dynamic CPU frequency switching workaround for encrypted writes
This commit implements a workaround that allows ESP32-C5 to run at 240MHz CPU frequency
normally, while automatically reducing CPU frequency during encrypted flash writes to
ensure correct operation. The frequency limit is chip revision dependent:
- v1.2 and above: limited to 160MHz during encrypted writes
- v1.0 and below: limited to 80MHz during encrypted writes

Key implementation details:
- Frequency limiting is triggered automatically when esp_flash_write_encrypted() is called
- Uses start() flags (ESP_FLASH_START_FLAG_LIMIT_CPU_FREQ) to integrate with OS layer
- Works with both PM enabled and disabled configurations
- Frequency is automatically restored after encrypted write completes
- For ESP32-C5 with 120MHz flash, Flash clock and timing registers are adjusted when
  CPU frequency is reduced to 80MHz
- SPI1 timing registers are configured during frequency switching since encrypted writes
  use SPI1 and must work correctly at reduced CPU frequencies

Code improvements:
- Use SOC_MSPI_FREQ_AXI_CONSTRAINED capability macro instead of hardcoded chip checks
- Control workaround via Kconfig (CONFIG_PM_WORKAROUND_FREQ_LIMIT_ENABLED) instead of
  hardcoded macros
- Add comprehensive test cases covering various PM configurations and edge cases

This workaround enables ESP32-C5 applications to benefit from 240MHz CPU performance
while maintaining reliable encrypted flash write functionality.
2025-12-17 01:21:45 +08:00
Chen Chen 1b015d22eb refactor(esp_system): clear dependency on hal components 2025-12-16 09:11:59 +08:00
Samuel Obuch 5908c9574c fix(esp_hw_support): enable core1 auto clock gating for esp32p4 rev3+ multicore 2025-12-15 14:47:54 +01:00
Jiang Jiang Jian 3df1ee13fb Merge branch 'fix/fix_mspi_write_stuck_after_reset_v6.0' into 'release/v6.0'
fix(esp_system): fix mspi write stuck after cpu/digital reset on c5/c61 (v6.0)

See merge request espressif/esp-idf!43994
2025-12-11 13:59:25 +08:00
morris 37c614d626 feat(twai): graduate the hal drivers into esp_hal_twai component 2025-12-10 13:56:47 +08:00
wuzhenghui 01ec965252 fix(esp_system): fix mspi write stuck after cpu/digital reset on c5/c61 2025-12-10 12:21:55 +08:00
morris 4ca7b95d83 Merge branch 'refactor/esp_hal_gpio_v6.0' into 'release/v6.0'
refactor(gpio): split GPIO HAL into separate component (v6.0)

See merge request espressif/esp-idf!43895
2025-12-09 16:02:49 +08:00
Alexey Gerenkov effa1e4248 Merge branch 'feature/update-toolchain-to-esp-15.2.0_20250929.4-6d3fdb7_v6.0' into 'release/v6.0'
Make Picolibc the default libc (v6.0)

See merge request espressif/esp-idf!43966
2025-12-08 18:13:08 +08:00
Song Ruo Jing 62899cbba6 refactor(gpio): split GPIO HAL into separate component
cleaned up some includes in GPIO peripheral files
2025-12-08 14:33:26 +08:00
Jiang Jiang Jian c33b848fea Merge branch 'bugfix/fix_chip_hangup_v6.0' into 'release/v6.0'
bugfix: clear regdma status when restart V6.0

See merge request espressif/esp-idf!43908
2025-12-08 11:07:25 +08:00
Alexey Lapshin ad7f4b9670 feat(esp_libc): make picolibc default libc 2025-12-06 00:08:35 +07:00
sibeibei e5fb2f50ec bugfix: clear regdma status when restart 2025-12-02 10:31:58 +08:00
Song Ruo Jing 1067b313c6 fix(uart): fix some wdt get triggered due to uart sclk not exist on C5
Interrupt wdt would get triggered on uart_driver_install if uart driver was deleted before
Closes https://github.com/espressif/esp-idf/issues/17779

RTC wdt would get triggered on esp_restart if uart driver was deleted before
2025-11-27 11:08:48 +08:00
morris f050c1deb1 Merge branch 'fix/no_function_call_in_min_max_v6.0' into 'release/v6.0'
refactor: avoid function calls inside MIN/MAX macros (v6.0)

See merge request espressif/esp-idf!43476
2025-11-21 12:03:09 +08:00
morris 8242e6914b Merge branch 'feature/ledc_etm_support_v6.0' into 'release/v6.0'
feat(ledc): add ETM support for LEDC peripheral (v6.0)

See merge request espressif/esp-idf!43401
2025-11-21 10:38:11 +08:00
Jiang Jiang Jian 3584d2273e Merge branch 'feat/support_p4_unicore_auto_clock_gating_v6.0' into 'release/v6.0'
feat(esp_hw_support): support unicore auto clock gating for esp32p4 rev3+ (v6.0)

See merge request espressif/esp-idf!43368
2025-11-20 10:32:40 +08:00
morris e9539d4560 refactor: avoid function calls inside MIN/MAX macros 2025-11-18 15:18:14 +08:00
Jiang Jiang Jian 6472c8215a Merge branch 'bugfix/esp32c5_encrypted_flash_write_v6.0' into 'release/v6.0'
fix(esp_system): limit CPU clock to 160MHz in ESP32-C5 for flash encryption (v6.0)

See merge request espressif/esp-idf!43325
2025-11-18 12:27:21 +08:00
Song Ruo Jing 88a183345b fix(console): wrong uart console pin info when UART console is not used 2025-11-14 20:58:17 +08:00
Jiang Jiang Jian 7738347885 Merge branch 'fix/fix_xtal32k_power_breaks_adc_v6.0' into 'release/v6.0'
fix(esp_system): fix XTAL32K power breaks ADC function on 32k XTAL clock pin (v6.0)

See merge request espressif/esp-idf!43295
2025-11-14 16:49:54 +08:00
wuzhenghui 5137558961 feat(esp_hw_support): support unicore auto clock gating for esp32p4 rev3+ 2025-11-14 14:06:23 +08:00
Mahavir Jain 0f77374746 fix(esp_system): limit CPU clock to 160MHz in ESP32-C5 for flash encryption
Encrypted flash write operation sometimes result in random corruption in
certain bytes. Root cause points to sudden current surge due to involvement of
encryption block overwhelming LDO supply. More details will be provided
in the ESP32-C5 SoC Errata document.

This fix limits the CPU clock to 160MHz for flash encryption enabled
case. Failing encrypted flash write tests could successfully pass in
this configuration. Going ahead, a dynamic clock adjustment in flash
driver will be considered to mitigate this issue.
2025-11-13 13:25:57 +05:30
Song Ruo Jing 05c2486d8b fix(clk): 400MHz CPU should still be selectable on ESP32-P4 less than rev3 2025-11-12 22:28:03 +08:00
wuzhenghui a7063c9884 fix(esp_system): fix XTAL32K power breaks ADC function on 32k XTAL clock pin 2025-11-12 19:03:42 +08:00
Chen Jichang dacc106758 feat(esp32h4): switch default h4 build to mp version 2025-11-03 16:27:05 +08:00
Xiao Xufeng 40dd5e3957 dma: fixed issue that DMA are not reset when CPU reset
When DMA keep writing the memory, some data may be corrupted after reset. For example, the stack of bootloader may be overwritten and failed to boot until a higher scope of reset (Core).

Also removed the DPORT_PERIP_RST_EN_REG alias on ESP32S2. Now it's the same as some following chips (EN0).
2025-10-20 01:34:32 +08:00
morris 2de3be7300 feat(dma): graduate the dma driver into a single component 2025-10-19 22:06:46 +08:00
Wu Zheng Hui e1b6006761 Merge branch 'fix/fix_esp32c5_xtal32k_clock_lost_in_sleep' into 'master'
fix(esp_system): manage slow clock sleep pd in select_rtc_slow_clk

See merge request espressif/esp-idf!41591
2025-10-16 15:24:50 +08:00
morris d5ff73e928 Merge branch 'feature/esp32p4_eco5_support' into 'master'
feat(gpio/ledc/uart/2ddma/ppa): ESP32P4 ECO5 related updates

Closes IDF-13419, IDF-13425, IDF-13427, IDF-13436, IDF-13740, IDF-13741, IDF-13675, IDF-12225, IDF-13823, IDF-13514, IDF-13539, and IDF-13533

See merge request espressif/esp-idf!41980
2025-10-16 11:16:34 +08:00
Song Ruo Jing dd5d4bd8d7 feat(2ddma): ESP32P4 ECO5 2DDMA related updates
Added one more pair of 2DDMA channels
Priority bit width increased corespondingly
Added three new CSC modes for RX channel 0
Also cleaned up DMA2D capability definitions in soc_caps.h
2025-10-15 16:49:22 +08:00
Song Ruo Jing 08bc91ecc5 fix(clk): allow P4 CPU clk freq can auto switch between 360/400MHz according to revision 2025-10-15 16:49:21 +08:00
morris e8de5b5a95 refactor(gptimer): clean up SOC capabilities for GPTIMER and Timer Group
- Remove GPTIMER and TIMG related definitions from soc_caps_full.h files
- Move timer peripheral definitions to appropriate HAL layer files
- Update references across components to use proper HAL abstractions
- Consolidate timer group and GPTIMER capabilities organization
- Ensure consistent timer configuration across all ESP32 variants

This refactoring improves the separation of concerns between SOC
capabilities and HAL implementations for timer-related functionality.
2025-10-14 11:44:38 +08:00
wuzhenghui 4bb6a01959 fix(esp_system): fix ext 32k io revoking breaks sleep io holding 2025-10-10 19:44:07 +08:00