Commit dad57a51 authored by Chanho Park's avatar Chanho Park Committed by Mark Brown

spi: s3c64xx: correct dma_chan pointer initialization

Use NULL for dma channel pointer initialization instead of plain integer.

sparse warnings: (new ones prefixed by >>)
>> drivers/spi/spi-s3c64xx.c:387:34: sparse: sparse: Using plain integer as NULL pointer
   drivers/spi/spi-s3c64xx.c:388:34: sparse: sparse: Using plain integer as NULL pointer
Reported-by: default avatarkernel test robot <lkp@intel.com>
Fixes: 82295bc0 ("spi: s3c64xx: move dma_release_channel to unprepare")
Fixes: f52b03c7 ("spi: s3c64xx: requests spi-dma channel only during data transfer")
Signed-off-by: default avatarChanho Park <chanho61.park@samsung.com>
Reviewed-by: default avatarAndi Shyti <andi@etezian.org>
Reviewed-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20220808004851.25122-1-chanho61.park@samsung.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent fba933c2
......@@ -389,8 +389,8 @@ static int s3c64xx_spi_unprepare_transfer(struct spi_master *spi)
if (sdd->rx_dma.ch && sdd->tx_dma.ch) {
dma_release_channel(sdd->rx_dma.ch);
dma_release_channel(sdd->tx_dma.ch);
sdd->rx_dma.ch = 0;
sdd->tx_dma.ch = 0;
sdd->rx_dma.ch = NULL;
sdd->tx_dma.ch = NULL;
}
return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment