dmaengine: dw: Move check for paused channel to dwc_get_residue()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 30 Jan 2023 15:17:47 +0000 (17:17 +0200)
committerVinod Koul <vkoul@kernel.org>
Thu, 16 Feb 2023 13:15:48 +0000 (18:45 +0530)
commit255ccd8b16a516209deb4257aa4e89e42a26413a
tree0949837486c1894ee8f06b7b1a999343ec6a0a18
parent928469986171a6f763b34b039427f5667ba3fd50
dmaengine: dw: Move check for paused channel to dwc_get_residue()

Move check for paused channel to dwc_get_residue() and rename the latter
to dwc_get_residue_and_status().

This improves data integrity as residue and DMA channel status are set
in the same function under the same conditions.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20230130151747.20704-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/dw/core.c