summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/adau17x1.h
diff options
context:
space:
mode:
authorRicard Wanderlof <ricard.wanderlof@axis.com>2017-09-07 15:31:38 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-11-08 10:06:27 +0100
commit97d64b7f2fdf945c40c5dc2004defec5f260cb6d (patch)
treefd530468b081bf86f6b9f864ee29b9a3bc5d91db /sound/soc/codecs/adau17x1.h
parent618b930317fbea5561f9e5b07b26468d595ec110 (diff)
ASoC: adau17x1: Workaround for noise bug in ADC
commit 1e6f4fc06f6411adf98bbbe7fcd79442cd2b2a75 upstream. The ADC in the ADAU1361 (and possibly other Analog Devices codecs) exhibits a cyclic variation in the noise floor (in our test setup between -87 and -93 dB), a new value being attained within this range whenever a new capture stream is started. The cycle repeats after about 10 or 11 restarts. The workaround recommended by the manufacturer is to toggle the ADOSR bit in the Converter Control 0 register each time a new capture stream is started. I have verified that the patch fixes this problem on the ADAU1361, and according to the manufacturer toggling the bit in question in this manner will at least have no detrimental effect on other chips served by this driver. Signed-off-by: Ricard Wanderlof <ricardw@axis.com> Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'sound/soc/codecs/adau17x1.h')
-rw-r--r--sound/soc/codecs/adau17x1.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/soc/codecs/adau17x1.h b/sound/soc/codecs/adau17x1.h
index e13583e6ff56..6b46461cdc03 100644
--- a/sound/soc/codecs/adau17x1.h
+++ b/sound/soc/codecs/adau17x1.h
@@ -123,5 +123,7 @@ bool adau17x1_has_dsp(struct adau *adau);
#define ADAU17X1_CONVERTER0_CONVSR_MASK 0x7
+#define ADAU17X1_CONVERTER0_ADOSR BIT(3)
+
#endif