kernel: add support for DesignWare SPI MMIO controller

Add kernel packages for DesignWare SPI core and MMIO controllers.
This is needed for the RP1 SoC found on RPi 5 devices.

Tested with a Microchip ENC28J60 Ethernet controller on a RPi 5.

Signed-off-by: Albrecht Lohofener <albrechtloh@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/19049
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
This commit is contained in:
Albrecht Lohofener 2025-06-08 09:23:42 +02:00 committed by Álvaro Fernández Rojas
parent eab2b27699
commit 82d20a0fbd
3 changed files with 48 additions and 0 deletions

View file

@ -73,3 +73,41 @@ define KernelPackage/spi-dev/description
endef
$(eval $(call KernelPackage,spi-dev))
define KernelPackage/spi-dw
SUBMENU:=$(SPI_MENU)
TITLE:=DesignWare SPI controller driver (core)
KCONFIG:=\
CONFIG_SPI=y \
CONFIG_SPI_DESIGNWARE \
CONFIG_SPI_DYNAMIC=y \
CONFIG_SPI_MASTER=y
FILES:=\
$(LINUX_DIR)/drivers/spi/spi-dw.ko
AUTOLOAD:=$(call AutoProbe,spi-dw)
endef
define KernelPackage/spi-dw/description
This package contains the DesignWare SPI core driver.
endef
$(eval $(call KernelPackage,spi-dw))
define KernelPackage/spi-dw-mmio
SUBMENU:=$(SPI_MENU)
TITLE:=DesignWare SPI controller driver (MMIO)
DEPENDS:=+kmod-spi-dw
KCONFIG:=\
CONFIG_SPI_DW_MMIO
FILES:=\
$(LINUX_DIR)/drivers/spi/spi-dw-mmio.ko
AUTOLOAD:=$(call AutoProbe,spi-dw-mmio)
endef
define KernelPackage/spi-dw-mmio/description
This package contains the DesignWare SPI MMIO driver.
endef
$(eval $(call KernelPackage,spi-dw-mmio))

View file

@ -6329,6 +6329,11 @@ CONFIG_SND_X86=y
# CONFIG_SPI_CH341 is not set
# CONFIG_SPI_DEBUG is not set
# CONFIG_SPI_DESIGNWARE is not set
# CONFIG_SPI_DW_BT1 is not set
# CONFIG_SPI_DW_BT1_DIRMAP is not set
# CONFIG_SPI_DW_DMA is not set
# CONFIG_SPI_DW_MMIO is not set
# CONFIG_SPI_DW_PCI is not set
# CONFIG_SPI_FSL_DSPI is not set
# CONFIG_SPI_FSL_ESPI is not set
# CONFIG_SPI_FSL_SPI is not set

View file

@ -6217,6 +6217,11 @@ CONFIG_SND_X86=y
# CONFIG_SPI_CADENCE_XSPI is not set
# CONFIG_SPI_DEBUG is not set
# CONFIG_SPI_DESIGNWARE is not set
# CONFIG_SPI_DW_BT1 is not set
# CONFIG_SPI_DW_BT1_DIRMAP is not set
# CONFIG_SPI_DW_DMA is not set
# CONFIG_SPI_DW_MMIO is not set
# CONFIG_SPI_DW_PCI is not set
# CONFIG_SPI_FSL_DSPI is not set
# CONFIG_SPI_FSL_ESPI is not set
# CONFIG_SPI_FSL_SPI is not set