Skip to content
Snippets Groups Projects
Commit 66cc6dd6 authored by Rosen Penev's avatar Rosen Penev Committed by John Crispin
Browse files

ramips: mmc: Add back some non-mt7621 code that staging removed


This reverts commit 8a570921.

This seems to have been accidentally reverted. This fixes mt7620 and
mt7628.

Signed-off-by: default avatarRosen Penev <rosenp@gmail.com>
Acked-by: default avatarDaniel Golle <daniel@makrotopia.org>
parent 8110bf18
No related branches found
No related tags found
No related merge requests found
...@@ -2209,7 +2209,23 @@ static int msdc_drv_probe(struct platform_device *pdev) ...@@ -2209,7 +2209,23 @@ static int msdc_drv_probe(struct platform_device *pdev)
// Set the pins for sdxc to sdxc mode // Set the pins for sdxc to sdxc mode
//FIXME: this should be done by pinctl and not by the sd driver //FIXME: this should be done by pinctl and not by the sd driver
reg = sdr_read32((void __iomem *)(RALINK_SYSCTL_BASE + 0x60)) & ~(0x3 << 18); if (ralink_soc == MT762X_SOC_MT7620A ||
ralink_soc == MT762X_SOC_MT7621AT) {
reg = sdr_read32((void __iomem *)(RALINK_SYSCTL_BASE +
0x60)) & ~(0x3 << 18);
if (ralink_soc == MT762X_SOC_MT7620A)
reg |= 0x1 << 18;
} else {
reg = sdr_read32((void __iomem *)(RALINK_SYSCTL_BASE + 0x3c));
reg |= 0x1e << 16;
sdr_write32((void __iomem *)(RALINK_SYSCTL_BASE + 0x3c), reg);
reg = sdr_read32((void __iomem *)(RALINK_SYSCTL_BASE +
0x60)) & ~(0x3 << 10);
#if defined(CONFIG_MTK_MMC_EMMC_8BIT)
reg |= 0x3 << 26 | 0x3 << 28 | 0x3 << 30;
#endif
}
sdr_write32((void __iomem *)(RALINK_SYSCTL_BASE + 0x60), reg); sdr_write32((void __iomem *)(RALINK_SYSCTL_BASE + 0x60), reg);
hw = &msdc0_hw; hw = &msdc0_hw;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment