All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/3] ASoC: TWL4030: Add AVADC Clock Priority
@ 2009-06-19  8:23 Lopez Cruz, Misael
  2009-06-19 10:00 ` Mark Brown
  0 siblings, 1 reply; 4+ messages in thread
From: Lopez Cruz, Misael @ 2009-06-19  8:23 UTC (permalink / raw)
  To: alsa-devel; +Cc: Mark Brown, Peter Ujfalusi

AVDAC clk priority allows to determine the path ADC must
be connected when the codec is in option2 and both audio
and voice paths are enabled.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
---
 sound/soc/codecs/twl4030.c |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/sound/soc/codecs/twl4030.c b/sound/soc/codecs/twl4030.c
index 780217a..fd5b30f 100644
--- a/sound/soc/codecs/twl4030.c
+++ b/sound/soc/codecs/twl4030.c
@@ -1036,6 +1036,16 @@ static DECLARE_TLV_DB_SCALE(digital_capture_tlv, 0, 100, 0);
  */
 static DECLARE_TLV_DB_SCALE(input_gain_tlv, 0, 600, 0);
 
+/* AVADC clock priority */
+static const char *twl4030_avadc_clk_priority_texts[] = {
+	"Voice high priority", "Audio high priority"
+};
+
+static const struct soc_enum twl4030_avadc_clk_priority_enum =
+	SOC_ENUM_SINGLE(TWL4030_REG_AVADC_CTL, 2,
+			ARRAY_SIZE(twl4030_avadc_clk_priority_texts),
+			twl4030_avadc_clk_priority_texts);
+
 static const char *twl4030_rampdelay_texts[] = {
 	"27/20/14 ms", "55/40/27 ms", "109/81/55 ms", "218/161/109 ms",
 	"437/323/218 ms", "874/645/437 ms", "1748/1291/874 ms",
@@ -1137,6 +1147,8 @@ static const struct snd_kcontrol_new twl4030_snd_controls[] = {
 	SOC_DOUBLE_TLV("Analog Capture Volume", TWL4030_REG_ANAMIC_GAIN,
 		0, 3, 5, 0, input_gain_tlv),
 
+	SOC_ENUM("AVADC Clock Priority", twl4030_avadc_clk_priority_enum),
+
 	SOC_ENUM("HS ramp delay", twl4030_rampdelay_enum),
 
 	SOC_ENUM("Vibra H-bridge mode", twl4030_vibradirmode_enum),
-- 
1.5.4.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/3] ASoC: TWL4030: Add AVADC Clock Priority
  2009-06-19  8:23 [PATCH 2/3] ASoC: TWL4030: Add AVADC Clock Priority Lopez Cruz, Misael
@ 2009-06-19 10:00 ` Mark Brown
  2009-06-19 17:57   ` Lopez Cruz, Misael
  0 siblings, 1 reply; 4+ messages in thread
From: Mark Brown @ 2009-06-19 10:00 UTC (permalink / raw)
  To: Lopez Cruz, Misael; +Cc: alsa-devel, Peter Ujfalusi

On Fri, Jun 19, 2009 at 03:23:42AM -0500, Lopez Cruz, Misael wrote:

> +/* AVADC clock priority */
> +static const char *twl4030_avadc_clk_priority_texts[] = {
> +	"Voice high priority", "Audio high priority"
> +};
> +

It'd probably be better to say "Hifi" (or whatever spelling the rest of
the driver uses) rather than "Audio" here.  Audio is a bit confusing
since obviously the voice data is audio data too, it's just a different
path through the CODEC with different characteristics.  The same thing
has been done elsewhere in the driver.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/3] ASoC: TWL4030: Add AVADC Clock Priority
  2009-06-19 10:00 ` Mark Brown
@ 2009-06-19 17:57   ` Lopez Cruz, Misael
  2009-06-22  6:36     ` Peter Ujfalusi
  0 siblings, 1 reply; 4+ messages in thread
From: Lopez Cruz, Misael @ 2009-06-19 17:57 UTC (permalink / raw)
  To: Mark Brown; +Cc: alsa-devel, Peter, Ujfalusi

> > +/* AVADC clock priority */
> > +static const char *twl4030_avadc_clk_priority_texts[] = {
> > +	"Voice high priority", "Audio high priority"
> > +};
> > +

> It'd probably be better to say "Hifi" (or whatever spelling 
> the rest of the driver uses) rather than "Audio" here.  Audio 
> is a bit confusing since obviously the voice data is audio 
> data too, it's just a different path through the CODEC with 
> different characteristics.  The same thing has been done 
> elsewhere in the driver.

Agree, "HiFi" is being used in codec DAI definition so I'll
use that too.

I'll wait for Peter's comments before resending the patch.

Thanks,
Misa

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/3] ASoC: TWL4030: Add AVADC Clock Priority
  2009-06-19 17:57   ` Lopez Cruz, Misael
@ 2009-06-22  6:36     ` Peter Ujfalusi
  0 siblings, 0 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2009-06-22  6:36 UTC (permalink / raw)
  To: ext Lopez Cruz, Misael; +Cc: alsa-devel, Mark Brown

On Friday 19 June 2009 20:57:39 ext Lopez Cruz, Misael wrote:
> > > +/* AVADC clock priority */
> > > +static const char *twl4030_avadc_clk_priority_texts[] = {
> > > +	"Voice high priority", "Audio high priority"
> > > +};
> > > +
> >
> > It'd probably be better to say "Hifi" (or whatever spelling
> > the rest of the driver uses) rather than "Audio" here.  Audio
> > is a bit confusing since obviously the voice data is audio
> > data too, it's just a different path through the CODEC with
> > different characteristics.  The same thing has been done
> > elsewhere in the driver.
>
> Agree, "HiFi" is being used in codec DAI definition so I'll
> use that too.
>
> I'll wait for Peter's comments before resending the patch.

Please change the Audio to HiFi, otherwise it is OK.

>
> Thanks,
> Misa

-- 
Péter

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-06-22  6:36 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-19  8:23 [PATCH 2/3] ASoC: TWL4030: Add AVADC Clock Priority Lopez Cruz, Misael
2009-06-19 10:00 ` Mark Brown
2009-06-19 17:57   ` Lopez Cruz, Misael
2009-06-22  6:36     ` Peter Ujfalusi

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.