Commit Graph

52 Commits

Author SHA1 Message Date
Adam Múdry
a89ca4caf6 fix(sdmmc): Validate DMA buffer address range
Closes https://github.com/espressif/esp-idf/issues/18714
2026-07-28 15:36:44 +02:00
Adam Múdry
ba4503a9b5 fix(sdmmc): Add a better handling of devices accessing PSRAM through DMA
Closes https://github.com/espressif/esp-idf/issues/18412
2026-07-02 11:39:20 +02:00
armando
9a87ff0017 fix(sdmmc): added mutex for adding a slot 2026-05-21 09:09:28 +08:00
armando
f408e1a8bc feat(sdmmc): add esp32s31 support
Enable SDMMC host support on ESP32-S31 across HAL, SOC caps, tests, examples, and documentation.
2026-05-21 09:09:28 +08:00
armando
09ff879535 fix(sdmmc): clean up slot state on removal paths
Keep slot registration state and interrupts consistent when add-slot setup fails or the final registered slot is removed.
2026-05-21 09:09:14 +08:00
armando
8499ad6ab0 feat(hal):graudate the sdmmc/sdio_slave hal driver into a new component 2026-02-02 09:47:54 +08:00
morris
0469db2f83 refactor(rcc): unify the usage of clock control macros for peripherals
- Removed conditional definitions for various RCC_ATOMIC macros across
multiple files, replacing them with a unified PERIPH_RCC_ATOMIC() macro.
- Updated instances where specific RCC_ATOMIC macros were used to ensure
consistent usage of PERIPH_RCC_ATOMIC().
- Deleted unused uart_share_hw_ctrl.h file as its functionality is now
integrated into the new structure.
2026-01-23 18:28:13 +08:00
Song Ruo Jing
62511d61e9 refactor(clk): split clock HAL into separate component 2026-01-13 15:50:20 +08:00
wanckl
6449181ce0 feat(driver_spi): split spi hal component 2025-12-11 15:00:18 +08:00
C.S.M
d5054072eb ci(header_check): Add check for public header should not include freertos 2025-11-28 19:15:17 +08:00
armando
70acf169e0 fix(sd): use heap_caps_alloc to maintain desc alignment 2025-09-23 01:15:33 +00:00
Marius Vikhammer
484d2c5c2f fix(system): fixed issues with unused variable warnings when compiling with NDEBUG 2025-09-19 15:42:07 +08:00
armando
28786d0732 feat(sdmmc): supported UHS-I SDR104 (200 MHz) on ESP32-P4 rev3 2025-09-16 12:03:03 +08:00
Darian Leung
5454499877 refactor: Use enum values for gpio pull up/down fields
Ensure that enum values are used When assigning `pull_up_en` and `pull_down_en`
fields of `gpio_config_t`. Helps avoid `invalid conversion` errors when
building those code snippets in C++.
2025-08-07 11:45:11 +08:00
armando
df7b39da34 fix(sdmmc): fixed dma desc on psram issue on s3 2025-07-07 10:24:22 +08:00
wuzhenghui
65b7e70564 feat(driver): support acquire/release clock source dependency for all drivers 2025-05-27 21:21:38 +08:00
Chen Jichang
a21f7c78f9 fix(sdmmc): only call esp_pm APIs when CONFIG_PM_ENABLE is enabled 2025-05-22 17:27:18 +08:00
armando
616dd97398 fix(sd): fixed slot0 requires all pins to be set when using 1bit iomux mode on p4 2025-05-16 11:10:58 +08:00
armando
8f6a2370d2 refactor(sd): updated sd host api to make 0 value as no change to configurations
use value 0 for `sd_host_slot_cfg_t` members, means no change to previous configurations,
instead of using `override/valid` flag
2025-05-15 15:16:38 +08:00
armando
77ae2808b0 refactor(sd): port legacy sd driver with NG driver 2025-05-15 10:57:45 +08:00
armando
402bf0ce58 feat(sd): sd host driver layer driver NG 2025-05-15 10:57:33 +08:00
armando
9af1f75af8 fix(sdmmc): fixed sdmmc pin drive regression issue on esp32 2025-05-07 10:52:20 +08:00
Ivan Grokhotkov
335027b731 fix(sdmmc): move DMA descriptor refilling into the ISR
Previously, as DMA descriptors were processed, the task performing
SDMMC transfer would get woken up and would refill the descriptors.
This design didn't work correctly when higher priority tasks occupied
the CPU for too long, resulting in SDMMC transfer timing out.

This change moves DMA descriptor refilling into SDMMC ISR. Now the
"DMA done" interrupt is delivered back to task context only when
the entire transfer is completed.

Closes https://github.com/espressif/esp-idf/issues/13934
2025-03-11 10:51:06 +08:00
Song Ruo Jing
53d8b70e8b fix(gpio): fix IO output enable control
oen_sel and oen_inv_sel fields from func_out_sel_cfg register
2025-02-20 19:49:28 +08:00
Wan Lei
76133bc373 Merge branch 'fix/remove_gpio_hal_iomux_func_sel' into 'master'
fix(driver_gpio): remove gpio_hal_iomux_func_sel

See merge request espressif/esp-idf!33928
2025-02-20 18:52:35 +08:00
wanckl
222b1ddbab fix(driver_gpio): remove gpio_hal_iomux_func_sel 2025-02-19 17:17:51 +08:00
Ivan Grokhotkov
6f49122b74 fix(sdmmc): fix missed deinitialization of CD and WP pins in f8f40ad
Related to https://github.com/espressif/esp-idf/issues/15330
2025-02-17 16:21:30 +01:00
Ivan Grokhotkov
f8f40ad94f fix(sdmmc): fix reset of pins above slot width
Closes https://github.com/espressif/esp-idf/issues/15328
2025-02-04 12:01:04 +01:00
Adam Múdry
30196f9430 fix(sdmmc): SDMMC concurrency change active slot only after the slot is initialized
Fixes counting of initialized slots
2025-01-27 03:41:01 +01:00
Armando
e8ad9b05aa refactor(sd): replace esp_dma_ with heap_caps_ 2025-01-20 10:54:59 +08:00
Armando
7c384facd7 change(sdmmc): simplify cmd11 enable code 2024-11-15 15:22:02 +08:00
Armando
9e3b7e4558 feat(sdmmc): supported UHS-I SDR50 (100Mhz) and DDR50 mode 2024-11-13 09:47:45 +08:00
Ivan Grokhotkov
f5f46ab74c change(sdmmc): adapt host state machine for CMD11, commit reg/struct files 2024-11-12 15:39:42 +08:00
Ivan Grokhotkov
98f1dd969a change(sdmmc): disable the logic related to D3 line, it needs to be connected for CMD11 to work 2024-11-12 15:39:41 +08:00
Ivan Grokhotkov
2b29de78bb change(sdmmc): allow speciying pins for IOMUX slots as well 2024-11-12 15:39:41 +08:00
Ivan Grokhotkov
3107f0abe7 change(sdmmc): make sdmmc_host_clock_update_command compatible with CMD11 2024-11-12 15:39:41 +08:00
wuzhenghui
13e42707a0 feat(esp_hw_support): add clk tree source gate management api 2024-09-11 10:53:01 +08:00
Armando
a1da4f8a01 feat(sdmmc): sdmmc full ll layer 2024-09-03 17:03:42 +08:00
Adam Múdry
347800bcda Merge branch 'fix/sdmmc_host_init_slot_possible_bad_shift_op' into 'master'
fix(sdmmc): Fix possible bad bit shift operation

Closes IDF-10759

See merge request espressif/esp-idf!32885
2024-08-30 23:55:14 +08:00
Adam Múdry
24c1f084d0 fix(sdmmc): Fix possible bad bit shift operation and check if GPIO pins are valid 2024-08-30 15:01:10 +02:00
Adam Múdry
b263b9dff9 fix(sdmmc): Fix SDMMC slot switch timing related issue on ESP32-P4 2024-08-20 19:17:08 +08:00
Ivan Grokhotkov
8a9d3076d7 fix(sdmmc): don't disable SDIO interrupts when switching slots 2024-08-12 14:18:29 +02:00
Adam Múdry
014dddad1f feat(sdmmc): Concurrent use of SDMMC peripheral
Host and device (card, etc.) initialization is not thread-safe.
After initialization transactions are serialized and guarded by mutex.
Changed `SDMMC_HOST_DEFAULT()` default deinit function to `sdmmc_host_deinit_slot`
which has a slot number as argument.
2024-08-06 10:34:13 +02:00
Adam Múdry
caa4f7fd20 refactor(sdmmc): Allow sdmmc_host_init to be called multiple times
Along with slight refactor for sdmmc_host.c
2024-07-23 12:35:19 +02:00
Ivan Grokhotkov
b08ddfb25b fix(sdmmc): don't fail in clock update commands when no card detected
Clock update commands don't actually require the card to be present,
so it's not necessary to fail at this stage.
2024-04-17 12:49:22 +02:00
Ivan Grokhotkov
49b4bc175e feat(sdmmc): add support for PSRAM DMA on ESP32-P4 2024-04-12 12:56:18 +02:00
gaoxu
40f38bea6f feat(dma): refactor dma calloc function 2024-04-02 14:30:14 +08:00
morris
4c2569e2fc change(sdmmc): update ldo acquire driver to new API 2024-03-25 21:19:12 +08:00
Armando
ec44556a07 feat(sd): added power control driver and implementation layer with ldo 2024-03-25 11:32:56 +08:00
Xiao Xufeng
216284b767 feat(sdio): add sdio over sdmmc support for esp32p4 2024-01-14 01:05:00 +08:00