Skip to content

Commit d08dfb7

Browse files
AaronDotKexyBiscuit
authored andcommitted
UPSTREAM: mmc: loongson2: Add Loongson-2K SD/SDIO controller driver
The MMC controllers on the Loongson-2K series CPUs are similar, except for the interface characteristics and the use of DMA controllers. This patch describes the MMC controllers on the Loongson-2K0500/2K1000, with the distinguishing feature being the use of an externally shared APBDMA engine. Signed-off-by: Binbin Zhou <[email protected]> Reviewed-by: Huacai Chen <[email protected]> Link: https://lore.kernel.org/r/c0a9f0c0279d8e09165c6e2d694b0c35f7fc7e31.1750765495.git.zhoubinbin@loongson.cn Signed-off-by: Ulf Hansson <[email protected]> (cherry picked from commit 2115772) Signed-off-by: Kexy Biscuit <[email protected]>
1 parent b5e4e8b commit d08dfb7

File tree

4 files changed

+813
-0
lines changed

4 files changed

+813
-0
lines changed

MAINTAINERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14185,6 +14185,7 @@ M: Binbin Zhou <[email protected]>
1418514185
1418614186
S: Maintained
1418714187
F: Documentation/devicetree/bindings/mmc/loongson,ls2k0500-mmc.yaml
14188+
F: drivers/mmc/host/loongson2-mmc.c
1418814189

1418914190
LOONGSON-2 SOC SERIES PM DRIVER
1419014191
M: Yinbo Zhu <[email protected]>

drivers/mmc/host/Kconfig

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1111,6 +1111,19 @@ config MMC_OWL
11111111
This selects support for the SD/MMC Host Controller on
11121112
Actions Semi Owl SoCs.
11131113

1114+
config MMC_LOONGSON2
1115+
tristate "Loongson-2K SD/SDIO/eMMC Host Interface support"
1116+
depends on LOONGARCH || COMPILE_TEST
1117+
depends on HAS_DMA
1118+
help
1119+
This selects support for the SD/SDIO/eMMC Host Controller on
1120+
Loongson-2K series CPUs.
1121+
1122+
To compile this driver as a module, choose M here: the
1123+
module will be called mmc_loongson2.
1124+
1125+
If unsure, say N.
1126+
11141127
config MMC_SDHCI_EXTERNAL_DMA
11151128
bool
11161129

drivers/mmc/host/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ obj-$(CONFIG_MMC_USDHI6ROL0) += usdhi6rol0.o
7272
obj-$(CONFIG_MMC_TOSHIBA_PCI) += toshsd.o
7373
obj-$(CONFIG_MMC_BCM2835) += bcm2835.o
7474
obj-$(CONFIG_MMC_OWL) += owl-mmc.o
75+
obj-$(CONFIG_MMC_LOONGSON2) += loongson2-mmc.o
7576

7677
obj-$(CONFIG_MMC_REALTEK_PCI) += rtsx_pci_sdmmc.o
7778
obj-$(CONFIG_MMC_REALTEK_USB) += rtsx_usb_sdmmc.o

0 commit comments

Comments
 (0)