summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2020-03-27ASoC: intel: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto34-135/+135
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87r1xjir7a.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: img: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto2-2/+2
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87sghzir7m.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: generic: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto1-6/+6
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87tv2fir7y.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: fsl: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto15-43/+43
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87v9mvir89.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: dwc: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto1-1/+1
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87wo7bir8j.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: cirrus: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto2-4/+4
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87y2rrir8s.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: bcm: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto2-19/+19
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87zhc7ir94.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: au1x: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto4-4/+4
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/871rpjk5tw.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: atmel: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto6-7/+7
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87369zk5ul.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: amd: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointerKuninori Morimoto3-6/+6
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/874kufk5uu.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-27ASoC: soc-core: add asoc_rtd_to_cpu/codec() macroKuninori Morimoto1-0/+4
Now, snd_soc_pcm_runtime supports multi cpu_dai/codec_dai. It still has cpu_dai/codec_dai for single DAI, and has cpu_dais/codec_dais for multi DAIs. dais = [][][][][][][][][][][][][][][][][][] ^cpu_dais ^codec_dais |--- num_cpus ---|--- num_codecs --| /* for multi DAIs */ rtd->cpu_dais = &rtd->dais[0]; rtd->codec_dais = &rtd->dais[dai_link->num_cpus]; /* for single DAI */ rtd->cpu_dai = rtd->cpu_dais[0]; rtd->codec_dai = rtd->codec_dais[0]; But, these can be replaced by dais. This patch adds asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/875zevk5va.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26Merge series "ASoC: rt1308-sdw: configure amplifier with set_tdm_slot()" ↵Mark Brown2-4/+36
from Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>: When two (or more) amplifiers are on the same link, the integrator may: a) assign dedicated slots for each of the amplifiers. b) provide the same configuration to all amplifiers, and rely on additional controls/processing in the amplifier to generate different outputs. case a) was the initial direction for SoundWire and is required for amplifiers with limited capabilities, but to deal with orientation or 'posture' changes it's easier to implement case b) when the amplifier can deal with multiple channels. This patchset suggest the use of the set_tdm_slot() API to define which of the channels will be consumed by what amplifiers. This maps well with SoundWire's 'ChannelEnable' registers. The notion of slot_width is however irrelevant here and ignored, and SoundWire ports are typically single direction, so only one of the two masks shall be used. Pierre-Louis Bossart (2): ASoC: rt1308-sdw: add set_tdm_slot() support ASoC: rt1308-sdw: use slot and rx_mask to configure stream sound/soc/codecs/rt1308-sdw.c | 38 +++++++++++++++++++++++++++++++---- sound/soc/codecs/rt1308-sdw.h | 2 ++ 2 files changed, 36 insertions(+), 4 deletions(-) -- 2.20.1
2020-03-26Merge series "ASoC: Intel: machine driver updates" from Pierre-Louis Bossart ↵Mark Brown8-31/+178
<pierre-louis.bossart@linux.intel.com>: One correction for GeminiLake and 2 additional machine drivers for Chromebooks. Curtis Malainey (1): ASoC: Intel: Make glk+rt5682 echo ref dynamic Sathyanarayana Nujella (2): ASoC: Intel: sof_rt5682: Add support for tgl-max98373-rt5682 ASoC: Intel: common: Add mach table for tgl-max98373-rt5682 Yong Zhi (1): ASoC: intel: sof_da7219_max98373: Add speaker switch sound/soc/intel/boards/Kconfig | 1 + sound/soc/intel/boards/Makefile | 2 +- sound/soc/intel/boards/glk_rt5682_max98357a.c | 1 + sound/soc/intel/boards/sof_da7219_max98373.c | 67 +++++++++------- sound/soc/intel/boards/sof_maxim_common.c | 80 +++++++++++++++++++ sound/soc/intel/boards/sof_maxim_common.h | 24 ++++++ sound/soc/intel/boards/sof_rt5682.c | 21 +++++ .../intel/common/soc-acpi-intel-tgl-match.c | 13 +++ 8 files changed, 178 insertions(+), 31 deletions(-) create mode 100644 sound/soc/intel/boards/sof_maxim_common.c create mode 100644 sound/soc/intel/boards/sof_maxim_common.h -- 2.20.1
2020-03-26Merge series "ASoC: SOF: cleanups and improvements" from Pierre-Louis ↵Mark Brown5-13/+69
Bossart <pierre-louis.bossart@linux.intel.com>: Couple of small patches to improve error handling, inits, logs. Hope we can have this for 5.7? Guennadi Liakhovetski (2): ASoC: SOF: (cosmetic) use for_each_pcm_streams() in sof_dai_load() ASoC: SOF: fix uninitialised "work" with VirtIO Kai Vehmanen (2): ASoC: SOF: Intel: hda: do not leave clock gating off upon error ASoC: SOF: Intel: hda: call codec wake at chip init Ranjani Sridharan (1): ASoC: SOF: Intel: hda: Improve DSP state logging sound/soc/sof/intel/hda-ctrl.c | 15 +++++++++--- sound/soc/sof/intel/hda-dsp.c | 43 ++++++++++++++++++++++++++++++++-- sound/soc/sof/pcm.c | 4 +--- sound/soc/sof/sof-audio.h | 3 +++ sound/soc/sof/topology.c | 17 ++++++++++---- 5 files changed, 69 insertions(+), 13 deletions(-) -- 2.20.1
2020-03-26ASoC: pxa: Enable AC'97 bus support for PXA machinesMark Brown1-0/+14
The AC'97 based PXA machines currently don't build reliably as they don't ensure that an AC'97 bus is built, causing at least eseries_pxa_defconfig to fail to build. Add selects to fix this. Reported-by: KernelCI <bot@kernelci.org> Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20200326180116.21375-1-broonie@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: pxa: Select regmap from AC'97 machinesMark Brown1-0/+8
regmap needs to be selected by users which for machine drivers that select AC'97 CODEC drivers means that we need to also select regmap to ensure that the CODEC driver will build if nothing else enables regmap as is likely for such systems. Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20200326151053.40806-1-broonie@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: rt1308-sdw: use slot and rx_mask to configure streamPierre-Louis Bossart1-4/+11
If the DAI was configured with a set_tdm_slots() call, use the information. A platform or machine driver may configure each amplifier to extract different bitSlots from the frame, or extract the same data and use processing to generate the relevant output. The latter case is easier to handle in case of orientation changes. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200325212905.28145-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: rt1308-sdw: add set_tdm_slot() supportPierre-Louis Bossart2-0/+25
Add ability to select which of the channels is used, or both, in case two RT1308 amplifiers are located on the same link. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200325212905.28145-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: SOF: Intel: hda: call codec wake at chip initKai Vehmanen1-0/+7
Further align HDA init sequence to the legacy non-DSP HDA driver by calling snd_hdac_set_codec_wakeup() during the chip init sequence. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20200325211233.27394-6-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: SOF: Intel: hda: do not leave clock gating off upon errorKai Vehmanen1-3/+5
The misc clock gating (MISCBDCGE) is disabled for controller reset and reenabled once reset is complete. Fix the case when error happens during reset, and clock gating is left disabled. The clock gating should be reenabled also in this case. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20200325211233.27394-5-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: SOF: fix uninitialised "work" with VirtIOGuennadi Liakhovetski3-4/+9
In the VirtIO case the sof_pcm_open() function isn't called on the host during guest streaming, which then leaves "work" structures uninitialised. However it is then used to handle position update messages from the DSP. Move their initialisation to immediately after allocation of the containing structure. Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20200325211233.27394-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: SOF: (cosmetic) use for_each_pcm_streams() in sof_dai_load()Guennadi Liakhovetski1-5/+8
Use for_each_pcm_streams() to enumerate streams in sof_dai_load() instead of doing that manually. Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20200325211233.27394-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: SOF: Intel: hda: Improve DSP state loggingRanjani Sridharan1-2/+41
Improve the DSP power state logs with the state names instead of values. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200325211233.27394-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: Intel: common: Add mach table for tgl-max98373-rt5682Sathyanarayana Nujella1-0/+13
Update tgl mach table with: Maxim98373 Amp and ALC5682 hp codec. Both of the codecs are on I2S bus. Signed-off-by: Jairaj Arava <jairaj.arava@intel.com> Signed-off-by: Sathyanarayana Nujella <sathyanarayana.nujella@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200325213245.28247-5-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: Intel: sof_rt5682: Add support for tgl-max98373-rt5682Sathyanarayana Nujella5-1/+127
This patch does the below: 1. Adds the driver data and updates quirk info for TGL with Max98373 speaker amp and ALC5682 headset codec. 2. Added max98373 speaker related code to common file for re-use. Signed-off-by: Jairaj Arava <jairaj.arava@intel.com> Signed-off-by: Sathyanarayana Nujella <sathyanarayana.nujella@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200325213245.28247-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: intel: sof_da7219_max98373: Add speaker switchYong Zhi1-30/+37
Add "Spk Switch" and associated widget, route to max98360a speaker amp for power saving, also remove the speaker_amp_init() callback with complete separated tables for max98373 and max98360a. Signed-off-by: Bhat, Uday M <uday.m.bhat@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Yong Zhi <yong.zhi@intel.com> Link: https://lore.kernel.org/r/20200325213245.28247-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-26ASoC: Intel: Make glk+rt5682 echo ref dynamicCurtis Malainey1-0/+1
Without the dynamic flag to allow runtime routing, the card cannot probe on chromebooks because SOF is constantly waiting for the link. Adding flag back to allow upstream kernels to work on rt5682 based chromebooks since SOF can now ignore the hard coded front end. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200325213245.28247-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-25ASoC: mchp-i2s-mcc: make signed 1 bit bitfields unsignedColin Ian King1-4/+4
The signed 1 bit bitfields should be unsigned, so make them unsigned. Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Link: https://lore.kernel.org/r/20200325132913.110115-1-colin.king@canonical.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-24ASoC: Convert jz4740-i2s doc to YAMLPaul Cercueil2-23/+92
Convert the textual binding documentation for the AIC (AC97/I2S Controller) of Ingenic SoCs to a YAML schema, and add the new compatible strings in the process. Signed-off-by: Paul Cercueil <paul@crapouillou.net> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20200306222931.39664-1-paul@crapouillou.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-24ASoC: jz4740-i2s: Add support for the JZ4770Paul Cercueil1-3/+10
Before the JZ4770, the playback and capture sampling rates had to match. The JZ4770 supports independent sampling rates for both. Signed-off-by: Paul Cercueil <paul@crapouillou.net> Link: https://lore.kernel.org/r/20200306222931.39664-6-paul@crapouillou.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-24ASoC: jz4740-i2s: Add support for the JZ4760Paul Cercueil1-9/+12
The change of offset for the {rx,tx}_threshold fields in the conf register predates the JZ4780, and was first introduced in the JZ4760. Signed-off-by: Paul Cercueil <paul@crapouillou.net> Link: https://lore.kernel.org/r/20200306222931.39664-5-paul@crapouillou.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-24dt-bindings: sound: rockchip-i2s: add #sound-dai-cells propertyJohan Jonker1-0/+5
'#sound-dai-cells' is required to properly interpret the list of DAI specified in the 'sound-dai' property, so add them to 'rockchip-i2s.yaml' Signed-off-by: Johan Jonker <jbx6244@gmail.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20200324094149.6904-2-jbx6244@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-24dt-bindings: sound: convert rockchip i2s bindings to yamlJohan Jonker2-49/+106
Current dts files with 'i2s' nodes are manually verified. In order to automate this process rockchip-i2s.txt has to be converted to yaml. Signed-off-by: Johan Jonker <jbx6244@gmail.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20200324094149.6904-1-jbx6244@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-24ASoC: wm8974: remove unused variablesYueHaibing1-8/+0
sound/soc/codecs/wm8974.c:200:38: warning: wm8974_aux_boost_controls defined but not used [-Wunused-const-variable=] sound/soc/codecs/wm8974.c:204:38: warning: wm8974_mic_boost_controls defined but not used [-Wunused-const-variable=] commit 8a123ee2a46d ("ASoC: WM8974 DAPM cleanups") left behind this, remove them. Signed-off-by: YueHaibing <yuehaibing@huawei.com> Link: https://lore.kernel.org/r/20200324070615.16248-1-yuehaibing@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-23Merge series "Support built-in Mic on Tegra boards that use WM8903" from ↵Mark Brown2-0/+19
Dmitry Osipenko <digetx@gmail.com>: Hello, This small series adds audio route for built-in microphone on NVIDIA Tegra boards that use WM8903 CODEC. In particular this is needed in order to unmute internal microphone on Acer A500 tablet device. I'm planning to send out the device tree for the A500 for 5.8, so will be nice to get the microphone sorted out. Please review and apply, thanks in advance. Dmitry Osipenko (2): dt-bindings: sound: tegra-wm8903: Document built-in microphone audio source ASoC: tegra: tegra_wm8903: Support DAPM events for built-in microphone .../sound/nvidia,tegra-audio-wm8903.txt | 1 + sound/soc/tegra/tegra_wm8903.c | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) -- 2.25.1
2020-03-23ASoC: rt5682: Add the descriptions for the DMIC clock rate and delay settingsOder Chiou1-0/+6
The patch adds the descriptions for the DMIC clock rate and delay settings. Signed-off-by: Oder Chiou <oder_chiou@realtek.com> Link: https://lore.kernel.org/r/20200323082547.7898-3-oder_chiou@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-23ASoC: rt5682: Add a property for DMIC delayOder Chiou2-1/+12
The patch adds a property for DMIC delay (ms) to avoid pop noise and changes the default delay setting. Signed-off-by: Oder Chiou <oder_chiou@realtek.com> Link: https://lore.kernel.org/r/20200323082547.7898-2-oder_chiou@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-23ASoC: rt5682: Add a property for DMIC clock rateOder Chiou2-2/+8
The patch adds a property for DMIC clock rate (hz) and changes the default to the common optimize DMIC clock rate. Signed-off-by: Oder Chiou <oder_chiou@realtek.com> Link: https://lore.kernel.org/r/20200323082547.7898-1-oder_chiou@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-23ASoC: MT6660: make spdxcheck.py happyLukas Bulwahn1-1/+1
The SPDX-License-Identifier shall not be suffixed with anything further. This makes ./scripts/spdxcheck.py complain: sound/soc/codecs/mt6660.c: 1:36 Invalid token: // Clean up SPDX-License-Identifier line to make spdxcheck.py happy. Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com> Link: https://lore.kernel.org/r/20200321114022.8545-1-lukas.bulwahn@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-23ASoC: tegra-wm8903: Document built-in microphone audio sourceDmitry Osipenko1-0/+1
The internal microphone source is needed in order to be able to describe the hardware audio routing for devices that have the built-in microphone in addition to the external Mic Jack. Signed-off-by: Dmitry Osipenko <digetx@gmail.com> Acked-by: Stephen Warren <swarren@nvidia.com> Acked-by: Jon Hunter <jonathanh@nvidia.com> Link: https://lore.kernel.org/r/20200320205504.30466-2-digetx@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-23ASoC: tegra: tegra_wm8903: Support DAPM events for built-in microphoneDmitry Osipenko1-0/+18
The enable-GPIO needs to be toggled on a DAPM event in order to turn microphone ON/OFF, otherwise microphone won't work. Signed-off-by: Dmitry Osipenko <digetx@gmail.com> Acked-by: Stephen Warren <swarren@nvidia.com> Acked-by: Jon Hunter <jonathanh@nvidia.com> Link: https://lore.kernel.org/r/20200320205504.30466-3-digetx@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-20ASoC: soc-core: Merge CPU/Codec for soc_dai_pcm_new()Kuninori Morimoto1-14/+9
Now CPU/Codec DAIs are alias for dais. Thus, we can directly use for_each_rtd_dais() macro for soc_dai_pcm_new(). This patch merge CPU/Codec for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87r1xsolen.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-20ASoC: soc-pcm: Merge for_each_rtd_cpu/codec_dais()Kuninori Morimoto1-236/+75
Now we can use for_each_rtd_dais(). Let's use it instead of for_each_rtd_cpu/codec_dais(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87sgi8olet.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-20ASoC: soc-dapm: Merge for_each_rtd_cpu/codec_dais()Kuninori Morimoto1-6/+3
Now we can use for_each_rtd_dais(). Let's use it instead of for_each_rtd_cpu/codec_dais(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87tv2ooley.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-20ASoC: soc-core: Merge for_each_rtd_cpu/codec_dais()Kuninori Morimoto1-18/+7
Now we can use for_each_rtd_dais(). Let's use it instead of for_each_rtd_cpu/codec_dais(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87v9n4olf4.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-20ASoC: soc-core: Merge CPU/Codec DAIsKuninori Morimoto2-10/+15
ALSA SoC is currently categorizing CPU/Codec DAIs, and it works well. But modern devices require more complex connections, for example Codec to Codec, etc, and future devices will enable to more complex connections. Because of these background, CPU/Codec DAIs categorizing is no longer good much to modern device. Currently, rtd has both CPU/Codec DAIs pointer. rtd->cpu_dais = [][][][][][][][][] rtd->codec_dais = [][][][][][][][][] This patch merges these into DAIs pointer. rtd->dais = [][][][][][][][][][][][][][][][][][] ^cpu_dais ^codec_dais |--- num_cpus ---|--- num_codecs --| Then, we can merge for_each_rtd_cpu/codec_dais() from this patch. - for_each_rtd_cpu_dais() { - ... - } - for_each_rtd_codec_dais() { - ... - } + for_each_rtd_dais() { + ... + } Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/87wo7kolfa.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-03-20Merge branch 'topic/ro_wordlength' of ↵Mark Brown2-7/+11
git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire into asoc-5.7
2020-03-20soundwire: stream: Add read_only_wordlength flag to port propertiesSrinivas Kandagatla2-7/+11
According to SoundWire Specification Version 1.2. "A Data Port number X (in the range 0-14) which supports only one value of WordLength may implement the WordLength field in the DPX_BlockCtrl1 Register as Read-Only, returning the fixed value of WordLength in response to reads." As WSA881x interfaces in PDM mode making the only field "WordLength" in DPX_BlockCtrl1" fixed and read-only. Behaviour of writing to this register on WSA881x soundwire slave with Qualcomm Soundwire Controller is throwing up an error. Not sure how other controllers deal with writing to readonly registers, but this patch provides a way to avoid writes to DPN_BlockCtrl1 register by providing a read_only_wordlength flag in struct sdw_dpn_prop Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200311113545.23773-2-srinivas.kandagatla@linaro.org Signed-off-by: Vinod Koul <vkoul@kernel.org>
2020-03-18Merge series "ASoC: stm32: manage rebind issue" from Olivier Moysan ↵Mark Brown2-41/+61
<olivier.moysan@st.com>: This patchset corrects a rebind issue on STM32 SPDIFRX and I2S drivers. The same correction has already been applied for SAI driver: 0d6defc7e0e4 ("ASoC: stm32: sai: manage rebind issue") The commit e894efef9ac7 ("ASoC: core: add support to card rebind") allows to rebind the sound card after a rebind of one of its component. With this commit, the sound card is actually rebound, but may be no more functional. The following problems have been seen on STM32 drivers. 1) DMA channel is not requested: With the sound card rebind the simplified call sequence is: probe snd_soc_register_component snd_soc_try_rebind_card snd_soc_instantiate_card devm_snd_dmaengine_pcm_register The problem occurs because the pcm must be registered, before snd_soc_instantiate_card() is called. Modify the driver, to change the call sequence as follows: probe devm_snd_dmaengine_pcm_register snd_soc_register_component snd_soc_try_rebind_card 2) DMA channel is not released: dma_release_channel() is not called when devm_dmaengine_pcm_release() is executed. This occurs because SND_DMAENGINE_PCM_DRV_NAME component, has already been released through devm_component_release(). devm_dmaengine_pcm_release() should be called before devm_component_release() to avoid this problem. Call snd_dmaengine_pcm_unregister() and snd_soc_unregister_component() explicitly from the driver, to have the right sequence. Olivier Moysan (3): ASoC: stm32: spdifrx: fix regmap status check ASoC: stm32: spdifrx: manage rebind issue ASoC: stm32: i2s: manage rebind issue sound/soc/stm/stm32_i2s.c | 40 ++++++++++++++++------ sound/soc/stm/stm32_spdifrx.c | 64 +++++++++++++++++++---------------- 2 files changed, 63 insertions(+), 41 deletions(-) -- 2.17.1
2020-03-18Merge series "ASoC: sdm845: fix soundwire stream handling" from Srinivas ↵Mark Brown3-44/+69
Kandagatla <srinivas.kandagatla@linaro.org>: Recent addition of SoundWire stream state-machine checks in linux-next have shown an existing issue with handling soundwire streams in codec drivers. In general soundwire stream prepare/enable/disable can be called from either codec/machine/controller driver. However calling it in codec driver means that if multiple instances(Left/Right speakers) of the same codec is connected to the same stream then it will endup calling stream prepare/enable/disable more than once. This will mess up the stream state-machine checks in the soundwire core. Moving this stream handling to machine driver would fix this issue and also allow board/platform specfic power sequencing. Changes since v1: - removed false error check while setting sruntime. Srinivas Kandagatla (2): ASoC: qcom: sdm845: handle soundwire stream ASoC: codecs: wsa881x: remove soundwire stream handling sound/soc/codecs/wsa881x.c | 44 +------------------------ sound/soc/qcom/Kconfig | 2 +- sound/soc/qcom/sdm845.c | 67 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 69 insertions(+), 44 deletions(-) -- 2.21.0