
Hi, Sean
вт, 2 апр. 2024 г. в 18:39, Sean Anderson sean.anderson@seco.com:
On 3/30/24 13:59, Maksim Kiselev wrote:
Add support for DesignWare SDHCI host controller on Alibaba TH1520 SoC
Signed-off-by: Maksim Kiselev bigunclemax@gmail.com
drivers/mmc/Kconfig | 12 + drivers/mmc/Makefile | 1 + drivers/mmc/snps_sdhci.c | 464 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 477 insertions(+) create mode 100644 drivers/mmc/snps_sdhci.c
diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig index cef05790dd..6936fa0928 100644 --- a/drivers/mmc/Kconfig +++ b/drivers/mmc/Kconfig @@ -671,6 +671,18 @@ config MMC_SDHCI_S5P
If unsure, say N.
+config MMC_SDHCI_SNPS
- bool "Synopsys DesignWare SDHCI controller"
- depends on MMC_SDHCI
- depends on DM_MMC
- help
- Support for DesignWare SDHCI host controller on Alibaba TH1520 SoC.
- This is a highly configurable and programmable, high performance
- Mobile Storage Host Controller (MSHC) with AXI as the bus interface
- for data transfer.
- If unsure, say N.
Why not use MMC_DW?
That driver looks completely different. As I notice in the cover letter, the MMC_SDHCI_ROCKCHIP driver is closer to TH1520 driver. https://lore.kernel.org/u-boot/20240330175948.80931-1-bigunclemax@gmail.com/
Their IP blocks look very similar. Moreover, on Linux, Rockchip SDHCI controllers (ex. rockchip,rk3588-dwcmshc) and the TH1520 controller live in the same driver - sdhci-of-dwcmshc.c
We could do the same for U-boot. It will require to get rid of Rockchip specific defines that come from asm/arch-rockchip/hardware.h. And maybe rename the rockchip_sdhci.c driver to sdhci-of-dwcmshc.c.
That's why I mark this series as RFC. So I'm willing to discuss any option.
--Sean
[Embedded World 2024, SECO SpA]https://www.messe-ticket.de/Nuernberg/embeddedworld2024/Register/ew24517689
Cheers, Maksim