diff options
author | Markus Pargmann <mpa@pengutronix.de> | 2014-05-27 10:24:23 +0200 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-06-01 11:55:08 +0100 |
commit | d429d8e3324cae120784a1e194ef6ea62aeb327e (patch) | |
tree | 1e1e30653ce73b844e2d8d36c1e8d9b1dcca827a /sound/spi | |
parent | b5dd91b3dcf937ce42583711fe4d679cacdbd2d0 (diff) | |
download | blackbird-op-linux-d429d8e3324cae120784a1e194ef6ea62aeb327e.tar.gz blackbird-op-linux-d429d8e3324cae120784a1e194ef6ea62aeb327e.zip |
ASoC: fsl-ssi: Fix baudclock handling
The baudclock may be used and set by different streams.
Allow only the first stream to set the bitclock rate. Other streams have
to try to get to the correct rate without modifying the bitclock rate
using the SSI internal clock modifiers.
The variable baudclk_streams is introduced to keep track of the active
streams that are using the baudclock. This way we know if the baudclock
may be set and whether we may enable/disable the clock.
baudclock enable/disable is moved to hw_params()/hw_free(). This way we can
keep track of the baudclock in those two functions and avoid a running
clock while it is not used. As hw_params()/hw_free() may be called
multiple times for the same stream, we have to use baudclk_streams
variable to know whether we may enable/disable the clock.
Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
Tested-By: Michael Grzeschik <mgr@pengutronix.de>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/spi')
0 files changed, 0 insertions, 0 deletions