Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1228260
| From | "Cormier, Jonathan" <jcormier@criticallink.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH RFC 5/7] ASoC: tlv320aic26: hw_params was unintentionally clearing AIC26 master mode |
| Date | 2015-09-18 22:20 +0200 |
| Message-ID | <qaait-4Bi-13@gated-at.bofh.it> (permalink) |
| References | <qaait-4Bi-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Commit: 5b0959d472c2 "ASoC: tlv320aic26: Use snd_soc_update_bits()" broke setting AIC26_REG_AUDIO_CTRL3 in master mode when fsref happens to be 48000. The master mode bit was getting cleared. Also fix setting AIC26_REG_DAC_GAIN and AIC26_REG_AUDIO_CTRL2 which was broke by same commit. Fixes: 5b0959d472c2 "ASoC: tlv320aic26: Use snd_soc_update_bits()" Signed-off-by: Cormier, Jonathan <jcormier@criticallink.com> --- sound/soc/codecs/tlv320aic26.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/sound/soc/codecs/tlv320aic26.c b/sound/soc/codecs/tlv320aic26.c index 70af361a116c..c3b0a698ea66 100644 --- a/sound/soc/codecs/tlv320aic26.c +++ b/sound/soc/codecs/tlv320aic26.c @@ -138,11 +138,12 @@ static int aic26_hw_params(struct snd_pcm_substream *substream, snd_soc_write(codec, AIC26_REG_PLL_PROG2, reg); /* Audio Control 3 (master mode, fsref rate) */ + reg = 0; if (aic26->master) - reg = 0x0800; + reg |= 0x0800; if (fsref == 48000) - reg = 0x2000; - snd_soc_update_bits(codec, AIC26_REG_AUDIO_CTRL3, 0xf800, reg); + reg |= 0x2000; + snd_soc_update_bits(codec, AIC26_REG_AUDIO_CTRL3, 0x2800, reg); /* Audio Control 1 (FSref divisor) */ reg = wlen | aic26->datfm | (divisor << 3) | divisor; @@ -167,7 +168,7 @@ static int aic26_mute(struct snd_soc_dai *dai, int mute) reg = 0x8080; else reg = 0; - snd_soc_update_bits(codec, AIC26_REG_DAC_GAIN, 0x8000, reg); + snd_soc_update_bits(codec, AIC26_REG_DAC_GAIN, 0x8080, reg); return 0; } @@ -302,7 +303,7 @@ static ssize_t aic26_keyclick_set(struct device *dev, struct aic26 *aic26 = dev_get_drvdata(dev); snd_soc_update_bits(aic26->codec, AIC26_REG_AUDIO_CTRL2, - 0x8000, 0x800); + 0x8000, 0x8000); return count; } -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH RFC 0/7] ASoC: tlv320aic26: Add device tree support and bug fixes "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
[PATCH RFC 2/7] ASoC: tlv320aic26: Fix module autoload "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
[PATCH RFC 7/7] ASoC: tlv320aic26: Change Capture Mute to Capture Switch to match alsa documentation. "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
[PATCH RFC 5/7] ASoC: tlv320aic26: hw_params was unintentionally clearing AIC26 master mode "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
[PATCH RFC 1/7] ASoC: tlv320aic26: Add device tree binding "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
Re: [alsa-devel] [PATCH RFC 1/7] ASoC: tlv320aic26: Add device tree binding Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-09-21 10:40 +0200
Re: [alsa-devel] [PATCH RFC 1/7] ASoC: tlv320aic26: Add device tree binding Jon Cormier <jcormier@criticallink.com> - 2015-09-21 15:10 +0200
[PATCH RFC 6/7] ASoC: tlv320aic26: Add support for DSP_B data format "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
Re: [PATCH RFC 6/7] ASoC: tlv320aic26: Add support for DSP_B data format Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-09-21 08:20 +0200
Re: [PATCH RFC 6/7] ASoC: tlv320aic26: Add support for DSP_B data format Jon Cormier <jcormier@criticallink.com> - 2015-09-21 15:10 +0200
[PATCH RFC 4/7] ASoC: tlv320aic26: Fix regmap by setting reg_defaults and reg_stride "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
[PATCH RFC 3/7] ASoC: tlv320aic26: Make SND_SOC_TLV320AIC26 user-visible "Cormier, Jonathan" <jcormier@criticallink.com> - 2015-09-18 22:20 +0200
csiph-web