Commit Graph

142 Commits

Author SHA1 Message Date
C.S.M 52d5b1a173 fix(spi_flash): Fix esp32p4 120m flash suspend failed 2026-03-20 15:21:22 +08:00
Song Ruo Jing c7ae253b89 feat(mspi): support 120MHz flash and psram for esp32c61 2026-03-19 14:30:46 +00:00
Chen Jichang 04df934c05 refactor(flash_enc): move esp_flash_encryption_enabled() to efuse component 2026-03-06 18:14:22 +08:00
Xiao Xufeng dd9706564f fix(tee): fix failed to configure flash on C6 v0.1 and above when REV_MIN_0 configured 2026-02-05 01:19:28 +08:00
Jiang Jiang Jian 31056d5db9 Merge branch 'refactor/spi_flash_private_v6.0' into 'release/v6.0'
refactor(spi_flash): reorganize header files, improve encapsulation and simplify ROM implementation (v6.0)

See merge request espressif/esp-idf!45488
2026-02-02 10:57:34 +08:00
wuzhenghui 0161304269 feat(esp_hw_support): hold MSPI pins in pd_top lightsleep 2026-01-30 15:30:59 +08:00
wuzhenghui ddec7eae60 fix(bootloader): fix bootloader bad spi pin drv config and clear all wpu/wpd by default 2026-01-30 15:30:59 +08:00
Xiao Xufeng 3411286544 refactor(spi_flash): reorganize header files and improve API encapsulation
This commit reorganizes SPI flash header files to better reflect their
visibility and intended usage:

1. Rename `esp_flash_port/` to `esp_flash_chips/`:
   - Better reflects that these headers are for chip driver implementations
   - All chip driver headers moved to `esp_flash_chips/` directory
   - Added README.md explaining semi-public nature of these headers

2. Move internal headers to `esp_private/`:
   - `esp_flash_internal.h` -> `esp_private/esp_flash_internal.h`
   - `memspi_host_driver.h` -> `esp_private/memspi_host_driver.h`

3. Move chip driver related headers to `esp_flash_chips/`:
   - `esp_private/esp_flash_types.h` -> `esp_flash_chips/esp_flash_types.h`
   - `spi_flash/spi_flash_defs.h` -> `esp_flash_chips/spi_flash_defs.h`
   - `spi_flash_override.h` -> `esp_flash_chips/spi_flash_override.h`
   - All `spi_flash_chip_*.h` headers moved to `esp_flash_chips/`

4. Code improvements:
   - Remove unused includes (e.g., `spi_flash_override.h` from `cache_utils.c`)
   - Use public API `esp_flash_get_size()` instead of direct member access
   - Add `esp_flash_is_quad_mode` to linker.lf for IRAM placement

5. Documentation updates:
   - Add README.md in `esp_flash_chips/` explaining semi-public headers
   - Update programming guide with warnings about internal headers
   - Update both English and Chinese documentation

6. Update all references across the codebase:
   - Update includes in `spi_flash` component
   - Update `bootloader_support`, `app_update`, `esp_tee`, `espcoredump`
   - Update example projects

Breaking changes:
- Headers moved to new locations require include path updates
- `custom_flash_driver` example temporarily disabled until external
  components are updated
2026-01-29 03:28:30 +08:00
armando 57e4a5b1e4 change(flash): improve bootloader_flash_read log 2026-01-21 11:45:15 +08:00
wanckl d12f941787 feat(driver_spi): split spi hal component 2025-12-16 20:38:09 +08:00
Alexey Gerenkov 14c53064ff Merge branch 'esp32p4_fix_bootloader_flash_read_allow_decrypt_v6.0' into 'release/v6.0'
fix(bootloader_flash): always invalidate FLASH_READ_VADDR before read (v6.0)

See merge request espressif/esp-idf!43956
2025-12-11 21:02:30 +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
Samuel Obuch 1007a41736 fix(bootloader_flash): invalidate FLASH_READ_VADDR before read
Fixed address to match corresponding mmu_hal_map_region call.
FLASH_MMAP_VADDR was invalidated by mistake in commit
ea38a2e9a4
2025-12-03 10:00:46 +01:00
Song Ruo Jing c1209fc2ac refactor(gpio): remove some useless macros from io_mux_reg.h 2025-11-19 12:17:52 +08:00
Laukik Hase cf36853d0d fix(esp_tee): Handle the SPI1 WB mode incompatibility in TEE flash APIs on ESP32-C5
- When `esp_flash_read()` is invoked from REE, it internally enables WB mode
  via `spi_flash_ll_wb_mode_enable()`. However, the ROM flash APIs used by TEE
  do not support WB mode, resulting in failures when TEE attempts to access
  flash after this call.
- This commit adds a workaround in the TEE flash layer by saving WB mode state,
  temporarily disabling it for ROM API calls, and restoring it afterward.
2025-11-13 15:38:13 +05:30
armando 1f7b1f3615 feat(mspi): supported psram & flash 120MHz timing tuning 2025-11-06 02:20:48 +00:00
C.S.M c81cf3bdf6 refactor(spi_flash): Remove spi_flash rom driver patch config option 2025-10-22 10:37:19 +08:00
Laukik Hase 6e51fac96e Merge branch 'fix/esp_tee_flash_op_bound_checks' into 'master'
fix(esp_tee): Correct flash operation bound checks to handle all overlap cases

Closes IDF-14129

See merge request espressif/esp-idf!41946
2025-10-13 13:31:03 +05:30
Peter Dragun e3198fff3c feat: Update esptool to v5 2025-09-30 15:28:55 +02:00
Laukik Hase 8b92f3603f fix(esp_tee): Correct flash operation bound checks to handle all overlap cases
- Ensure bound checks correctly handle all scenarios, including
  when a requested operation's (SPI0/1) range fully contains the
  TEE-protected region.
- Disable delegation of INTWDT timeout and Cache error interrupts as they reset
  the device after the panic handler
2025-09-30 12:22:25 +05:30
armando 8ebce9b805 change(cache): no use sdkconfig in cache/mmu hal 2025-09-22 01:01:03 +00:00
Konstantin Kondrashov dcf486359e feat(log): Optimize log tag init for bin logging 2025-09-15 15:59:52 +03:00
armando 179d00a6f8 feat(p4): p4 rev3 real chip support 2025-08-28 17:56:16 +08:00
C.S.M 47218f6291 fix(bootloader_flash): Make bootloader flash size accurate 2025-07-30 17:10:59 +08:00
C.S.M b765ad43cf feat(spi_flash): Add flash suspend support on esp32h21, esp32h4 2025-07-21 19:24:00 +08:00
C.S.M 50aee21d33 feat(spi_flash): Add basic support for esp32h4 2025-07-21 19:24:00 +08:00
C.S.M bc9fa040da feat(spi_flash): support spi_flash on esp32h21 2025-07-21 19:24:00 +08:00
Song Ruo Jing b3fd9b6afa fix(clk): XTAL_X2 clock is not usable on H21 MPW and H4 BETA5 2025-07-10 16:35:58 +08:00
Song Ruo Jing 6d293c8582 feat(clk): Add basic clock support for esp32h21 2025-06-16 15:05:32 +08:00
armando 2f8cd616cc test(psram): re-enable 80M psram tests on C5 ECO2 2025-05-22 14:52:40 +08:00
Armando (Dou Yiwen) dadcc7b9f3 Merge branch 'feat/c5_eco2_psram_timing_tuning' into 'master'
mspi: psram 80M timing tuning on C5 ECO2

Closes IDF-13003

See merge request espressif/esp-idf!39232
2025-05-22 06:41:56 +00:00
armando 00e3f4885a feat(mspi): supported psram 80MHz timing tuning 2025-05-22 10:27:19 +08:00
Laukik Hase 12e2df2d74 feat(esp_tee): Support for ESP32-H2 - the rest of the components 2025-05-20 16:31:23 +05:30
Chen Jichang 6c4271d4bb feat(esp32h4): disable unsupported build 2025-03-28 14:41:29 +08:00
Armando (Dou Yiwen) 64ff6ec274 Merge branch 'fix/mutex_between_oct_flash_and_flash_rom_impl' into 'master'
flash: mutex between oct flash and flash rom impl

See merge request espressif/esp-idf!37760
2025-03-21 14:51:08 +08:00
Chen Jichang 45ba78940f feat(esp32h4): finnal introduce hello world 2025-03-19 18:48:41 +08:00
armando cbcee1625f refactor(flash): rename SOC_SPI_MEM_SUPPORT_OPI_MODE to SOC_SPI_MEM_SUPPORT_FLASH_OPI_MOD 2025-03-19 14:01:22 +08:00
wanckl 222b1ddbab fix(driver_gpio): remove gpio_hal_iomux_func_sel 2025-02-19 17:17:51 +08:00
Mahavir Jain 870a1846b1 Merge branch 'feature/esp_tee_flash_prot_spi1' into 'master'
feat(esp_tee): Add support for flash memory isolation and protection (SPI1)

Closes IDF-10481, IDF-10083, and IDF-8915

See merge request espressif/esp-idf!36454
2025-02-12 18:35:49 +08:00
Laukik Hase c23714f775 feat(esp_tee): Add support for flash memory isolation and protection (SPI1) 2025-02-11 12:30:05 +05:30
Chen Jichang 6f83f39dce feat(esp32h4): introduce target esp32h4(stage 1) 2025-02-08 17:07:44 +08:00
Armando (Dou Yiwen) 3aba0ff704 Merge branch 'refactor/mspi_ll' into 'master'
mspi: rename mspi_timing_tuning_ll.h to mspi_ll.h

Closes IDF-11918

See merge request espressif/esp-idf!36039
2025-01-08 16:29:28 +08:00
Armando 14b5db0e87 refactor(mspi): rename to mspi_ll.h 2025-01-07 16:16:06 +08:00
Laukik Hase 1499c65754 feat(esp_tee): Add support for flash memory isolation and protection (SPI0) 2025-01-03 11:44:01 +05:30
gaoxu 25731d0c1e feat(esp32h21): finnal introduce hello world support 2024-12-30 20:14:40 +08:00
C.S.M d448c4ed05 feat(spi_flash): Add 32M flash support on esp32c5 2024-12-25 16:06:43 +08:00
Armando 6528ab5971 refactor(mspi): refactor mspi clock src settings 2024-12-11 14:46:07 +08:00
C.S.M 2b1c27feb4 Merge branch 'feat/custom_flash_component' into 'master'
feature(spi_flash): New customized flash drivers framework, including bootloader📡

Closes IDFGH-8624

See merge request espressif/esp-idf!32774
2024-12-04 18:05:58 +08:00
C.S.M af31ec11f1 feat(spi_flash): New customise flash drivers framework, including bootloader 2024-12-02 17:48:40 +08:00
Laukik Hase 54c3f1bae4 feat(esp_tee): Support for ESP-TEE - bootloader_support component 2024-12-02 12:20:03 +05:30