Commit 10d48b39 authored by Mika Westerberg's avatar Mika Westerberg Committed by Russell King
Browse files

ARM: 6440/1: ep93xx: DMA: fix channel_disable

When channel_disable() is called, it disables per channel interrupts and
waits until channels state becomes STATE_STALL, and then disables the
channel. Now, if the DMA transfer is disabled while the channel is in
STATE_NEXT we will not wait anything and disable the channel immediately.
This seems to cause weird data corruption for example in audio transfers.

Fix is to wait while we are in STATE_NEXT or STATE_ON and only then
disable the channel.
Signed-off-by: default avatarMika Westerberg <>
Acked-by: default avatarRyan Mallon <>
Signed-off-by: default avatarRussell King <>
parent c0bb5862
......@@ -276,7 +276,7 @@ static void channel_disable(struct m2p_channel *ch)
m2p_set_control(ch, v);
while (m2p_channel_state(ch) == STATE_ON)
while (m2p_channel_state(ch) >= STATE_ON)
m2p_set_control(ch, 0x0);
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