diff options
author | Wolfram Sang <wsa+renesas@sang-engineering.com> | 2021-06-23 11:59:36 +0200 |
---|---|---|
committer | Wolfram Sang <wsa@kernel.org> | 2021-08-11 15:15:30 +0200 |
commit | 73a370cff4db1ad2c19340c38c7ee9a67bfc340d (patch) | |
tree | 0e935e355505f5518dbe0dfbf9d28dc518c731ce /drivers/i2c | |
parent | 73c76332a448e522fbcea3b52fee442f531f7b49 (diff) | |
download | linux-73a370cff4db1ad2c19340c38c7ee9a67bfc340d.tar.bz2 |
i2c: imx: : use proper DMAENGINE API for termination
dmaengine_terminate_all() is deprecated in favor of explicitly saying if
it should be sync or async. Here, we want dmaengine_terminate_sync()
because there is no other synchronization code in the driver to handle
an async case.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Oleksij Rempel <o.rempel@pengutronix.de>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/busses/i2c-imx.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c index d5b5f084a27d..3576b63a6c03 100644 --- a/drivers/i2c/busses/i2c-imx.c +++ b/drivers/i2c/busses/i2c-imx.c @@ -423,7 +423,7 @@ static int i2c_imx_dma_xfer(struct imx_i2c_struct *i2c_imx, return 0; err_submit: - dmaengine_terminate_all(dma->chan_using); + dmaengine_terminate_sync(dma->chan_using); err_desc: dma_unmap_single(chan_dev, dma->dma_buf, dma->dma_len, dma->dma_data_dir); @@ -894,7 +894,7 @@ static int i2c_imx_dma_write(struct imx_i2c_struct *i2c_imx, &i2c_imx->dma->cmd_complete, msecs_to_jiffies(DMA_TIMEOUT)); if (time_left == 0) { - dmaengine_terminate_all(dma->chan_using); + dmaengine_terminate_sync(dma->chan_using); return -ETIMEDOUT; } @@ -949,7 +949,7 @@ static int i2c_imx_dma_read(struct imx_i2c_struct *i2c_imx, &i2c_imx->dma->cmd_complete, msecs_to_jiffies(DMA_TIMEOUT)); if (time_left == 0) { - dmaengine_terminate_all(dma->chan_using); + dmaengine_terminate_sync(dma->chan_using); return -ETIMEDOUT; } |