]> www.infradead.org Git - users/jedix/linux-maple.git/commit
ASoC: codecs: es8311: add everest es8311 codec support
authorMatteo Martelli <matteomartelli3@gmail.com>
Wed, 22 May 2024 16:46:56 +0000 (18:46 +0200)
committerMark Brown <broonie@kernel.org>
Mon, 27 May 2024 00:30:52 +0000 (01:30 +0100)
commitbaf9899122b0e585a340e2edc685c56c60b9c23e
treefaf8fd822a80891a9474330e843af0fb7ba6775a
parent21d35e335a51bd0b961a4ec07f827712b781e386
ASoC: codecs: es8311: add everest es8311 codec support

Add support for the Everest-semi ES8311 codec.

Everest-semi ES8311 codec is a low-power mono audio codec with I2S audio
interface and I2C control.

Supported features:
* Both master and slave mode. Master clock is optional in slave mode.
* Sample rates from 8KHz to 96KHz.
* Sample formats: S16_LE, S18_3LE, S20_3LE, S24_3LE, S24_LE and S32_LE.
* I2S formats: I2S, LEFT_J, DSP_A, DSP_B.
* BCLK and FSYNC clocks inversion.
* Component suspend/resume.
* ADC, PGA, DAC controls.
* ADC DSP controls: volume, fade (ramp rate), ALC, automute, HPF, EQ.
* DAC DSP controls: volume, fade (ramp rate), DRC, EQ.
* DAPM routes: capture path with input source selection (differential
  MIC/DMIC) and AIF channel source selection; playback path with DAC
  channel source selection.

Limitations:
* Support only for master clocks with a ratio of ADC (or DAC) clock to
  LRCLK equal to 256. This to keep the default ADC and DAC oversampling
  and ADC scale settings. Anyway all 8-96KHz sample rates are supported
  when the ratio of MCLK to sample rate is 32, 64, 128, 256, 384 or 512
  (upper limit due to max MCLK freq of 49.2MHz).
* Coefficients for ADC HPF and ADC/DAC EQ not supported.
* Digital mic supported but not tested.
* S18_3LE, S20_3LE and S24_3LE formats supported but not tested.

Signed-off-by: Matteo Martelli <matteomartelli3@gmail.com>
Link: https://msgid.link/r/20240522164722.954656-3-matteomartelli3@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/Kconfig
sound/soc/codecs/Makefile
sound/soc/codecs/es8311.c [new file with mode: 0644]
sound/soc/codecs/es8311.h [new file with mode: 0644]