diff options
author | kumar km <kumar.km@stericsson.com> | 2011-09-22 13:19:05 +0530 |
---|---|---|
committer | Philippe Langlais <philippe.langlais@linaro.org> | 2012-03-19 09:00:59 +0100 |
commit | a35234e9d0e4438dc7236ca175a8132fe092928d (patch) | |
tree | f4714716aa1828112d8b33050a243ce1f8478df2 /sound/soc | |
parent | 23076f65e9b6ed061c3a7ad82979fa242edfb503 (diff) |
Ux500 ASoC:To decrease noise in Audio playback
This patch addresses loud noise that heard
at the start and end of audio plaback. This patch
enables DC offset cancellation and negative charge
pump voltage selection.
ST-Ericsson Linux next: Not tested, ER 342775
ST-Ericsson ID: 342775
ST-Ericsson FOSS-OUT ID: STETL-FOSS-OUT-10006
Signed-off-by: kumar km <kumar.km@stericsson.com>
Change-Id: I2d11d60f8ddf14a7fa02981ece78699f62e932af
Signed-off-by: kumar km <kumar.km@stericsson.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/31696
Reviewed-by: Avinash A <avinash.a@stericsson.com>
Tested-by: Avinash A <avinash.a@stericsson.com>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/codecs/ab5500.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/sound/soc/codecs/ab5500.c b/sound/soc/codecs/ab5500.c index 3482d139c57..79df2a6e812 100644 --- a/sound/soc/codecs/ab5500.c +++ b/sound/soc/codecs/ab5500.c @@ -1104,6 +1104,9 @@ static void power_for_playback(enum enum_power onoff, int ifsel) __func__); return; } + mask_set_reg(ENV_THR, ENV_THR_HIGH_MASK, 0x0F << ENV_THR_HIGH_SHIFT); + mask_set_reg(ENV_THR, ENV_THR_LOW_MASK, 0x0F << ENV_THR_LOW_SHIFT); + power_widget_unlocked(onoff, ifsel == 0 ? widget_if0_dld_l : widget_if1_dld_l); power_widget_unlocked(onoff, ifsel == 0 ? @@ -1112,6 +1115,8 @@ static void power_for_playback(enum enum_power onoff, int ifsel) mask_set_reg(SPKR1, SPKRx_PWR_MASK, 0x03 << SPKRx_PWR_SHIFT); mask_set_reg(SPKR1, SPKRx_GAIN_MASK, 0x12 << SPKRx_GAIN_SHIFT); mask_set_reg(RX3_DPGA, RXx_DPGA_MASK, 0x3F << RXx_DPGA_SHIFT); + mask_set_reg(DC_CANCEL, DC_CANCEL_AUXO12_MASK, + 0x01 << DC_CANCEL_AUXO12_SHIFT); mutex_unlock(&ab5500_pm_mutex); } @@ -1592,11 +1597,11 @@ static inline void init_playback_gain(void) { /* 0x43, 0x0C: pure gain values */ mask_set_reg(RX1_DPGA, RXx_DPGA_MASK, - 0x43 << RXx_DPGA_SHIFT); + 0x2C << RXx_DPGA_SHIFT); mask_set_reg(RX2_DPGA, RXx_DPGA_MASK, - 0x43 << RXx_DPGA_SHIFT); - mask_set_reg(AUXO1, AUXOx_GAIN_MASK, 0x0C << AUXOx_GAIN_SHIFT); - mask_set_reg(AUXO2, AUXOx_GAIN_MASK, 0x0C << AUXOx_GAIN_SHIFT); + 0x2C << RXx_DPGA_SHIFT); + mask_set_reg(AUXO1, AUXOx_GAIN_MASK, 0x0A << AUXOx_GAIN_SHIFT); + mask_set_reg(AUXO2, AUXOx_GAIN_MASK, 0x0A << AUXOx_GAIN_SHIFT); } static inline void init_capture_gain(void) |