]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: mxs-saif: fix clk_prepare() without matching clk_unprepare()
authorMans Rullgard <mans@mansr.com>
Thu, 21 Jan 2016 14:55:56 +0000 (14:55 +0000)
committerMark Brown <broonie@kernel.org>
Wed, 27 Jan 2016 13:20:45 +0000 (13:20 +0000)
commitf072924dd3e13bb09a700df63375f7d72567a018
tree575174911ae08cd18c05bb32e62556a3631060ba
parent5367e65a538f2d59834d845f582bc1f1ae9599b8
ASoC: mxs-saif: fix clk_prepare() without matching clk_unprepare()

The clk_prepare() call in hw_params() has no matching clk_unprepare(),
leaving the clk with an ever-increasing prepare count.  Moreover,
hw_params() can be called multiple times which would again leave us
with a runaway prepare count.  Fix this by moving the clk_prepare()
call to the startup() function and adding a shutdown() function with
a matching clk_unprepare() as these operations are already correctly
bracketed by soc-core.

Signed-off-by: Mans Rullgard <mans@mansr.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/mxs/mxs-saif.c