dma: tegra: add accurate reporting of dma state
PATCH 4/6 dma: tegra: add accurate reporting of dma state
21.02.2019 13:06, Ben Dooks пишет:
Quoted 17 lines · Dmitry Osipenko
Quoted 16 lines
31.10.2018 19:03, Ben Dooks пишет:
Quoted 5 lines
The
tx_statuscallback does not report the state of the transfer beyond complete segments. This causes problems with users such as ALSA when applications want to know accurately how much data has been moved.Quoted 7 lines
This patch addes a function
tegra_dma_update_residual()to query the hardware and modify the residual information accordinly. It takes into account any hardware issues when trying to read the state, such as delays between finishing a buffer and signalling the interrupt.Signed-off-by Ben Dooks <[email protected]>Hello Ben,
Quoted 8 lines
Quoted 1 line
Do you have any plans to submit a new version of this patch? It's really useful and fixes a real problem with the audio playback. I could help with finalizing the patch and could submit it for you if you happened to lost the interest.
Personally I think the original version was fine. It has been tested and returns fairly quickly (I am not a fan of just adding more delay in)
My notes say the condition doesn't last for long and the loop tends to terminate within 2 runs.
Okay, so are you going to re-send the patch? We can back to the review after, you need at least to re-send because this series has been outdated. Also please take a look and feel free to use as-is the reduced variant of yours patch that I was carrying and testing for months now [0], it works great.
[0] https://github.com/grate-driver/linux/commit/ab8a67a6f47185f265f16749b55df214aaaefad4