Commit 55f24c27 authored by Kunihiko Hayashi's avatar Kunihiko Hayashi Committed by Vinod Koul
Browse files

dmaengine: uniphier-xdmac: Use readl_poll_timeout_atomic() in atomic state



The function uniphier_xdmac_chan_stop() is only called in atomic state.
Should use readl_poll_timeout_atomic() there instead of
readl_poll_timeout().

Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Fixes: 667b9251 ("dmaengine: uniphier-xdmac: Add UniPhier external DMA controller driver")
Signed-off-by: default avatarKunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/1627364852-28432-1-git-send-email-hayashi.kunihiko@socionext.com


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 6b4b87f2
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -209,7 +209,7 @@ static int uniphier_xdmac_chan_stop(struct uniphier_xdmac_chan *xc)
	writel(0, xc->reg_ch_base + XDMAC_TSS);

	/* wait until transfer is stopped */
	return readl_poll_timeout(xc->reg_ch_base + XDMAC_STAT, val,
	return readl_poll_timeout_atomic(xc->reg_ch_base + XDMAC_STAT, val,
					 !(val & XDMAC_STAT_TENF), 100, 1000);
}