Commit 79861bbb authored by Ben Dooks's avatar Ben Dooks Committed by Mark Brown

ASoC: rsnd: fix clock prepare/unprepare

As with the previous commit, before a clock can be used it must be prepared
for use. Change from clk_enable() and clk_disable() to the versions of the
calls which also prepare and un-prepare the clocks.

Will fix warnings from the clock code when this is used.
Signed-off-by: default avatarBen Dooks <ben.dooks@codethink.co.uk>
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent ab5d6fbd
...@@ -258,7 +258,7 @@ static int rsnd_src_init(struct rsnd_mod *mod, ...@@ -258,7 +258,7 @@ static int rsnd_src_init(struct rsnd_mod *mod,
{ {
struct rsnd_src *src = rsnd_mod_to_src(mod); struct rsnd_src *src = rsnd_mod_to_src(mod);
clk_enable(src->clk); clk_prepare_enable(src->clk);
return 0; return 0;
} }
...@@ -269,7 +269,7 @@ static int rsnd_src_quit(struct rsnd_mod *mod, ...@@ -269,7 +269,7 @@ static int rsnd_src_quit(struct rsnd_mod *mod,
{ {
struct rsnd_src *src = rsnd_mod_to_src(mod); struct rsnd_src *src = rsnd_mod_to_src(mod);
clk_disable(src->clk); clk_disable_unprepare(src->clk);
return 0; return 0;
} }
......
...@@ -171,7 +171,7 @@ static void rsnd_ssi_hw_start(struct rsnd_ssi *ssi, ...@@ -171,7 +171,7 @@ static void rsnd_ssi_hw_start(struct rsnd_ssi *ssi,
u32 cr; u32 cr;
if (0 == ssi->usrcnt) { if (0 == ssi->usrcnt) {
clk_enable(ssi->clk); clk_prepare_enable(ssi->clk);
if (rsnd_dai_is_clk_master(rdai)) { if (rsnd_dai_is_clk_master(rdai)) {
if (rsnd_ssi_clk_from_parent(ssi)) if (rsnd_ssi_clk_from_parent(ssi))
...@@ -230,7 +230,7 @@ static void rsnd_ssi_hw_stop(struct rsnd_ssi *ssi, ...@@ -230,7 +230,7 @@ static void rsnd_ssi_hw_stop(struct rsnd_ssi *ssi,
rsnd_ssi_master_clk_stop(ssi); rsnd_ssi_master_clk_stop(ssi);
} }
clk_disable(ssi->clk); clk_disable_unprepare(ssi->clk);
} }
dev_dbg(dev, "ssi%d hw stopped\n", rsnd_mod_id(&ssi->mod)); dev_dbg(dev, "ssi%d hw stopped\n", rsnd_mod_id(&ssi->mod));
......
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