diff options
author | Jon Lin <jon.lin@rock-chips.com> | 2021-08-21 15:49:25 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-08-23 18:41:07 +0300 |
commit | 8d00f9819458b95301e274c6df705df2963ba34f (patch) | |
tree | b93e32f7478097bab22ba68ee548fab4f569d8d8 /drivers/spi/spi-rockchip-sfc.c | |
parent | 7a4697b201a617907e4b440ae34df601d4755bef (diff) | |
download | linux-8d00f9819458b95301e274c6df705df2963ba34f.tar.xz |
spi: rockchip-sfc: Remove redundant IO operations
Coherent dma buffer is uncached and memcpy is enough.
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
Link: https://lore.kernel.org/r/20210821124925.6066-1-jon.lin@rock-chips.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-rockchip-sfc.c')
-rw-r--r-- | drivers/spi/spi-rockchip-sfc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi-rockchip-sfc.c b/drivers/spi/spi-rockchip-sfc.c index 7c4d47fe80c2..81154a8836fc 100644 --- a/drivers/spi/spi-rockchip-sfc.c +++ b/drivers/spi/spi-rockchip-sfc.c @@ -453,7 +453,7 @@ static int rockchip_sfc_xfer_data_dma(struct rockchip_sfc *sfc, dev_dbg(sfc->dev, "sfc xfer_dma len=%x\n", len); if (op->data.dir == SPI_MEM_DATA_OUT) - memcpy_toio(sfc->buffer, op->data.buf.out, len); + memcpy(sfc->buffer, op->data.buf.out, len); ret = rockchip_sfc_fifo_transfer_dma(sfc, sfc->dma_buffer, len); if (!wait_for_completion_timeout(&sfc->cp, msecs_to_jiffies(2000))) { @@ -462,7 +462,7 @@ static int rockchip_sfc_xfer_data_dma(struct rockchip_sfc *sfc, } rockchip_sfc_irq_mask(sfc, SFC_IMR_DMA); if (op->data.dir == SPI_MEM_DATA_IN) - memcpy_fromio(op->data.buf.in, sfc->buffer, len); + memcpy(op->data.buf.in, sfc->buffer, len); return ret; } |