mac_dbdma: always clear FLUSH bit once DBDMA channel flush is complete
commit1cde732d88af34849343dc1f0e68072eab0841b9
authorMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Sun, 23 Aug 2015 10:50:55 +0000 (23 11:50 +0100)
committerAlexander Graf <agraf@suse.de>
Sun, 20 Sep 2015 20:48:38 +0000 (20 22:48 +0200)
treed33dd5f5d30748229539485b23e24ac57d1d3bc8
parent116dc18db6854cc38c6abff799019b7237365a36
mac_dbdma: always clear FLUSH bit once DBDMA channel flush is complete

The code to flush the DBDMA channel was effectively duplicated in
dbdma_control_write(), except for the fact that the copy executed outside of a
RUN bit transition was broken by not clearing the FLUSH bit once the flush was
complete.

Newer PPC Linux kernels would timeout waiting for the FLUSH bit to clear again
after submitting a FLUSH command. Fix this by always clearing the FLUSH bit
once the channel flush is complete and removing the repeated code.

Reported-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Alexander Graf <agraf@suse.de>
hw/misc/macio/mac_dbdma.c