From: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
To: olivier moysan <olivier.moysan@st.com>
Cc: alsa-devel@alsa-project.org, alexandre.torgue@st.com,
arnaud.pouliquen@st.com, tiwai@suse.com, lgirdwood@gmail.com,
broonie@kernel.org, mcoquelin.stm32@gmail.com
Subject: Re: [RFC PATCH 0/2] ASoC: wm8994: master clock issues
Date: Mon, 20 Mar 2017 14:11:37 +0000 [thread overview]
Message-ID: <20170320141137.GR6986@localhost.localdomain> (raw)
In-Reply-To: <1489682483-13051-1-git-send-email-olivier.moysan@st.com>
On Thu, Mar 16, 2017 at 05:41:21PM +0100, olivier moysan wrote:
> Hello,
>
> I face two issues using wm8994 codec driver.
> Below is a description of the use cases rising the problem.
> I added the patches which allow to fix these issues.
> These minimalist patches can be seen as a starting point for a discussion on the best
> way to handle the use cases exposed.
>
>
> - ASoC: wm8994: default master clock selection
>
> Use case:
> CPU DAI and codec are managed through simple card.
> Wolson codec wm8994 is set as slave of CPU DAI and CPU DAI feeds codec with master clock.
> Master clock is derived from mclk-fs property and provided to CPU DAI and codec
> through snd_soc_dai_set_sysclk API.
>
> Analysis:
> The simple card assumes id 0 for master clock.
> However wm8994 codec exposes master clock ids from 1 to 4. (MCLK1, MCLK2 ..)
>
> The proposal in this patch is to define a default selection regarding master clock
> when id 0 is provided.
>
>
> - ASoC: wm8994: delay aifxclk activation
>
> Use case:
> Wolson codec wm8994 is set as slave of CPU DAI and CPU DAI feeds codec with master clock.
> CPU DAI generates master clock when enabled in trigger callback.
> So master clock is available only at runtime.
> Master clock is not available when configuring codec through alsa controls.
>
> Analysis:
> When we configure aifx clock while master clock is not active, related registers are not updated in wm8894 codec.
> A way to go around this problem, is to delay aifxclk activation until SND_SOC_DAPM_POST_PMU DAPM stage.
> The purpose of patch here is to illustrate this workaround.
>
> What I cannot clearly figure out, is how this may impact other uses of wm8894 codec.
> I try to know if it's worth investigating further in this direction or if it will not be applicable.
> If not applicable, what maybe the other options ?
>
> regards
> olivier
Would be good to CC patches@opensource.wolfsonmicro.com on the
next version of these patches as well, higher chance someone here
will notice and have a look over them.
Thanks,
Charles
prev parent reply other threads:[~2017-03-20 14:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-16 16:41 [RFC PATCH 0/2] ASoC: wm8994: master clock issues olivier moysan
2017-03-16 16:41 ` [RFC PATCH 1/2] ASoC: wm8994: default master clock selection olivier moysan
2017-03-16 16:41 ` [RFC PATCH 2/2] ASoC: wm8994: delay aifxclk activation olivier moysan
2017-03-16 17:51 ` Mark Brown
2017-03-17 15:37 ` Olivier MOYSAN
2017-03-20 14:11 ` Charles Keepax [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170320141137.GR6986@localhost.localdomain \
--to=ckeepax@opensource.wolfsonmicro.com \
--cc=alexandre.torgue@st.com \
--cc=alsa-devel@alsa-project.org \
--cc=arnaud.pouliquen@st.com \
--cc=broonie@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=mcoquelin.stm32@gmail.com \
--cc=olivier.moysan@st.com \
--cc=tiwai@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).