- Feb 09, 2023
-
-
Herve Codina authored
The Infineon PEB2466 codec is a programmable DSP-based four channels codec with filters capabilities. It also provides signals as GPIOs. Signed-off-by:
Herve Codina <herve.codina@bootlin.com> Link: https://lore.kernel.org/r/20230206144904.91078-3-herve.codina@bootlin.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jan 31, 2023
-
-
Richard Fitzgerald authored
This adds support for using CS42L42 as a SoundWire device. SoundWire-specifics are kept separate from the I2S implementation as much as possible, aiming to limit the risk of breaking the I2C+I2S support. There are some important differences in the silicon behaviour between I2S and SoundWire mode that are reflected in the implementation: - ASP (I2S) most not be used in SoundWire mode because the two interfaces share pins. - The SoundWire capture (record) port only supports 1 channel. It does not have left-to-right duplication like the ASP. - DP2 can only be prepared if the HP has powered-up. DP1 can only be prepared if the ADC has powered-up. (This ordering restriction does not exist for ASPs.) The SoundWire core port-prepare step is triggered by the DAI-link prepare(). This happens before the codec DAI prepare() or the DAPM sequence so these cannot be used to enable HP/ADC. Instead the HP/ADC enable/disable are done during the port_prep callback. - The SRCs are an integral part of the audio chain but in silicon their power control is linked to the ASP. There is no equivalent power link to SoundWire DPs so the driver must take "manual" control of SRC power. - The SoundWire control registers occupy the lower part of the SoundWire address space so cs42l42 registers are offset by 0x8000 (non-paged) in SoundWire mode. - Register addresses are 8-bit paged in I2C mode but 16-bit unpaged in SoundWire. - Special procedures are needed on register read/writes to (a) ensure that the previous internal bus transaction has completed, and (b) handle delayed read results, when the read value could not be returned within the SoundWire read command. There are also some differences in driver implementation between I2S and SoundWire operation: - CS42L42 I2S does not runtime_suspend, but runtime_suspend/resume support has been added into the driver in SoundWire mode as the most convenient way to power-up the bus manager and to handle the unattach_request condition, though the CS42L42 chip does not itself suspend or resume. - Intel SoundWire host controllers have a low-power clock-stop mode that requires resetting all peripherals when resuming. This means that the interrupt registers will be reset in between the interrupt being generated and the interrupt being handled, and since the interrupt status is debounced, these values may not be accurate immediately, and may cause spurious unplug events before settling. - As in I2S mode, the PLL is only used while audio is active because of clocking quirks in the silicon. For SoundWire the cs42l42_pll_config() is deferred until the DAI prepare(), to allow the cs42l42_bus_config() callback to set the SCLK. Signed-off-by:
Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by:
Stefan Binding <sbinding@opensource.cirrus.com> Reviewed-by:
Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20230127165111.3010960-7-sbinding@opensource.cirrus.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jan 30, 2023
-
-
Weidong Wang authored
The Awinic AW88395 is an I2S/TDM input, high efficiency digital Smart K audio amplifier with an integrated 10.25V smart boost convert Signed-off-by:
Nick Li <liweilei@awinic.com> Signed-off-by:
Bruce zhao <zhaolei@awinic.com> Signed-off-by:
Weidong Wang <wangweidong.a@awinic.com> Link: https://lore.kernel.org/r/20230113055301.189541-5-wangweidong.a@awinic.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
Herve Codina authored
The Renesas IDT821034 codec is four channel PCM codec with on-chip filters and programmable gain setting. It also provides SLIC (Subscriber Line Interface Circuit) signals as GPIOs. Signed-off-by:
Herve Codina <herve.codina@bootlin.com> Link: https://lore.kernel.org/r/20230126085137.375814-3-herve.codina@bootlin.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jan 28, 2023
-
-
KiseokJo authored
Signed-off-by:
KiseokJo <kiseok.jo@irondevice.com> Reported-by:
Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20230126020156.3252-3-kiseok.jo@irondevice.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Nov 16, 2022
-
-
Shuming Fan authored
This is the initial amplifier driver for rt1318 SDCA version. Signed-off-by:
Shuming Fan <shumingf@realtek.com> Link: https://lore.kernel.org/r/20221108092727.13011-1-shumingf@realtek.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Sep 19, 2022
-
-
Martin Povišer authored
The CS42L83 part is a headphone jack codec found in recent Apple machines. It is a publicly undocumented part but as far as can be told it is identical to CS42L42 except for two points: * The chip ID is different. * Of those registers for which we have a default value in the existing CS42L42 kernel driver, one register (MCLK_CTL) differs in its reset value on CS42L83. To address those two points (and only those), add to the CS42L42 driver a separate CS42L83 front. Signed-off-by:
Martin Povišer <povik+lin@cutebit.org> Link: https://lore.kernel.org/r/20220915094444.11434-10-povik+lin@cutebit.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
Richard Fitzgerald authored
Split the I2C bus driver definition and probe()/remove() into a separate module so that a SoundWire build of CS42L42 support does not have a spurious dependency on I2C. Signed-off-by:
Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by:
Martin Povišer <povik+lin@cutebit.org> Link: https://lore.kernel.org/r/20220915094444.11434-8-povik+lin@cutebit.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Aug 16, 2022
-
-
Zhu Ning authored
The ES8326 codec is not compatible with ES8316 and requires a dedicated driver. ------ v6 remove rate 96000 remove HEX suffix Signed-off-by:
David Yang <yangxiaohua@everest-semi.com> Signed-off-by:
Zhu Ning <zhuning@everest-semi.com> Link: https://lore.kernel.org/r/20220816024456.4475-2-zhuning0077@gmail.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Aug 15, 2022
-
-
Matt Flax authored
The src4xxx keyword is used for future capability to integrate other codecs similar to the src4392 to the same code base. Signed-off-by:
Matt Flax <flatmax@flatmax.com> Link: https://lore.kernel.org/r/20220810013213.1544645-1-flatmax@flatmax.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jul 08, 2022
-
-
Raphael-Xu authored
1.update Kconfig and Makefile 2.add tas2780.c and tas2780.h Signed-off-by:
Raphael-Xu <13691752556@139.com> Link: https://lore.kernel.org/r/20220707123343.2403-1-13691752556@139.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jun 29, 2022
-
-
Srinivas Kandagatla authored
This patch adds support to WSA8830/WSA8812/WSA8835 Class-D Smart Speaker Amplifier. This Amplifier is primarily interfaced with SoundWire. This patch is tested on SM8450 MTP Board. Signed-off-by:
Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20220629090644.67982-3-srinivas.kandagatla@linaro.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jun 06, 2022
-
-
Cezary Rojewski authored
Add generic ASoC equivalent of ALSA HD-Audio codec. This codec is designed to follow HDA_DEV_LEGACY convention. Driver wrapps existing hda_codec.c handlers to prevent code duplication within the newly added code. Number of DAIs created is dependent on capabilities exposed by the codec itself. Because of this, single solution can be applied to support every single HD-Audio codec type. At the same time, through the ASoC topology, platform drivers may limit the number of endpoints available to the userspace as codec driver exposes BE DAIs only. Both hda_codec_probe() and hda_codec_remove() declare their expectations on device's usage_count and suspended-status. This is to catch any unexpected behavior as PM-related code for HD-Audio has been changing quite a bit throughout the years. In order for codec DAI list to reflect its actual PCM capabilities, PCMs need to be built and that can only happen once codec device is constructed. To do that, a valid component->card->snd_card pointer is needed. Said pointer will be provided by the framework once all card components are accounted for and their probing can begin. Usage of "binder" BE DAI solves the problem - codec can be listed as one of HD-Audio card components without declaring any actual BE DAIs statically. Relation with hdac_hda: Addition of parallel solution is motivated by behavioral differences between hdac_hda.c and its legacy equivalent found in sound/pci/hda e.g.: lack of dynamic, based on codec capabilities, resource allocation and high cost of removing such differences on actively used targets. Major goal of codec driver presented here is to follow HD-Audio legacy behavior in 1:1 fashion by becoming a wrapper. Doing so increases code coverage of the legacy code and reduces the maintenance cost for both solutions. Signed-off-by:
Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220511162403.3987658-3-cezary.rojewski@intel.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Apr 26, 2022
-
-
Ryan Lee authored
This series of patches adds support for Analog Devices MAX98396 mono amplifier with IV sense. The device provides a PCM interface for audio data and a standard I2C interface for control data communication. This driver also supports MAX98397 which is a variant of MAX98396 with wide input supply range. Signed-off-by:
Ryan Lee <ryan.lee.analog@gmail.com> Reported-by:
kernel test robot <lkp@intel.com> Link: https://lore.kernel.org/r/20220423021558.1773598-1-ryan.lee.analog@gmail.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Apr 06, 2022
-
-
Stephen Kitt authored
The rt1016 driver wasn't listed in Kconfig and Makefile, which AFAICT means it isn't ever built. This patch adds the appropriate entries to Kconfig and Makefile. Signed-off-by:
Stephen Kitt <steve@sk2.org> Link: https://lore.kernel.org/r/20220405171158.2168762-1-steve@sk2.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Apr 05, 2022
-
-
James Schulman authored
The CS35L45 is a 15 V Boosted Mono Class D Amplifier with DSP Speaker Protection and Adaptive Battery Management. This initial driver provides standard non-boosted audio operation without the DSP. Signed-off-by:
James Schulman <james.schulman@cirrus.com> Signed-off-by:
Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220405135419.1230088-6-rf@opensource.cirrus.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Apr 04, 2022
-
-
Mark Brown authored
Placing both the I2C and SPI code in the same module causes problems with mixes of modular and non-modular builds of the buses so it's generally bad practice. As with other drivers split the bus code out of the WM8731 driver into separate modules. Signed-off-by:
Mark Brown <broonie@kernel.org> Acked-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325153121.1598494-6-broonie@kernel.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Mar 07, 2022
-
-
Jonathan Albrieux authored
The Awinic AW8738 is a simple audio amplifier using a single GPIO. The main difference to simple-amplifier is that there is a "one-wire pulse control" that allows configuring the amplifier to one of a few pre-defined modes. This can be used to configure the speaker-guard function (primarily the power limit for the amplifier). Add a simple driver that allows setting it up in the device tree with a specified mode number. Signed-off-by:
Jonathan Albrieux <jonathan.albrieux@gmail.com> Co-developed-by:
Stephan Gerhold <stephan@gerhold.net> Signed-off-by:
Stephan Gerhold <stephan@gerhold.net> Link: https://lore.kernel.org/r/20220304102452.26856-3-stephan@gerhold.net Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Feb 28, 2022
-
-
Srinivasa Rao Mandadapu authored
Add support for enabling required power domains in digital macro codecs. macro and dcodec power domains are being requested as clocks by HLOS in ADSP based architectures and ADSP internally handling as powerdomains. In ADSP bypass case need to handle them as power domains explicitly. Signed-off-by:
Srinivasa Rao Mandadapu <quic_srivasam@quicinc.com> Co-developed-by:
Venkata Prasad Potturu <quic_potturu@quicinc.com> Signed-off-by:
Venkata Prasad Potturu <quic_potturu@quicinc.com> Reported-by:
kernel test robot <lkp@intel.com> Link: https://lore.kernel.org/r/1645898959-11231-2-git-send-email-quic_srivasam@quicinc.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jan 24, 2022
-
-
Daniel Beer authored
The Texas Instruments TAS5805M is a class D audio amplifier with an integrated DSP. DSP configuration is supplied in a firmware image specified through a device-tree attribute. These register writes set up application-specific DSP settings and are expected to be generated using TI's PPC3 tool. Signed-off-by:
Daniel Beer <daniel.beer@igorinstitute.com> Link: https://lore.kernel.org/r/b82fac1d21a33a5f57a5819eaf37c31f5c86eb65.1642298336.git.daniel.beer@igorinstitute.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Dec 31, 2021
-
-
Lucas Tanure authored
To support CS35L41 in HDA systems the HDA driver for CS35L41 would have to duplicate some functions that already exist on ASoC driver So instead of duplicate the code, use the new lib source as a shared resource for both ASoC and HDA Also, change the way CONFIG_SND_SOC_CS35L41 is selected, as reported by Intel Kernel test robot, it is possible to build SND_SOC_CS35L41_SPI/I2C without the main driver, which would lead to build failures. Signed-off-by:
Lucas Tanure <tanureal@opensource.cirrus.com> Reported-by:
kernel test robot <lkp@intel.com> Link: https://lore.kernel.org/r/20211217115708.882525-2-tanureal@opensource.cirrus.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Dec 21, 2021
-
-
Vincent Knecht authored
AK4375 is a 32-bit stereo DAC with headphones amplifier. There's no documentation for it on akm.com, and only a brief datasheet can be found floating on the internets [1]. Thanks to Oriane BAYERD <obayerd@eurocomposant.fr> for finally answering my inquiries through akm.com, if only to tell me that this chip is EOL following AKM factory burning in october 2020 and thus no detailed documentation is available anymore... AK4331 is advertised [2] as pin and register compatible with AK4375 so some scraps of its datasheet were used and this driver might be used as a base for it, but this is totally untested. So this driver is mainly based on downstream code [3] and [4] by Hu Jin from AKM (no known email). Tested on msm8916-alcatel-idol347 and msm8939-alcatel-idol3, which both use PLL driven clock with bypass of SRC (sample rate converter), so only this setup is supported for now. [1] https://datasheetspdf.com/pdf-file/1400317/AKM/AK4375A/1 [2] https://www.akm.com/content/dam/documents/products/audio/audio-dac/ak4331ecb/ak4331ecb-en-datasheet.pdf [3] https://github.com/msm8916-mainline/android_kernel_qcom_msm8916/blob/alcatel-idol347/sound/soc/codecs/idol347/ak4375.c [4] https://github.com/msm8916-mainline/android_kernel_qcom_msm8916/blob/alcatel-idol347/sound/soc/codecs/ak4375.c Signed-off-by:
Vincent Knecht <vincent.knecht@mailoo.org> Link: https://lore.kernel.org/r/20211220193725.2650356-2-vincent.knecht@mailoo.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Dec 20, 2021
-
-
Ricard Wanderlof authored
New codec driver for Texas Instruments TLV320ADC3001 and TLV320ADC3101 audio ADCs. Signed-off-by:
Ricard Wanderlof <ricardw@axis.com> Link: https://lore.kernel.org/r/alpine.DEB.2.21.2112151801370.27889@lap5cg0092dnk.se.axis.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Nov 26, 2021
-
-
Lucas Tanure authored
Can't link I2C and SPI to the same binary, better to move CS35L41 to 3 modules approach. And instead of exposing cs35l41_reg, volatile_reg, readable_reg and precious_reg arrays, move cs35l41_regmap_i2c/spi to new module and expose it. Signed-off-by:
Lucas Tanure <tanureal@opensource.cirrus.com> Link: https://lore.kernel.org/r/20211125143501.7720-1-tanureal@opensource.cirrus.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Oct 27, 2021
-
-
George Song authored
add max98520 audio amplifier driver Signed-off-by:
George Song <george.song@maximintegrated.com> Link: https://lore.kernel.org/r/20211027001431.363-2-george.song@maximintegrated.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Oct 13, 2021
-
-
ChiYuan Huang authored
Add Richtek rt9120 audio amplifier support. Signed-off-by:
ChiYuan Huang <cy_huang@richtek.com> Link: https://lore.kernel.org/r/1634088519-995-3-git-send-email-u0084500@gmail.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
Mark Brown authored
This drops the rt9210 support due to a race with a new version being sent out for some incremental changes. Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Oct 08, 2021
-
-
ChiYuan Huang authored
Add Richtek rt9120 audio amplifier support. Signed-off-by:
ChiYuan Huang <cy_huang@richtek.com> [Fix a Gain->Volume -- broonie] Message-Id: <1633668612-25524-3-git-send-email-u0084500@gmail.com> Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Oct 02, 2021
-
-
Seven Lee authored
The driver is for codec NAU88L21 of Nuvoton Technology Corporation. The NAU88L21 is an ultra-low power high performance audio codec that supports both analog and digital audio functions. Signed-off-by:
Seven Lee <wtli@nuvoton.com> Link: https://lore.kernel.org/r/20211001103108.3297848-1-wtli@nuvoton.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Sep 13, 2021
-
-
Derek Fang authored
This is an initial codec driver for Realtek ALC5682I-VS codec. Signed-off-by:
Derek Fang <derek.fang@realtek.com> Signed-off-by: Derek Fang <derek.fang@realtek.com<mailto:derek.fang@realtek.com>> Link: https://lore.kernel.org/r/20210831130258.19286-1-derek.fang@realtek.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
David Rhodes authored
SoC Audio driver for the Cirrus Logic CS35L41 amplifier Signed-off-by:
David Rhodes <drhodes@opensource.cirrus.com> Tested-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20210907225719.2018115-2-drhodes@opensource.cirrus.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jul 22, 2021
-
-
Arnd Bergmann authored
With SND_SOC_ALL_CODECS=y and SND_SOC_WCD938X_SDW=m, there is a link error from a reverse dependency, since the built-in codec driver calls into the modular soundwire back-end: x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_codec_free': wcd938x.c:(.text+0x2c0): undefined reference to `wcd938x_sdw_free' x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_codec_hw_params': wcd938x.c:(.text+0x2f6): undefined reference to `wcd938x_sdw_hw_params' x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_codec_set_sdw_stream': wcd938x.c:(.text+0x332): undefined reference to `wcd938x_sdw_set_sdw_stream' x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_tx_swr_ctrl': wcd938x.c:(.text+0x23de): undefined reference to `wcd938x_swr_get_current_bank' x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_bind': wcd938x.c:(.text+0x2579): undefined reference to `wcd938x_sdw_device_get' x86_64-linux-ld: wcd938x.c:(.text+0x25a1): undefined reference to `wcd938x_sdw_device_get' x86_64-linux-ld: wcd938x.c:(.text+0x262a): undefined reference to `__devm_regmap_init_sdw' Work around this using two small hacks: An added Kconfig dependency prevents the main driver from being built-in when soundwire support itself is a loadable module to allow calling devm_regmap_init_sdw(), and a Makefile trick links the wcd938x-sdw backend as built-in if needed to solve the dependency between the two modules. Fixes: 04544222 ("ASoC: codecs: wcd938x: add audio routing and Kconfig") Signed-off-by:
Arnd Bergmann <arnd@arndb.de> Link: https://lore.kernel.org/r/20210721150510.1837221-1-arnd@kernel.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jul 14, 2021
-
-
Pierre-Louis Bossart authored
To test the host controller and bus management code, it is currently required to have a physical SoundWire peripheral attached to the bus. To help with pre-silicon or early hardware enablement, it would be very useful to have a SoundWire 'mockup' device that is exposed in platform firmware but does not drive any signal on the bus. This is different to the existing ASoC 'dummy' codec uses for I2S/TDM, the SoundWire spec makes it clear that a device that is not attached to the bus is not permitted to interact with the bus, be it for command/control or data. This patch exposes a 'mockup' device, with a minimalist driver, with 4 partID values reserved by Intel for such test configurations. The mockup device exposes one full-duplex DAI based on 2 ports (DP1 for playback and DP8 for capture). The capture data port is just virtual, such a mockup device is prevented by the SoundWire specification from presenting any data generated by a Source port without being Attached. All the callbacks exposed by the SoundWire Slave interface are populated, even if they just return immediately. This is intentional to describe what a minimal codec driver should do and implement and help new codec vendors provide support for their devices. Signed-off-by:
Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by:
Rander Wang <rander.wang@intel.com> Signed-off-by:
Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://lore.kernel.org/r/20210714032209.11284-2-yung-chuan.liao@linux.intel.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jun 14, 2021
-
-
Srinivas Kandagatla authored
This patch adds audio routing for both playback and capture and Makefile and Kconfigs changes for wcd938x Signed-off-by:
Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20210609090943.7896-10-srinivas.kandagatla@linaro.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jun 04, 2021
-
-
Srinivas Kandagatla authored
Most new Qualcomm WCD codecs support MBHC(Multi Button Headset Control) via ADC. This patchset adds support to Common parts of this MBHC support so that WCD codecs need not duplicate them. To do that codec exposes set of register fields and callbacks to this common driver to control it. Signed-off-by:
Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20210604115230.23259-3-srinivas.kandagatla@linaro.org Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Jun 01, 2021
-
-
Chris Morgan authored
Add support for the Rockchip rk817 audio codec integrated into the rk817 PMIC. This is based on the sources provided by Rockchip from their BSP kernel. Signed-off-by:
Chris Morgan <macromorgan@hotmail.com> Tested-by:
Maciej Matuszczyk <maccraft123mc@gmail.com> Reviewed-by:
Mark Brown <broonie@kernel.org> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
- May 24, 2021
-
-
Stephan Gerhold authored
NXP's TFA98xx (now part of Goodix) are fairly popular speaker amplifiers used in many smartphones and tablets. Most of them are sold as "smart amplifiers" with built-in "CoolFlux DSP" that is used for volume control, plus a "sophisticated speaker-boost and protection algorithm". Unfortunately, they are also almost entirely undocumented. The short datasheets (e.g. [1] for TFA9897) describe the available features, but do not provide any information about the registers or how to use the "CoolFlux DSP". The amplifiers are most often configured through proprietary userspace libraries. There are also some (rather complex) kernel drivers (e.g. [2]) but even those rely on obscure firmware blobs for configuration (so-called "containers"). They seem to contain different "profiles" with tuned speaker settings, sample rates and volume steps (which would be better exposed as separate ALSA mixers). The format of the firmware files seems to have changed a lot over the time, so it's not even possible to simply re-use the firmware originally provided by the vendor. Overall, it seems close to impossible to develop a proper mainline driver for these amplifiers that could make proper use of the built-in DSP. This commit implements a compromise: At least the TFA1 family of the TFA98xx amplifiers (usually called TFA989x) provide a way to *bypass* the DSP using a special register sequence. The register sequence can be found in similar variations in the kernel drivers from lots of vendors e.g. in [3] and was probably mainly used for factory testing. With the DSP bypassed, the amplifier acts mostly like a dumb standard speaker amplifier, without (hardware) volume control. However, the setup is much simpler and it works without any obscure firmware. This driver implements the DSP bypass combined with chip-specific initialization sequences adapted from [2]. Only TFA9895 is supported in this initial commit. Except for the lack of volume control I can not hear any difference with or without the DSP, it works just fine. This driver allows the speaker to work on mainline Linux running on the Samsung Galaxy A3/A5 (2015) [TFA9895] and Alcatel Idol 3 [TFA9897]. TFA9897 support will be added in separate patch set later. [1]: https://product.goodix.com/en/docview/TFA9897%20SDS_Rev.3.1?objectId=47&objectType=document&version=78 [2]: https://source.codeaurora.org/external/mas/tfa98xx [3]: https://github.com/sonyxperiadev/kernel/blob/57b5050e340f40a88e1ddb8d16fd9adb44418923/sound/soc/codecs/tfa98xx.c#L1422-L1462 Signed-off-by:
Stephan Gerhold <stephan@gerhold.net> Link: https://lore.kernel.org/r/20210513104129.36583-2-stephan@gerhold.net Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Apr 07, 2021
-
-
Jiri Prchal authored
Added SPI support. Signed-off-by:
Jiri Prchal <jiri.prchal@aksignal.cz> Link: https://lore.kernel.org/r/20210406142439.102396-5-jiri.prchal@aksignal.cz Signed-off-by:
Mark Brown <broonie@kernel.org>
-
Jiri Prchal authored
Moved I2C related staff to separated source file. Signed-off-by:
Jiri Prchal <jiri.prchal@aksignal.cz> Link: https://lore.kernel.org/r/20210406142439.102396-4-jiri.prchal@aksignal.cz Signed-off-by:
Mark Brown <broonie@kernel.org>
-
- Mar 25, 2021
-
-
Argus Lin authored
MT6359 audio codec supports jack detection feature, adds MT6359 accdet driver to support jack plugged detection and key detection. Signed-off-by:
Argus Lin <argus.lin@mediatek.com> Link: https://lore.kernel.org/r/1615383186-18500-3-git-send-email-argus.lin@mediatek.com Signed-off-by:
Mark Brown <broonie@kernel.org>
-