提交 b9a59166 编写于 作者: R Richard Zhao 提交者: Vinod Koul

dma/imx-sdma: let sdma_run_channel call sdma_enable_channel

Let all enable channel code call sdma_enable_channel.
Signed-off-by: NRichard Zhao <richard.zhao@linaro.org>
Acked-by: NShawn Guo <shawn.guo@linaro.org>
Acked-by: NSascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: NVinod Koul <vinod.koul@linux.intel.com>
上级 880db3ff
......@@ -394,6 +394,11 @@ static int sdma_config_ownership(struct sdma_channel *sdmac,
return 0;
}
static void sdma_enable_channel(struct sdma_engine *sdma, int channel)
{
__raw_writel(1 << channel, sdma->regs + SDMA_H_START);
}
/*
* sdma_run_channel - run a channel and wait till it's done
*/
......@@ -405,7 +410,7 @@ static int sdma_run_channel(struct sdma_channel *sdmac)
init_completion(&sdmac->done);
__raw_writel(1 << channel, sdma->regs + SDMA_H_START);
sdma_enable_channel(sdma, channel);
ret = wait_for_completion_timeout(&sdmac->done, HZ);
......@@ -811,11 +816,6 @@ static int sdma_request_channel(struct sdma_channel *sdmac)
return ret;
}
static void sdma_enable_channel(struct sdma_engine *sdma, int channel)
{
__raw_writel(1 << channel, sdma->regs + SDMA_H_START);
}
static dma_cookie_t sdma_assign_cookie(struct sdma_channel *sdmac)
{
dma_cookie_t cookie = sdmac->chan.cookie;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册