From: Liam Girdwood <lrg@ti.com>
To: Takashi Iwai <tiwai@suse.de>
Cc: "alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
Mark Brown <broonie@opensource.wolfsonmicro.com>
Subject: Re: [PATCH] ASoC: dapm - Refactor widget IO functions in preparation for platform widgets.
Date: Fri, 10 Jun 2011 15:44:30 +0100 [thread overview]
Message-ID: <4DF22DCE.8040406@ti.com> (raw)
In-Reply-To: <s5h4o3x3mzl.wl%tiwai@suse.de>
On 10/06/11 13:11, Takashi Iwai wrote:
> At Thu, 9 Jun 2011 19:10:49 +0100,
> Liam Girdwood wrote:
>>
>> Currently widget IO is tightly coupled to the CODEC drivers. Future platform DSP
>> devices have mixer components that can alter power usage and hence require full
>> DAPM support.
>>
>> This provides a generic widget IO operation wrapper in preparation for
>> future patches that implement platform driver DAPM.
>>
>> Signed-off-by: Liam Girdwood <lrg@ti.com>
>> ---
>> sound/soc/soc-dapm.c | 55 ++++++++++++++++++++++++++++++++++++++++++++-----
>> 1 files changed, 49 insertions(+), 6 deletions(-)
>>
>> diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c
>> index 34106bc..7b7af9f 100644
>> --- a/sound/soc/soc-dapm.c
>> +++ b/sound/soc/soc-dapm.c
>> @@ -124,6 +124,49 @@ static inline struct snd_soc_dapm_widget *dapm_cnew_widget(
>> return kmemdup(_widget, sizeof(*_widget), GFP_KERNEL);
>> }
>>
>> +static int soc_widget_read(struct snd_soc_dapm_widget *w, int reg)
>> +{
>> + if (w->codec)
>> + return snd_soc_read(w->codec, reg);
>> + return 0;
>> +}
>> +
>> +static int soc_widget_write(struct snd_soc_dapm_widget *w,int reg, int val)
>
> Missing space after comma.
Thanks, didn't see that.
>
>> +{
>> + if (w->codec)
>> + return snd_soc_write(w->codec, reg, val);
>> + return 0;
>> +}
>> +
>> +int soc_widget_update_bits(struct snd_soc_dapm_widget *w, unsigned short reg,
>> + unsigned int mask, unsigned int value)
>
> Do you want to expose this and soc_widget_test_bits()?
> Or just forgotten static?
>
The original intention was that they may have been used by the ABE but this seems unlikely now.
I'll make them static for V2 and remove test_bits since it's not used.
Liam
next prev parent reply other threads:[~2011-06-10 14:44 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-09 18:10 [PATCH] ASoC: dapm - Refactor widget IO functions in preparation for platform widgets Liam Girdwood
2011-06-09 19:21 ` Mark Brown
2011-06-10 12:11 ` Takashi Iwai
2011-06-10 14:44 ` Liam Girdwood [this message]
2011-06-10 14:58 ` Takashi Iwai
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=4DF22DCE.8040406@ti.com \
--to=lrg@ti.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@opensource.wolfsonmicro.com \
--cc=tiwai@suse.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.