Commit Graph

611 Commits

Author SHA1 Message Date
Chen Chen 17d2041821 refactor(i2c): cleanup I2C definitions in soc_caps.h 2026-01-12 17:07:04 +08:00
Jiang Jiang Jian 382dbc04ea Merge branch 'bugfix/fix_esp32_phy_init_bb_clock_issue' into 'master'
bugfix(wifi): fix incomplete phy initialization due to absence of bb clocks at...

Closes ESPCS-1007 and ESPCS-997

See merge request espressif/esp-idf!42511
2026-01-08 20:32:04 +08:00
wuzhenghui 48ba430297 change(esp_hal_rtc_timer): unify lp_timer/rtc_timer naming to RTC_TIMER 2025-12-30 11:35:36 +08:00
Song Ruo Jing e0d3cc040d refactor(uart): clean up uart soc_caps 2025-12-25 14:52:11 +08:00
Song Ruo Jing 643b2508fa refactor(uart): remove soc/uart_channel.h 2025-12-25 14:42:43 +08:00
Song Ruo Jing 74aeb3f41f refactor(uart): split UART HAL into separate component 2025-12-25 14:41:28 +08:00
liuning ea2829f856 bugfix(wifi): fix incomplete phy initialization due to absence of bb clocks at coexistence scenarios 2025-12-24 20:15:48 +08:00
Kevin (Lao Kaiyao) 3665d0b0f6 Merge branch 'feature/graduate_tsens_hal_component' into 'master'
feat(tsens): graduate temperature sensor hal component

Closes IDF-14906

See merge request espressif/esp-idf!44121
2025-12-18 12:44:41 +08:00
laokaiyao 3cfd8d6906 feat(tsens): graduate temperature sensor hal component 2025-12-17 16:09:21 +08:00
Song Ruo Jing 67a738d1de refactor(ledc): split ledc hal into a separate component 2025-12-17 15:26:10 +08:00
Wan Lei a633083633 Merge branch 'fix/spi_clean_soc_caps' into 'master'
refactor(driver_spi): clean spi soc caps

See merge request espressif/esp-idf!44083
2025-12-15 20:48:21 +08:00
C.S.M e3eaee53e2 Merge branch 'ci/esp32s31_build_ena' into 'master'
ci(esp32s31): Add ci build test for esp32s31

See merge request espressif/esp-idf!44045
2025-12-12 14:59:42 +08:00
wanckl 13e1ae57e1 refactor(driver_spi): clean spi soc caps 2025-12-12 11:29:42 +08:00
C.S.M f405e51784 ci(esp32s31): Add ci build test for esp32s31 2025-12-11 15:17:15 +08:00
wanckl 6449181ce0 feat(driver_spi): split spi hal component 2025-12-11 15:00:18 +08:00
morris af02c173fb refactor(soc): remove soc_caps_full.h 2025-12-04 10:48:07 +08:00
laokaiyao e39c9781f3 feat(hal): graudate the adc/dac hal driver into a new component 2025-12-04 10:38:24 +08:00
morris ab4200e6f6 feat(twai): graduate the hal drivers into esp_hal_twai component 2025-12-01 22:32:54 +08:00
morris 580d9bca57 Merge branch 'refactor/esp_hal_gpio' into 'master'
refactor(gpio): split GPIO HAL into separate component

Closes IDF-14089

See merge request espressif/esp-idf!43215
2025-12-01 10:40:07 +08:00
Jaroslav Burian da18980ff0 change: Modify license of soc component
License of soc component is changed from Apache-2.0 to Apache-2.0 OR MIT
to be able to use it in esp-stub-lib
2025-11-28 10:32:05 +01:00
Song Ruo Jing 06970a5284 refactor(esp_hal_gpio): move some caps definitions to esp_hal_gpio 2025-11-26 15:35:27 +08:00
Song Ruo Jing 1862fdec74 refactor(gpio): split GPIO HAL into separate component
cleaned up some includes in GPIO peripheral files
2025-11-26 15:35:07 +08:00
Chen Jichang 2cb84ecf95 feat(hal): graudate the RMT hal driver into a new component 2025-11-25 14:21:01 +08:00
morris bc064a353a refactor(hal_dma): move bitscrambler from hal component
because bitscrambler can't live without DMA, it's highly binded with the
GDMA peripheral.
2025-11-21 16:10:16 +08:00
laokaiyao bab5a7a8ed refactor(i2s): refactor of the private i2s caps 2025-11-18 16:13:14 +08:00
laokaiyao e8f39b4c8d feat(hal): graudate the I2S hal driver into a new component 2025-11-18 15:47:16 +08:00
Jiang Jiang Jian 504c82ff6a Merge branch 'bugfix/update_wifi_fragment_doc' into 'master'
docs(wifi): update wifi fragment doc

Closes WIFI-7097

See merge request espressif/esp-idf!43044
2025-11-18 10:50:27 +08:00
Harshal Patil 0debe71b3d Merge branch 'feat/flash_enc_using_key_manager' into 'master'
Support Flash Encryption using Key Manager

Closes IDF-13462 and IDF-14278

See merge request espressif/esp-idf!41879
2025-11-13 07:55:15 +05:30
muhaidong 9cbd5c2804 docs(wifi): update wifi fragment doc 2025-11-12 19:15:28 +08:00
Song Ruo Jing c17644a400 feat(gpio): add IO hold support for Deep-sleep for ESP32-P4 ECO5 2025-11-11 17:03:24 +08:00
harshal.patil 0c3c284819 feat(bootloader_support): Support FE XTS-AES-256 using Key Manager for ESP32-C5 2025-11-11 12:23:27 +05:30
Song Ruo Jing 266c06354d refactor(gpio): remove some useless macros from io_mux_reg.h 2025-11-07 15:26:52 +08:00
morris 2de3be7300 feat(dma): graduate the dma driver into a single component 2025-10-19 22:06:46 +08:00
morris ab149384e1 Merge branch 'refactor/clean_soc_caps_gptimer' into 'master'
refactor(hal): graduate watch dog hal driver into a new component: esp_hal_wdt

Closes IDF-14091

See merge request espressif/esp-idf!42338
2025-10-15 17:18:20 +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
morris 56c3dc4755 feat(wdt): graduate watch dog hal driver into a new component: esp_hal_wdt 2025-10-14 11:44:32 +08:00
Song Ruo Jing 9056974051 feat(gpio): ESP32P4 ECO5 GPIO related update 2025-10-13 11:48:47 +08:00
Chen Jichang d0e24e4a81 refactor(hw_support): remove unused periph_module_t members 2025-10-09 15:27:20 +08:00
laokaiyao fec96035be refactor(i2s): replace the enum i2s_port_t with int type 2025-10-01 21:53:55 +08:00
laokaiyao 91a6387005 refactor(i2s): clean up i2s soc caps 2025-10-01 21:51:58 +08:00
morris 71cb24caab feat(timg): graduate the hal driver into a single component 2025-09-27 17:33:10 +08:00
Chen Ji Chang 9dc9d7de9f Merge branch 'refactor/remove_legacy_rmt_driver' into 'master'
remove(legacy_rmt)!: remove legacy rmt driver in IDF v6.0

Closes IDF-13175

See merge request espressif/esp-idf!40092
2025-09-17 14:07:31 +08:00
Song Ruo Jing addfa2aa01 Merge branch 'feature/esp32h21_esp32h4_ledc_support' into 'master'
feat(ledc): Add LEDC support for ESP32H21 and ESP32H4

Closes IDF-12343, IDF-12344, IDF-12920, IDF-11568, IDF-11569, IDF-12115, and IDF-13672

See merge request espressif/esp-idf!41172
2025-09-17 10:55:00 +08:00
Chen Jichang 883ead113d remove(legacy_rmt): remove legacy rmt driver in IDF v6.0 2025-09-16 15:20:10 +08:00
Song Ruo Jing 24a9cb7dde refactor(dedic_gpio): clean up dedic gpio soc caps 2025-09-16 11:18:10 +08:00
C.S.M 5ce39e8878 refactor(i2c): Make i2c hal layer independent 2025-09-15 11:26:48 +08:00
Alexey Lapshin ecc37c12d7 feat(build): enable -mtune=esp-base option for RISC-V targets
The `-mtune=esp-base` option is identical to the default tuning profile,
except that `slow_unaligned_access` is set to false.

This reduces the instruction count for built-in `memcpy` and improves
performance, since our chips can handle misaligned access with minimal
penalty (without triggering exceptions).

Example:

  void load(uint32_t *r, char* x) {
    memcpy(r, x, sizeof(uint32_t));
  }
  void store(char* x, uint32_t v) {
    memcpy(x, &v, sizeof(uint32_t));
  }

Previously generated code:

  load:
        lbu     a5,2(a1)
        lbu     a3,0(a1)
        lbu     a4,1(a1)
        sb      a5,2(a0)
        sb      a3,0(a0)
        sb      a4,1(a0)
        lbu     a5,3(a1)
        sb      a5,3(a0)
        ret
  store:
        srli    a3,a1,8
        srli    a4,a1,16
        srli    a5,a1,24
        addi    sp,sp,-16
        sb      a1,0(a0)
        sb      a3,1(a0)
        sb      a4,2(a0)
        sb      a5,3(a0)
        addi    sp,sp,16
        jr      ra

With `-mtune=esp-base`:

  load:
        lw      a5,0(a1)
        sw      a5,0(a0)
        ret
  store:
        sw      a1,0(a0)
        ret

Inlining behavior
=================

Without `-mtune=esp-base`:
  - `memcpy()` is inlined only when the compile-time size is ≤ 12 bytes.
    - Maximum cost: ~25 instructions

With `-mtune=esp-base`:
  - `memcpy()` is inlined for all compile-time constant sizes.
    - Maximum cost: ~14 instructions

As a result, some applications may see reduced code size, while others
may increase slightly. However, performance always improves because
extra `memcpy` calls are eliminated.

Performance results
===================

esp32p4 (Ethernet iperf):
  - No noticeable difference

esp32c61 (Wi-Fi iperf):
  - ~2 Mb/s increase for TCP and UDP TX (may be within measurement error)

NOTE
====

Applies only to RISC-V chips that do not have the hardware issue marked
by the SOC_CPU_MISALIGNED_ACCESS_ON_PMP_MISMATCH_ISSUE macro.
2025-08-27 12:46:41 +07:00
Alexey Lapshin 913d38ba14 fix(newlib): fix CONFIG_LIBC_OPTIMIZED_MISALIGNED_ACCESS for c2/c3/c6/h2/h21
PMP configurations for load and store addresses may
have different permissions (e.g., "R" vs. "RW").

Due to the timing alignment of internal signals, the address
permission check may be incorrectly applied during the second
part of a misaligned access transaction.

As a workaround, insert two instructions (e.g. ADDI/NOP) between
accessing to different memory regions. This spacing avoids the
false permission check caused by signal timing overlap.
2025-08-22 13:46:43 +08:00
Chen Ji Chang 7324fc6dd9 Merge branch 'refactor/use_gdma_link_in_rmt' into 'master'
refactor(rmt): use gdma link list driver to mount buffer

Closes IDFGH-15289 and IDFGH-15421

See merge request espressif/esp-idf!39350
2025-08-14 10:49:19 +08:00
Wan Lei 7d1e974f77 Merge branch 'bugfix/twai_driver_cxx_test' into 'master'
fix(twai): fixed build errors in cxx environment

Closes IDFGH-16058

See merge request espressif/esp-idf!40818
2025-08-14 09:41:23 +08:00