Skip to contentSkip to conversation

MMC: add NPCM SDHCI driver support

PATCH In review Tomer Maimon 1 participant 4 messages Dec 21, 2022 – Feb 7, 2023

Subsystems (4)
lore
Share & tools
lore

Tomer Maimon

author maintainer
#0 lore raw

cover MMC: add NPCM SDHCI driver support

This patch set adds SDHCI support for the Nuvoton NPCM Baseboard Management Controller (BMC).

The NPCM SDHCI driver tested on NPCM750 and NPCM845 EVB.

Tomer Maimon (2):
dt-bindings: mmc: npcm,sdhci: Document NPCM SDHCI controller
mmc: sdhci-npcm: Add NPCM SDHCI driver

 .../devicetree/bindings/mmc/npcm,sdhci.yaml   | 45 ++++++++++
 drivers/mmc/host/Kconfig                      |  8 ++
 drivers/mmc/host/Makefile                     |  1 +
 drivers/mmc/host/sdhci-npcm.c                 | 84 +++++++++++++++++++
 4 files changed, 138 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mmc/npcm,sdhci.yaml
 create mode 100644 drivers/mmc/host/sdhci-npcm.c
Signature · 1 line
2.33.0
author maintainer
#1 lore raw

PATCH 1/2 dt-bindings: mmc: npcm,sdhci: Document NPCM SDHCI controller

Add binding for Nuvoton NPCM SDHCI controller.

---
 .../devicetree/bindings/mmc/npcm,sdhci.yaml   | 45 +++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mmc/npcm,sdhci.yaml
Documentation/devicetree/bindings/mmc/npcm,sdhci.yaml new file +45 -0
new file mode 100644
index 000000000000..196fdbfa16ed
@@ -0,0 +1,45 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mmc/npcm,sdhci.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: NPCM SDHCI Controller
+
+maintainers:
+  - Tomer Maimon <[email protected]>
+
+allOf:
+  - $ref: mmc-controller.yaml#
+
+properties:
+  compatible:
+    enum:
+      - nuvoton,npcm750-sdhci
+      - nuvoton,npcm845-sdhci
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  clocks:
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - interrupts
+  - clocks
+
+unevaluatedProperties: false
+
+examples:
+  - |
+    mmc@f0840000 {
+      compatible = "nuvoton,npcm750-sdhci";
+      reg = <0xf0840000 0x200>;
+      interrupts = <0 27 4>;
+      clocks = <&clk 4>;
+    };
Signature · 1 line
2.33.0
author maintainer
#2 lore raw

PATCH 2/2 mmc: sdhci-npcm: Add NPCM SDHCI driver

In reply to Tomer Maimon

Add Nuvoton NPCM BMC sdhci-pltfm controller driver.

---
 drivers/mmc/host/Kconfig      |  8 ++++
 drivers/mmc/host/Makefile     |  1 +
 drivers/mmc/host/sdhci-npcm.c | 84 +++++++++++++++++++++++++++++++++++
 3 files changed, 93 insertions(+)
 create mode 100644 drivers/mmc/host/sdhci-npcm.c
drivers/mmc/host/Kconfig +8 -0
index 97a6ea4a3ac7..ad9432fdca27 100644
@@ -414,6 +414,14 @@ config MMC_SDHCI_MILBEAUT
 
 	  If unsure, say N.
 
+config MMC_SDHCI_NPCM
+	tristate "Secure Digital Host Controller Interface support for NPCM"
+	depends on ARCH_NPCM || COMPILE_TEST
+	depends on MMC_SDHCI_PLTFM
+	help
+	  This provides support for the SD/eMMC controller found in
+	  NPCM BMC family SoCs.
+
 config MMC_SDHCI_IPROC
 	tristate "SDHCI support for the BCM2835 & iProc SD/MMC Controller"
 	depends on ARCH_BCM2835 || ARCH_BCM_IPROC || ARCH_BRCMSTB || COMPILE_TEST
drivers/mmc/host/Makefile +1 -0
index 4e4ceb32c4b4..a101f87a5f19 100644
@@ -97,6 +97,7 @@ obj-$(CONFIG_MMC_SDHCI_MICROCHIP_PIC32)	+= sdhci-pic32.o
 obj-$(CONFIG_MMC_SDHCI_BRCMSTB)		+= sdhci-brcmstb.o
 obj-$(CONFIG_MMC_SDHCI_OMAP)		+= sdhci-omap.o
 obj-$(CONFIG_MMC_SDHCI_SPRD)		+= sdhci-sprd.o
+obj-$(CONFIG_MMC_SDHCI_NPCM)		+= sdhci-npcm.o
 obj-$(CONFIG_MMC_CQHCI)			+= cqhci.o
 cqhci-y					+= cqhci-core.o
 cqhci-$(CONFIG_MMC_CRYPTO)		+= cqhci-crypto.o
drivers/mmc/host/sdhci-npcm.c new file +84 -0

84 lines not on this page · raw message

Signature · 1 line
2.33.0
author maintainer
#3 lore raw
In reply to Tomer Maimon

Hi Joel,

Kind reminder regards NPCM eMMC driver.

Thanks,

Tomer

Quoted 21 lines · Tomer Maimon

This patch set adds SDHCI support for the Nuvoton NPCM Baseboard Management Controller (BMC).

The NPCM SDHCI driver tested on NPCM750 and NPCM845 EVB.

Tomer Maimon (2):
dt-bindings: mmc: npcm,sdhci: Document NPCM SDHCI controller
mmc: sdhci-npcm: Add NPCM SDHCI driver

 .../devicetree/bindings/mmc/npcm,sdhci.yaml   | 45 ++++++++++
 drivers/mmc/host/Kconfig                      |  8 ++
 drivers/mmc/host/Makefile                     |  1 +
 drivers/mmc/host/sdhci-npcm.c                 | 84 +++++++++++++++++++
 4 files changed, 138 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mmc/npcm,sdhci.yaml
 create mode 100644 drivers/mmc/host/sdhci-npcm.c

--
2.33.0