summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/meson-mx-sdhc-clkc.c
diff options
context:
space:
mode:
authorMartin Blumenstingl <martin.blumenstingl@googlemail.com>2020-05-18 00:29:06 +0200
committerUlf Hansson <ulf.hansson@linaro.org>2020-05-28 11:22:15 +0200
commitc70805dca13970d18a4a9960bdc1d2f10de59057 (patch)
treedb2c87d9eb0c99995b11d0c5f473f58829d7535d /drivers/mmc/host/meson-mx-sdhc-clkc.c
parent86b59671deba640d77335ef75f7c3ca388372860 (diff)
mmc: meson-mx-sdhc: Fix manual RX FIFO flushing
For Meson8 and Meson8b SoCs the vendor driver follows the following pattern: - for eMMC and SD cards in .set_pdma it sets: pdma->rxfifo_manual_flush = 1; - for SDIO cards in .set_pdma it sets: pdma->rxfifo_manual_flush = 0; - before syncing the DMA read buffer is sets: pdma->rxfifo_manual_flush |= 0x02; Set the second bit of MESON_SDHC_PDMA_RXFIFO_MANUAL_FLUSH without clearing the first bit before syncing the DMA read buffer. This fixes a problem where Meson8 and Meson8b SoCs would read random garbage from SD cards. It is not clear why it worked for eMMC cards. This manifested in the following errors when plugging in an SD card: unrecognised SCR structure version <random number> Cc: Thomas Graichen <thomas.graichen@gmail.com> Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Link: https://lore.kernel.org/r/20200517222907.1277787-1-martin.blumenstingl@googlemail.com Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/host/meson-mx-sdhc-clkc.c')
0 files changed, 0 insertions, 0 deletions