]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: mxs-saif: fix clock prepare and enable unbalance issue
authorDong Aisheng <dong.aisheng@linaro.org>
Fri, 20 Jul 2012 09:20:24 +0000 (17:20 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 24 Jul 2012 19:17:58 +0000 (20:17 +0100)
commitc826773a4baaa02db90d28a83ef580263e8b94cb
tree2f7a0a5020881a9e4bc4413f60849bed279c9d08
parentf6e0c8e7813e9194e26f831493c31541b4e763d5
ASoC: mxs-saif: fix clock prepare and enable unbalance issue

Currently we directly call a clock_enable in trigger function without
a clk_prepare as pair first.
This will cause system hang immediately when run capture because
the clock was not prepared(playback does not hang because the clock was
prepared already by get_mclk before), a warning message in clock framework
may cause a deadlock to reclaim clock lock (see: pl011_console_write).

Here we prepare clock first in hw_param, then enable it in trigger
function to guarantee the balance.

Signed-off-by: Dong Aisheng <dong.aisheng@linaro.org>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/mxs/mxs-saif.c