File tree Expand file tree Collapse file tree 9 files changed +1571
-7
lines changed
Expand file tree Collapse file tree 9 files changed +1571
-7
lines changed Original file line number Diff line number Diff line change @@ -14,4 +14,5 @@ zephyr_library_sources_ifdef(CONFIG_CDNS_SDHC sdhc_cdns_ll.c sdhc_cdns.c)
1414zephyr_library_sources_ifdef (CONFIG_SDHC_ESP32 sdhc_esp32.c )
1515zephyr_library_sources_ifdef (CONFIG_SDHC_RENESAS_RA sdhc_renesas_ra.c )
1616zephyr_library_sources_ifdef (CONFIG_SDHC_MAX32 sdhc_max32.c )
17+ zephyr_library_sources_ifdef (CONFIG_SDHC_ALIF sdhc_alif.c )
1718endif ()
Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ source "drivers/sdhc/Kconfig.sdhc_cdns"
1919source "drivers/sdhc/Kconfig.esp32"
2020source "drivers/sdhc/Kconfig.renesas_ra"
2121source "drivers/sdhc/Kconfig.max32"
22+ source "drivers/sdhc/Kconfig.alif"
2223
2324config SDHC_INIT_PRIORITY
2425 int "SDHC driver init priority"
Original file line number Diff line number Diff line change 1+ # Copyright (c) 2024 Alif Semiconductor
2+ # SPDX-License-Identifier: Apache-2.0
3+
4+ config SDHC_ALIF
5+ bool "Alif SDHC driver"
6+ default y
7+ depends on DT_HAS_ALIF_SDHC_ENABLED
8+ select SDHC_SUPPORTS_NATIVE_MODE
9+ select EVENTS
10+ help
11+ Enable Alif SDHC driver.
12+
13+ if SDHC_ALIF
14+
15+ config SDHC_BUFFER_ALIGNMENT
16+ int "SDHC buffer alignment"
17+ default 512
18+
19+ config SDHC_DESCRIPTOR_SECTION
20+ string
21+ default ".alif.ns"
22+ help
23+ Linker section for SDHC driver data including DMA descriptors.
24+ On Alif SoCs this is overridden to a non-secure region by the
25+ SoC Kconfig defconfig.
26+
27+ config SDHC_ALIF_SDMA
28+ bool "Use SDMA mode"
29+ help
30+ Use Single-operation DMA (SDMA) for data transfers. SDMA uses
31+ the SDMA System Address register and requires handling DMA
32+ boundary interrupts for transfers crossing 4 KB pages.
33+
34+ config SDHC_ALIF_ADMA
35+ bool "Use ADMA2 mode"
36+ default y
37+ depends on !SDHC_ALIF_SDMA
38+ help
39+ Use Advanced DMA 2 (ADMA2) for data transfers. ADMA2 uses a
40+ descriptor table that allows scatter-gather transfers without
41+ boundary interrupt handling. This is the recommended DMA mode.
42+
43+ config SDHC_ALIF_ADMA_MAX_DESC
44+ int "SDHC ALIF ADMA Maximum Descriptor count"
45+ depends on SDHC_ALIF_ADMA
46+ default 32
47+ help
48+ SDHC ALIF ADMA Maximum Descriptor count.
49+
50+ endif # SDHC_ALIF
You can’t perform that action at this time.
0 commit comments