* [PATCH] mci: imx-esdhc-pbl: fix iMX50 prediv setting
@ 2025-08-03 5:54 Alexander Kurz
2025-08-05 5:00 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: Alexander Kurz @ 2025-08-03 5:54 UTC (permalink / raw)
To: barebox; +Cc: Alexander Kurz
The ESDHC3 instance is common between iMX50 and iMX53.
Extend the required quirk also to iMX50 fixing a problem that data could
not be written to an eMMC.
Fixes: 1713fa5bf0f9 ("mci: imx-esdhc-pbl: fix prediv setting")
Signed-off-by: Alexander Kurz <akurz@blala.de>
---
drivers/mci/imx-esdhc.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/mci/imx-esdhc.c b/drivers/mci/imx-esdhc.c
index 0ae0bb4ede..ae02d80443 100644
--- a/drivers/mci/imx-esdhc.c
+++ b/drivers/mci/imx-esdhc.c
@@ -22,6 +22,7 @@
#include <gpio.h>
#include <of_device.h>
#include <mach/imx/generic.h>
+#include <mach/imx/imx50-regs.h>
#include <mach/imx/imx53-regs.h>
#include "sdhci.h"
@@ -97,8 +98,9 @@ static void set_sysctl(struct mci_host *mci, u32 clock, bool ddr)
if (esdhc_is_layerscape(host))
sdhc_clk >>= 1;
- /* For i.MX53 eSDHCv3, SYSCTL.SDCLKFS may not be set to 0. */
- if (cpu_is_mx53() && host->sdhci.base == (void *)MX53_ESDHC3_BASE_ADDR)
+ /* For i.MX50 and i.MX53 eSDHCv3, SYSCTL.SDCLKFS may not be set to 0. */
+ if ((cpu_is_mx50() && host->sdhci.base == (void *)MX50_ESDHC3_BASE_ADDR)
+ || (cpu_is_mx53() && host->sdhci.base == (void *)MX53_ESDHC3_BASE_ADDR))
pre_div = 2;
else
pre_div = 1;
--
2.39.5
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] mci: imx-esdhc-pbl: fix iMX50 prediv setting
2025-08-03 5:54 [PATCH] mci: imx-esdhc-pbl: fix iMX50 prediv setting Alexander Kurz
@ 2025-08-05 5:00 ` Sascha Hauer
0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2025-08-05 5:00 UTC (permalink / raw)
To: barebox, Alexander Kurz
On Sun, 03 Aug 2025 05:54:49 +0000, Alexander Kurz wrote:
> The ESDHC3 instance is common between iMX50 and iMX53.
> Extend the required quirk also to iMX50 fixing a problem that data could
> not be written to an eMMC.
>
>
Applied, thanks!
[1/1] mci: imx-esdhc-pbl: fix iMX50 prediv setting
https://git.pengutronix.de/cgit/barebox/commit/?id=08c388d2aa11 (link may not be stable)
Best regards,
--
Sascha Hauer <s.hauer@pengutronix.de>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-08-05 5:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-08-03 5:54 [PATCH] mci: imx-esdhc-pbl: fix iMX50 prediv setting Alexander Kurz
2025-08-05 5:00 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox