summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukasz Majewski <lukma@denx.de>2019-09-05 09:54:57 +0200
committerStefano Babic <sbabic@denx.de>2019-10-08 16:36:36 +0200
commitc2050e10e11b7226f01aa18d49b9d4a2322723ca (patch)
treea0c841381724f46a4e0d0870667e30304439327c
parent3c50e0156644bf3223db11a57e23cc38de88af3b (diff)
spi: fix: Call mxs_reset_block() during DM/DTS probe
Without this change the DM/DTS version of mxs_spi driver doesn't reset the SPI IP block in probe. As a result this driver (when used solely on U-Boot proper) relies on reset performed by mxs spi driver in SPL. In the use case where eMMC is used in SPL as a boot primary device, the mxs_reset_block() is not called at all and DM/DTS aware SPI driver in U-Boot proper is malfunctioning. Signed-off-by: Lukasz Majewski <lukma@denx.de>
-rw-r--r--drivers/spi/mxs_spi.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/spi/mxs_spi.c b/drivers/spi/mxs_spi.c
index b1cc83aab1..d475830f17 100644
--- a/drivers/spi/mxs_spi.c
+++ b/drivers/spi/mxs_spi.c
@@ -436,6 +436,8 @@ static int mxs_spi_probe(struct udevice *bus)
priv->dma_channel = plat->dma_id;
priv->clk_id = plat->clk_id;
+ mxs_reset_block(&priv->regs->hw_ssp_ctrl0_reg);
+
ret = mxs_dma_init_channel(priv->dma_channel);
if (ret) {
printf("%s: DMA init channel error %d\n", __func__, ret);