summaryrefslogtreecommitdiffstats
path: root/sound
Commit message (Collapse)AuthorAgeFilesLines
...
| | * | | ASoC: Intel: common: clarify Copyright informationPierre-Louis Bossart2024-05-066-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some reason a number of files included the "All rights reserved" statement. Good old copy-paste made sure this mistake proliferated. Remove the "All rights reserved" in all Intel-copyright to align with internal guidance. Acked-by: Cezary Rojewski <cezary.rojewski@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: https://lore.kernel.org/r/20240503140359.259762-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: boards: clarify Copyright informationPierre-Louis Bossart2024-05-0615-17/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some reason a number of files included the "All rights reserved" statement. Good old copy-paste made sure this mistake proliferated. Remove the "All rights reserved" in all Intel-copyright to align with internal guidance. Acked-by: Cezary Rojewski <cezary.rojewski@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: https://lore.kernel.org/r/20240503140359.259762-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: clarify Copyright informationPierre-Louis Bossart2024-05-0693-93/+93
| | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some reason a number of files included the "All rights reserved" statement. Good old copy-paste made sure this mistake proliferated. Remove the "All rights reserved" in all Intel-copyright to align with internal guidance. Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: https://lore.kernel.org/r/20240503140359.259762-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | ASoC: qcom: q6apm-dai: drop unused 'q6apm_dai_rtd' fieldsKrzysztof Kozlowski2024-05-071-8/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove few unused fields from 'struct q6apm_dai_rtd'. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20240430140954.328127-1-krzysztof.kozlowski@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | ASoC: SOF: Intel: remove circular dependency forMark Brown2024-05-0731-637/+811
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>: The SoundWire BPT support will rely on the HDaudio DMA. This exposes a circular dependency module dependency which has to be resolved by splitting common parts used by HDaudio and SoundWire parts, and 'generic' parts used by HDaudio only. This patchset does not change any functionality, it just moves code around, exposes symbols that are used in the new module. The code has been in use for more than one kernel cycle already so it really shouldn't break any existing platforms. The main issue with such code moves is that it makes backports or fixes more complicated. That's the main reason why we held back these patches until we were reasonably confident on the maturity of MTL and LNL drivers.
| | * | | ASoC: SOF: Intel: move hda.c to different modulePierre-Louis Bossart2024-05-0522-22/+88
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that most of the code moves are done, we can add a new module and the required EXPORT_SYMBOL definitions. No functionality change, just a new module added. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-8-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: remove circular dependency on hda_sdw_process_wakeen()Pierre-Louis Bossart2024-05-059-1/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | hda_sdw_process_wakeen() is used in hda-loader.c, but defined in hda.c. This code split will create a circular dependency when hda.c is moved to a different module. Rather than an invasive code change, this patch follows the model used for sdw_check_wakeen_irq() with an abstraction. For now all abstractions point to the same common routine, which is arguably not great, but this also provides us with a future-proof way of addressing platform-specific wake processing. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-7-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: move tracepoint creationPierre-Louis Bossart2024-05-053-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CREATE_TRACEPOINTS is supposed to be used once. To avoid modpost issues when creating modules, let's move the tracepoint creation in a single object file. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-6-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: move common code from hda.cPierre-Louis Bossart2024-05-055-561/+575
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To avoid circular dependencies when moving hda.c to a separate module, we need to move the common code to hda-ipc.c and hda-dsp.c No functionality change, just code move. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-5-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: start splitting top-level from common partsPierre-Louis Bossart2024-05-0519-32/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing code relies on the 'HDA_COMMON' module and namespace. We need to start splitting top-level parts from the low-level ones, otherwise we will not be able to reuse the low-level parts DMA support for SoundWire/BPT. In the end the dependencies will be: +----------------------------------------------+ | | | v sof-pci-intel-xxx --> sof-intel-hda ------------> sof-hda-common | ^ | | +-> soundwire_intel --> sof_hda_sdw_bpt This patch adds the initial split between the sof-pci-intel-xxx modules and the common parts, in a follow-up patch we will further split the HDA_COMMON parts Since the PCI modules are not all independent, i.e. the CNL parts are also used in JSL and TGL, additional Kconfig and namespace modules were added. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: regroup all SoundWire/Intel functions in hda.cPierre-Louis Bossart2024-05-052-40/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To avoid circular dependencies between SOF/Intel and SoundWire/Intel, we need to split the top-level hda.c from the rest of the code. This patch first regroups all SoundWire related code in hda.c. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: SOF: Intel: hda-stream: export stream_get_position() helperPierre-Louis Bossart2024-05-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Export this helper so that we can report the DPIB position if the BPT DMA do not complete - this is very useful to see if the DMA started or gets stuck somehow with invalid bandwidth configurations. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Link: https://lore.kernel.org/r/20240503135221.229202-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | | ASoC: SOF: Intel: HDA/DMIC updatesMark Brown2024-05-073-60/+196
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>: The first patch handles a problematic configuration where the wrong machine driver/topology is used: when the hardware reports an external HDaudio codec the direction is to ignore/discard ACPI SoundWire devices. The last two patch deal with DMIC format configurations and allow users to select S16_LE even if the DMIC and internal copiers only support 24 or 32-bits. The code changes are located in sound/soc/sof/ but in the scope of Intel DAIs.
| | * | | | ASoC: SOF: ipc4-topology: Correct DAI copier config and NHLT blob requestPeter Ujfalusi2024-05-051-26/+136
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In case of capture and when the DAI copier have single bit depth supported on it's input side we should use this format instead of the one in fe_params. Regardless of the stream direction for the NHLT blob lookup when the DAI copier only supports single bit depth on the DAI side we should only look for a blob which matches with this single configuration. For DMIC if the DAI copier supports multiple bit depths, try to request 32-bit blob first if the requested bit depth is 16-bit. If the 32-bit blob is available then look for marching (32-bit) copier format to make sure that both the blob and copier have correct parameters. Reviewed-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240503133253.108201-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: SOF: ipc4-topology: Allow selective update in sof_ipc4_update_hw_paramsPeter Ujfalusi2024-05-051-32/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a bitmask parameter to sof_ipc4_update_hw_params() to be able to select the param to be updated. This feature can be used when not all params should be updated, for example if caller only wants to update the format in the params, leaving the channels and rates untouched. Reviewed-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240503133253.108201-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: SOF: Intel: discard SoundWire configuration if HDaudio codec is reportedPierre-Louis Bossart2024-05-052-2/+9
| | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The machine driver and topology selection starts with I2S, then SoundWire and last uses HDaudio as a fallback. That assumes that the ACPI information is correct but there are of course exceptions to the rule. On a Lenovo platform, an external HDaudio codec is detected, but the ACPI tables expose TWO RT711 jack codecs. This patch skips the SoundWire selection in case an external HDaudio codec is detected - which only works with the additional assumption that no one will mix HDaudio and SoundWire. Closes: https://github.com/thesofproject/linux/issues/4962 Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Reviewed-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/20240503133253.108201-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | / / ASoC: tas2781: Fix a warning reported by robot kernel testShenghao Ding2024-05-061-3/+3
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix a warning reported by robot kernel test that 'fw_entry' in function 'tas2781_load_calibration' is used uninitialized with compiler sh4-linux-gcc (GCC) 13.2.0, an update of copyright and a correction of the comments. Fixes: ef3bcde75d06 ("ASoc: tas2781: Add tas2781 driver") Signed-off-by: Shenghao Ding <shenghao-ding@ti.com> Link: https://lore.kernel.org/r/20240505122346.1326-1-shenghao-ding@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | ASoC: codecs: Drop explicit initialization of struct ↵Uwe Kleine-König2024-05-03141-168/+168
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | i2c_device_id::driver_data to 0 These drivers don't use the driver_data member of struct i2c_device_id, so don't explicitly initialize this member. This prepares putting driver_data in an anonymous union which requires either no initialization or named designators. But it's also a nice cleanup on its own. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20240502074722.1103986-2-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
| * | ASoC: doc: dapm: various improvementsMark Brown2024-05-013-7/+48
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Luca Ceresoli <luca.ceresoli@bootlin.com>: This series applies various improvements to the DAPM documentation: a rewrite of a few sections for clarity, style improvements and typo fixes. Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> --- Changes in v2: - avoid wrapping in patch 3 as suggested by Alex - Link to v1: https://lore.kernel.org/r/20240416-dapm-docs-v1-0-a818d2819bf6@bootlin.com --- Luca Ceresoli (12): ASoC: doc: dapm: fix typos ASoC: doc: dapm: fix struct name ASoC: doc: dapm: minor rewording ASoC: doc: dapm: remove dash after colon ASoC: doc: dapm: clarify it's an internal API ASoC: doc: dapm: replace "map" with "graph" ASoC: doc: dapm: extend initial descrption ASoC: doc: dapm: describe how widgets and routes are registered ASoC: doc: dapm: fix and improve section "Registering DAPM controls" ASoC: doc: dapm: improve section "Codec/DSP Widget Interconnections" ASoC: doc: dapm: update section "DAPM Widget Events" ASoC: doc: dapm: update event types Documentation/sound/soc/dapm-graph.svg | 375 +++++++++++++++++++++++++++++++++ Documentation/sound/soc/dapm.rst | 174 ++++++++++----- 2 files changed, 492 insertions(+), 57 deletions(-) --- base-commit: c942a0cd3603e34dd2d7237e064d9318cb7f9654 change-id: 20240315-dapm-docs-79bd51f267db Best regards, -- Luca Ceresoli <luca.ceresoli@bootlin.com>
| * \ \ ASoC: Intel: updates for 6.10 - part6Mark Brown2024-04-3013-1016/+461
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>: Last batch of cleanups from Brent Lu, with Chromebooks now supported with fewer modular machine drivers.
| | * | | ASoC: Intel: sof-rt5682: support bclk as PLL source on rt5682sBrent Lu2024-04-291-8/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For rt5682s codec, we could use bclk as PLL source when the frequency is 3.072MHz but no 2.4MHz. Update the code to select correct pll_id and clk_id for 3.072MHz bclk. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-24-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof-rt5682: get bclk frequency from topologyBrent Lu2024-04-291-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A different bclk frequency 3.072MHz was introduced to tgl platform and is used in mtl topologies. Use SOF API to get frequency from topology instead of hardcoding. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-23-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof-rt5682: setup pll_id only when neededBrent Lu2024-04-291-29/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The variable 'pll_id' is needed only when we use snd_soc_dai_set_pll() to setup PLL. Move the code segment to improve some readability. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-22-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof-rt5682: add driver_data to sof_rt5682 boardBrent Lu2024-04-291-10/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move default BYT/CHT quirk to driver_data of sof_rt5682 board. This fixes a problem that DMI quirk of Minnowboard board got overwritten in probe function since it's a BYT board. Fixes: c68e07970eca ("ASoC: intel: sof_rt5682: Add quirk for number of HDMI DAI's") Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-21-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_rt5682: add icl_rt5682_def for icl boardsBrent Lu2024-04-292-10/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the board config icl_rt5682_def to rt5682 machine driver for all icl boards using default SSP port allocation (headphone codec on SSP0). Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-20-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof-rt5682: remove SOF_RT5682_MCLK_BYTCHT_ENBrent Lu2024-04-291-20/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We don't need this quirk flag since 'is_legacy_cpu' will be true if this is a BYT/CHT board. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-19-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof-rt5682: add mclk_en to sof_rt5682_privateBrent Lu2024-04-292-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a variable mclk_en to sof_rt5682_private structure to reduce global variable access. No functional change. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-18-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: glk_rt5682_max98357a: delete driverBrent Lu2024-04-294-706/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Delete this driver and use sof_rt5682 machine driver instead. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-17-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_rt5682: support MAX98357A on glk boardsBrent Lu2024-04-291-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For glk boards, MAX98357A speaker amplifier is supported by machine driver glk_rt5682_mx98357a with sound card name glkrt5682max. Use same name for backward compatibility with existing devices on market. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-16-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_rt5682: add glk_rt5682_def for glk boardsBrent Lu2024-04-291-12/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the board config glk_rt5682_def to rt5682 machine driver for all glk boards using default SSP port allocation (headphone codec on SSP2, speaker amplifiers on SSP1). Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-15-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: bxt_da7219_max98357a: remove glk supportBrent Lu2024-04-294-56/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove glk platform support and use sof_da7219 machine driver instead for existing glk boards with MAX98357A speaker amplifier. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-14-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: support MAX98357A on glk boardsBrent Lu2024-04-291-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For glk boards, MAX98357A speaker amplifier is supported by machine driver bxt_da7219_max98357a with sound card name glkda7219max. Use same name for backward compatibility with existing devices on market. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-13-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: add glk_da7219_def for glk boardsBrent Lu2024-04-291-4/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the board config glk_da7219_def to da7219 machine driver for all glk boards using default SSP port allocation (headphone codec on SSP2, speaker amplifiers on SSP1). Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-12-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: bxt_da7219_max98357a: remove cml supportBrent Lu2024-04-293-32/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove cml platform support and use sof_da7219 machine driver instead for existing cml boards with MAX98357A speaker amplifier. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-11-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: support MAX98357A on cml boardsBrent Lu2024-04-291-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For cml boards, MAX98357A speaker amplifier is supported by machine driver bxt_da7219_max98357a with sound card name cmlda7219max. Use same name for backward compatibility with existing devices on market. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-10-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: support MAX98357ABrent Lu2024-04-291-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support to Maxim MAX98357A speaker amplifier. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-9-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_rt5682: add missing MAX98357A configBard Liao2024-04-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sof_rt5682 supports MAX98357A/MAX98360A amp. Select SND_SOC_MAX98357A as needed. Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-8-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: bxt_da7219_max98357a: remove MAX98390 supportBrent Lu2024-04-293-111/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove MAX98390 support and use sof_da7219 machine driver instead for existing cml boards with MAX98390 speaker amplifier. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-7-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: support MAX98390 on cml boardsBrent Lu2024-04-291-5/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For cml boards, MAX98390 speaker amplifier is supported by machine driver bxt_da7219_max98357a with sound card name cml_max98390_da7219. Use same name for backward compatibility with existing devices on market. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-6-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: add cml_da7219_def for cml boardsBrent Lu2024-04-291-3/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the board config cml_da7219_def to da7219 machine driver for all cml boards using default SSP port allocation (headphone codec on SSP0, speaker amplifiers on SSP1). Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-5-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_da7219: support MAX98390Brent Lu2024-04-292-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support to Maxim MAX98390 speaker amplifier. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: sof_maxim_common: support MAX98390 on cml boardsBrent Lu2024-04-291-7/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for 2xMAX98390 speaker amplifier running in I2S mode for existing cml boards. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | ASoC: Intel: nau8825/rt5682: move speaker widget to common modulesBrent Lu2024-04-294-15/+180
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two machine drivers sof_rt5682 and sof_nau8825 always register two speaker widgets 'Left Spk' and 'Right Spk' regardless the actual number of speakers. Move the widget registration to speaker common modules to avoid useless speaker widgets for 1 or 4 speaker boards. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20240426152529.38345-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | | ASoC: Intel: avs: PCM code cleanupMark Brown2024-04-302-139/+113
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Cezary Rojewski <cezary.rojewski@intel.com>: A set of changes that aims to improve readability of cohesiveness of the pcm code for the avs-driver. Start off with a change that synchronizes DAI open/close - DAIs are started up in ascending order yet their shutdown does not follow the scheme - it is done in the ascending order too, rather than desceding one. This patch is a dependency for the next one in line. To align the HDAudio DAI startup/shutdown with the non-HDAudio equivalents, relocate the code from component to DAI. The reason above is a dependency stems from codec driver requirements - HDAudio code found in sound/pci/hda/ expects substream->runtime->private_data to point to a valid stream (HOST) pointer. With the hard part done, the follow up changes update the existing code to reduce it is complexity - removal of duplicates, renaming of ambiguous functions and adding new fields to DAI-data object so that the number of local variables and casts is reduced.
| | * | | | ASoC: Intel: avs: Clean up hw constraints initializationCezary Rojewski2024-04-301-40/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provide a separate function that initializes all PCM hardware constraints for the driver. No functional changes. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20240426095733.3946951-9-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: Intel: avs: Store pointer to link_stream in dma_dataCezary Rojewski2024-04-301-21/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While the HDAudio codec driver expectations must be met - store valid pointer to HDAudio LINK stream in substream->runtime->private_data - the code is more readable and easier to maintain if dma_data stores pointers to both HOST and LINK stream. DAI BE operations can refer to the LINK stream with data->link_stream, similarly to how DAI FE operations access the HOST stream with data->host_stream. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20240426095733.3946951-8-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: Intel: avs: Remove redundancy around DAI prepareCezary Rojewski2024-04-301-10/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Drop unused arguments in the avs_dai_prepare() function. With the function updated, it matches its template in snd_soc_dai_ops and can be referenced throughout the pcm.c file without need of any wrappers. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20240426095733.3946951-7-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: Intel: avs: Remove redundancy around DAI startupCezary Rojewski2024-04-301-17/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Half of the arguments in avs_dai_startup() are unused and can be dropped. With the function updated, it matches its template in snd_soc_dai_ops and can be referenced throughout the pcm.c file without need of any wrappers. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20240426095733.3946951-6-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: Intel: avs: Store pointer to adev in DAI dma_dataCezary Rojewski2024-04-301-9/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce the number of to_avs_dev() casts by storing the driver context in DAI's dma_data. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20240426095733.3946951-5-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | | ASoC: Intel: avs: Remove redundancy around DAI shutdownCezary Rojewski2024-04-301-25/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move avs_dai_nonhda_be_shutdown() to avs_dai_shutdown() as the function is common for all transfer types, not just non-HDAudio ones. Use it to simplify avs_dai_fe_shutdown(). While at it, fix explicit kfree(data) and use the destructor instead. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20240426095733.3946951-4-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>