diff options
author | Christophe JAILLET <[email protected]> | 2020-03-18 20:12:09 +0100 |
---|---|---|
committer | Vinod Koul <[email protected]> | 2020-03-23 11:48:34 +0530 |
commit | 018af9be3dd54e6f24f828966bdd873f4d63ad9b (patch) | |
tree | 88b42568a023be2584da4b32a8d8277e6389cbd9 /scripts/gcc-plugins/sancov_plugin.c | |
parent | 01c4df39a2bb732e0593ba3cdacc1552fd07f7b9 (diff) |
dmaengine: ti: k3-udma-glue: Fix an error handling path in 'k3_udma_glue_cfg_rx_flow()'
All but one error handling paths in the 'k3_udma_glue_cfg_rx_flow()'
function 'goto err' and call 'k3_udma_glue_release_rx_flow()'.
This not correct because this function has a 'channel->flows_ready--;' at
the end, but 'flows_ready' has not been incremented here, when we branch to
the error handling path.
In order to keep a correct value in 'flows_ready', un-roll
'k3_udma_glue_release_rx_flow()', simplify it, add some labels and branch
at the correct places when an error is detected.
Doing so, we also NULLify 'flow->udma_rflow' in a path that was lacking it.
Fixes: d70241913413 ("dmaengine: ti: k3-udma: Add glue layer for non DMAengine user")
Signed-off-by: Christophe JAILLET <[email protected]>
Acked-by: Peter Ujfalusi <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Vinod Koul <[email protected]>
Diffstat (limited to 'scripts/gcc-plugins/sancov_plugin.c')
0 files changed, 0 insertions, 0 deletions