Skip to content

Commit 33d1792

Browse files
talih0carlescufi
authored andcommitted
drivers: spi: Add xmc4xxx driver
Adds spi driver for xmc4xxx SoCs. Signed-off-by: Andriy Gelman <[email protected]>
1 parent ca9ac5a commit 33d1792

File tree

9 files changed

+553
-0
lines changed

9 files changed

+553
-0
lines changed

boards/arm/xmc45_relax_kit/doc/index.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ The Relax Kit development board configuration supports the following hardware fe
4343
+-----------+------------+-----------------------+
4444
| UART | on-chip | serial port |
4545
+-----------+------------+-----------------------+
46+
| SPI | on-chip | spi |
47+
+-----------+------------+-----------------------+
4648

4749
More details about the supported peripherals are available in `XMC4500 TRM`_
4850
Other hardware features are not currently supported by the Zephyr kernel.

drivers/spi/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ zephyr_library_sources_ifdef(CONFIG_SPI_MCHP_QSPI spi_mchp_mss_qspi.c)
3434
zephyr_library_sources_ifdef(CONFIG_SPI_PL022 spi_pl022.c)
3535
zephyr_library_sources_ifdef(CONFIG_SPI_ANDES_ATCSPI200 spi_andes_atcspi200.c)
3636
zephyr_library_sources_ifdef(CONFIG_NXP_S32_SPI spi_nxp_s32.c)
37+
zephyr_library_sources_ifdef(CONFIG_SPI_XMC4XXX spi_xmc4xxx.c)
3738

3839
zephyr_library_sources_ifdef(CONFIG_SPI_ASYNC spi_signal.c)
3940
zephyr_library_sources_ifdef(CONFIG_USERSPACE spi_handlers.c)

drivers/spi/Kconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,4 +107,6 @@ source "drivers/spi/Kconfig.andes_atcspi200"
107107

108108
source "drivers/spi/Kconfig.nxp_s32"
109109

110+
source "drivers/spi/Kconfig.xmc4xxx"
111+
110112
endif # SPI

drivers/spi/Kconfig.xmc4xxx

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Copyright (c) 2022 Schlumberger
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
menuconfig SPI_XMC4XXX
5+
bool "XMC4XX SPI driver"
6+
default y
7+
depends on DT_HAS_INFINEON_XMC4XXX_SPI_ENABLED
8+
select GPIO
9+
help
10+
Enable XMC4XXX SPI driver.
11+
12+
13+
if SPI_XMC4XXX
14+
15+
config SPI_XMC4XXX_INTERRUPT
16+
bool "XMC4XXX SPI interrupt mode"
17+
help
18+
Enables interrupt support for XMC4XXX SPI driver.
19+
20+
endif # SPI_XMC4XXX

0 commit comments

Comments
 (0)