Commit 25a98edd authored by Yoshihiro Shimoda's avatar Yoshihiro Shimoda Committed by Ulf Hansson
Browse files

mmc: renesas_sdhi_internal_dmac: Cannot clear the RX_IN_USE in abort



This patch is fixes an issue that the SDHI_INTERNAL_DMAC_RX_IN_USE
flag cannot be cleared because tmio_mmc_core sets the host->data
to NULL before the tmio_mmc_core calls tmio_mmc_abort_dma().

So, this patch clears the SDHI_INTERNAL_DMAC_RX_IN_USE in
the renesas_sdhi_internal_dmac_abort_dma() anyway. This doesn't
cause any side effects.

Fixes: 0cbc94da ("mmc: renesas_sdhi_internal_dmac: limit DMA RX for old SoCs")
Cc: <stable@vger.kernel.org> # v4.17+
Signed-off-by: default avatarYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Reviewed-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: default avatarSimon Horman <horms+renesas@verge.net.au>
Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
parent fe6e0494
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -139,7 +139,6 @@ renesas_sdhi_internal_dmac_abort_dma(struct tmio_mmc_host *host) {
	renesas_sdhi_internal_dmac_dm_write(host, DM_CM_RST,
					    RST_RESERVED_BITS | val);

	if (host->data && host->data->flags & MMC_DATA_READ)
	clear_bit(SDHI_INTERNAL_DMAC_RX_IN_USE, &global_flags);

	renesas_sdhi_internal_dmac_enable_dma(host, true);