dmaengine: tegra-apb: Ensure that clock is enabled during of DMA synchronization
authorDmitry Osipenko <digetx@gmail.com>
Sun, 26 Apr 2020 19:08:35 +0000 (22:08 +0300)
committerVinod Koul <vkoul@kernel.org>
Mon, 27 Apr 2020 16:05:35 +0000 (21:35 +0530)
commit664475cffb8cd2ee3b9602e60f07c244abb05d4a
treedb56c496be3d96cc4ac4c58cd331f8fba8abbb84
parent0821009445a8261ac4d32a6df4b83938e007c765
dmaengine: tegra-apb: Ensure that clock is enabled during of DMA synchronization

DMA synchronization hook checks whether interrupt is raised by testing
corresponding bit in a hardware status register, and thus, clock should
be enabled in this case, otherwise CPU may hang if synchronization is
invoked while Runtime PM is in suspended state. This patch resumes the RPM
during of the DMA synchronization process in order to avoid potential
problems. It is a minor clean up of a previous commit, no real problem is
fixed by this patch because currently RPM is always in a resumed state
while DMA is synchronized, although this may change in the future.

Fixes: 6697255f239f ("dmaengine: tegra-apb: Improve DMA synchronization")
Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
Link: https://lore.kernel.org/r/20200426190835.21950-1-digetx@gmail.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/tegra20-apb-dma.c