* [PATCH] ASoC: TWL4030: Modify codec default settings
@ 2010-01-28 13:57 Peter Ujfalusi
2010-01-28 14:14 ` Liam Girdwood
2010-01-28 14:34 ` Mark Brown
0 siblings, 2 replies; 6+ messages in thread
From: Peter Ujfalusi @ 2010-01-28 13:57 UTC (permalink / raw)
To: alsa-devel; +Cc: broonie
Change the legacy default register configuration, which left some
internal components on.
Now we have either DAPM, or other ways to control these bits,
so there is no need to enable them by default.
The affected parts:
Disable ADCL and ADCR
Disable ARXL2 and ARXR2 analog PGA (playback)
Disable APLL by default
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
---
sound/soc/codecs/twl4030.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/sound/soc/codecs/twl4030.c b/sound/soc/codecs/twl4030.c
index 74f0d65..e0106a5 100644
--- a/sound/soc/codecs/twl4030.c
+++ b/sound/soc/codecs/twl4030.c
@@ -64,12 +64,12 @@ static const u8 twl4030_reg[TWL4030_CACHEREGNUM] = {
0x00, /* REG_VRXPGA (0x14) */
0x00, /* REG_VSTPGA (0x15) */
0x00, /* REG_VRX2ARXPGA (0x16) */
- 0x0c, /* REG_AVDAC_CTL (0x17) */
+ 0x00, /* REG_AVDAC_CTL (0x17) */
0x00, /* REG_ARX2VTXPGA (0x18) */
0x00, /* REG_ARXL1_APGA_CTL (0x19) */
0x00, /* REG_ARXR1_APGA_CTL (0x1A) */
- 0x4b, /* REG_ARXL2_APGA_CTL (0x1B) */
- 0x4b, /* REG_ARXR2_APGA_CTL (0x1C) */
+ 0x4a, /* REG_ARXL2_APGA_CTL (0x1B) */
+ 0x4a, /* REG_ARXR2_APGA_CTL (0x1C) */
0x00, /* REG_ATX2ARXPGA (0x1D) */
0x00, /* REG_BT_IF (0x1E) */
0x00, /* REG_BTPGA (0x1F) */
@@ -99,7 +99,7 @@ static const u8 twl4030_reg[TWL4030_CACHEREGNUM] = {
0x00, /* REG_I2S_RX_SCRAMBLE_H (0x37) */
0x00, /* REG_I2S_RX_SCRAMBLE_M (0x38) */
0x00, /* REG_I2S_RX_SCRAMBLE_L (0x39) */
- 0x16, /* REG_APLL_CTL (0x3A) */
+ 0x06, /* REG_APLL_CTL (0x3A) */
0x00, /* REG_DTMF_CTL (0x3B) */
0x00, /* REG_DTMF_PGA_CTL2 (0x3C) */
0x00, /* REG_DTMF_PGA_CTL1 (0x3D) */
--
1.6.6.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] ASoC: TWL4030: Modify codec default settings
2010-01-28 13:57 [PATCH] ASoC: TWL4030: Modify codec default settings Peter Ujfalusi
@ 2010-01-28 14:14 ` Liam Girdwood
2010-01-28 14:25 ` Peter Ujfalusi
2010-01-28 14:34 ` Mark Brown
1 sibling, 1 reply; 6+ messages in thread
From: Liam Girdwood @ 2010-01-28 14:14 UTC (permalink / raw)
To: Peter Ujfalusi; +Cc: alsa-devel, broonie
On Thu, 2010-01-28 at 15:57 +0200, Peter Ujfalusi wrote:
> Change the legacy default register configuration, which left some
> internal components on.
> Now we have either DAPM, or other ways to control these bits,
> so there is no need to enable them by default.
>
> The affected parts:
> Disable ADCL and ADCR
> Disable ARXL2 and ARXR2 analog PGA (playback)
> Disable APLL by default
>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Btw, should we be expecting more of these or does the twl4030 have full
DAPM coverage now ?
Thanks
Liam
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ASoC: TWL4030: Modify codec default settings
2010-01-28 14:14 ` Liam Girdwood
@ 2010-01-28 14:25 ` Peter Ujfalusi
0 siblings, 0 replies; 6+ messages in thread
From: Peter Ujfalusi @ 2010-01-28 14:25 UTC (permalink / raw)
To: alsa-devel; +Cc: broonie@opensource.wolfsonmicro.com, ext Liam Girdwood
Hello Liam,
On Thursday 28 January 2010 16:14:05 ext Liam Girdwood wrote:
> On Thu, 2010-01-28 at 15:57 +0200, Peter Ujfalusi wrote:
> > Change the legacy default register configuration, which left some
> > internal components on.
> > Now we have either DAPM, or other ways to control these bits,
> > so there is no need to enable them by default.
> >
> > The affected parts:
> > Disable ADCL and ADCR
> > Disable ARXL2 and ARXR2 analog PGA (playback)
> > Disable APLL by default
>
> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
>
> Btw, should we be expecting more of these or does the twl4030 have full
> DAPM coverage now ?
Well, there are couple of small things that I'm not that satisfied with the
current implementation:
Some outputs are enabled by default (Headset namely),
Few other defaults, which might not need to be enabled,
In OPTION register the RX2 and TX1 path enable bits are not handled by DAPM,
and there were something else also, which I can not recall...
All in all I think the twl4030 codec driver is now in a really good shape, but
still needs some fine tuning to be close to perfect ;)
So yes, there will be more patches coming, but I'm not sure about the time line
for those.
> Thanks
>
> Liam
>
--
Péter
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ASoC: TWL4030: Modify codec default settings
2010-01-28 13:57 [PATCH] ASoC: TWL4030: Modify codec default settings Peter Ujfalusi
2010-01-28 14:14 ` Liam Girdwood
@ 2010-01-28 14:34 ` Mark Brown
2010-01-29 7:01 ` Peter Ujfalusi
1 sibling, 1 reply; 6+ messages in thread
From: Mark Brown @ 2010-01-28 14:34 UTC (permalink / raw)
To: Peter Ujfalusi; +Cc: alsa-devel
On Thu, Jan 28, 2010 at 03:57:04PM +0200, Peter Ujfalusi wrote:
> Change the legacy default register configuration, which left some
> internal components on.
> Now we have either DAPM, or other ways to control these bits,
> so there is no need to enable them by default.
Applied, thanks. Though if they're regular DAPM controls then they
should get turned off again during startup if they're not used.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ASoC: TWL4030: Modify codec default settings
2010-01-28 14:34 ` Mark Brown
@ 2010-01-29 7:01 ` Peter Ujfalusi
2010-01-29 10:17 ` Mark Brown
0 siblings, 1 reply; 6+ messages in thread
From: Peter Ujfalusi @ 2010-01-29 7:01 UTC (permalink / raw)
To: ext Mark Brown; +Cc: alsa-devel@alsa-project.org
On Thursday 28 January 2010 16:34:24 ext Mark Brown wrote:
> On Thu, Jan 28, 2010 at 03:57:04PM +0200, Peter Ujfalusi wrote:
> > Change the legacy default register configuration, which left some
> > internal components on.
> > Now we have either DAPM, or other ways to control these bits,
> > so there is no need to enable them by default.
>
> Applied, thanks. Though if they're regular DAPM controls then they
> should get turned off again during startup if they're not used.
What I have found out is that after boot these bits were set (obviously), after
the audio activity, they were cleared (not all, since if the given DAPM control
was not in the path, it was left enabled either way).
Now these bits are 0 after boot, and only enabled, when a certain path needs it.
In short: the overall power consumption was higher after boot, than what was
after for example the playback was stopped...
--
Péter
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ASoC: TWL4030: Modify codec default settings
2010-01-29 7:01 ` Peter Ujfalusi
@ 2010-01-29 10:17 ` Mark Brown
0 siblings, 0 replies; 6+ messages in thread
From: Mark Brown @ 2010-01-29 10:17 UTC (permalink / raw)
To: Peter Ujfalusi; +Cc: alsa-devel@alsa-project.org
On Fri, Jan 29, 2010 at 09:01:30AM +0200, Peter Ujfalusi wrote:
> What I have found out is that after boot these bits were set (obviously), after
> the audio activity, they were cleared (not all, since if the given DAPM control
> was not in the path, it was left enabled either way).
> Now these bits are 0 after boot, and only enabled, when a certain path needs it.
> In short: the overall power consumption was higher after boot, than what was
> after for example the playback was stopped...
Hrm, that shouldn't happen - DAPM should be syncing during startup which
will turn off anything that's left turned on. I'll have to fake up a
test for this, I'd not notice problems normally since all the devices I
start with power everything off by default.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2010-01-29 10:17 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-28 13:57 [PATCH] ASoC: TWL4030: Modify codec default settings Peter Ujfalusi
2010-01-28 14:14 ` Liam Girdwood
2010-01-28 14:25 ` Peter Ujfalusi
2010-01-28 14:34 ` Mark Brown
2010-01-29 7:01 ` Peter Ujfalusi
2010-01-29 10:17 ` Mark Brown
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.