- 05 Apr, 2022 23 commits
-
-
Mark Brown authored
Merge series from Sameer Pujar <spujar@nvidia.com>: This series adds support for Asynchronous Sample Rate Converter (ASRC) module on Tegra186 and later generations of SoCs. ASRC is a client of AHUB. The driver and DT support is added to make it work with Tegra audio graph card. The module can be plugged into audio path using ALSA mixer controls. ASRC supports two modes of operation, where it gets the ratio info from SW and ratio detector module. Presently the support is added for SW mode.
-
Mark Brown authored
Merge series from Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>: Following patches contain minor changes, cleaning up code to be easier to read. Clean up few loops, to be simpler or altogether remove them. Rename some things to make code easier to understand.
-
Mark Brown authored
Merge series from Mark Brown <broonie@kernel.org>: This series contains a bunch of fairly minor changes which overhaul and modernise the WM8731 driver, there should be no impact on the driver's functionality.
-
Mark Brown authored
Merge series from Ranjani Sridharan <ranjani.sridharan@linux.intel.com>: This series includes some miscellaenous fixes pertaining to IPC, DMA buffer and DMA trace.
-
Mark Brown authored
Merge series from Trevor Wu <trevor.wu@mediatek.com>: This series of patches adds support for mt8195 board with mt6359, max98390 and rt5682. To prevent from copy-paste components, mt8195 machine drivers and dt-bindings are merged in the patch.
-
Mark Brown authored
Merge series from Mark Brown <broonie@kernel.org>: At some point the machine driver for the audio subsystem on the AT91SAM9G20-EK appears to have bitrotted, no longer probing due to effects of the transition to the common clock framework. The first patch in this series fixes the initial probe problem, with the rest of the series being random other fixes and cleanups I noticed while looking at the driver.
-
Cezary Rojewski authored
CATPT_SSP_IFACE_LAST is being used only to calculate CATPT_SSP_COUNT. Make CATPT_SSP_COUNT part of the enum directly and remove the redundant constant. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220403141647.1037173-1-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Derek Fang authored
Control the regulators separately instead of using regulator_bulk to accord to the timing request in the datasheet. Signed-off-by: Derek Fang <derek.fang@realtek.com> Link: https://lore.kernel.org/r/20220328053338.21441-1-derek.fang@realtek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Peter Ujfalusi authored
Since the scontrol->priv is freed up during load operation it should be set to NULL to be safe against double freeing attempt. Fixes: b5cee8fe ("ASoC: SOF: topology: Make control parsing IPC agnostic") Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.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/20220331114757.32551-1-peter.ujfalusi@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Stephen Kitt authored
The i2c probe functions here don't use the id information provided in their second argument, so the single-parameter i2c probe function ("probe_new") can be used instead. This avoids scanning the identifier tables during probes. Signed-off-by: Stephen Kitt <steve@sk2.org> Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Lucas Tanure <tanureal@opensource.cirrus.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325170734.1216018-1-steve@sk2.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Stephen Kitt authored
As part of the ongoing i2c transition to the simple probe ("probe_new"), this patch uses i2c_match_id to retrieve the driver_data for the probed device. The id parameter is thus no longer necessary and the simple probe can be used instead. Signed-off-by: Stephen Kitt <steve@sk2.org> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325162515.1204107-1-steve@sk2.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Stephen Kitt authored
The i2c probe functions here don't use the id information provided in their second argument, so the single-parameter i2c probe function ("probe_new") can be used instead. This avoids scanning the identifier tables during probes. Signed-off-by: Stephen Kitt <steve@sk2.org> Reviewed-by: Nuno Sá <nuno.sa@analog.com> Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Link: https://lore.kernel.org/r/20220325164828.1209201-1-steve@sk2.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Hui Wang authored
The CS35L41_NUM_OTP_ELEM is 100, but only 99 entries are defined in the array otp_map_1/2[CS35L41_NUM_OTP_ELEM], this will trigger UBSAN to report a shift-out-of-bounds warning in the cs35l41_otp_unpack() since the last entry in the array will result in GENMASK(-1, 0). UBSAN reports this problem: UBSAN: shift-out-of-bounds in /home/hwang4/build/jammy/jammy/sound/soc/codecs/cs35l41-lib.c:836:8 shift exponent 64 is too large for 64-bit type 'long unsigned int' CPU: 10 PID: 595 Comm: systemd-udevd Not tainted 5.15.0-23-generic #23 Hardware name: LENOVO \x02MFG_IN_GO/\x02MFG_IN_GO, BIOS N3GET19W (1.00 ) 03/11/2022 Call Trace: <TASK> show_stack+0x52/0x58 dump_stack_lvl+0x4a/0x5f dump_stack+0x10/0x12 ubsan_epilogue+0x9/0x45 __ubsan_handle_shift_out_of_bounds.cold+0x61/0xef ? regmap_unlock_mutex+0xe/0x10 cs35l41_otp_unpack.cold+0x1c6/0x2b2 [snd_soc_cs35l41_lib] cs35l41_hda_probe+0x24f/0x33a [snd_hda_scodec_cs35l41] cs35l41_hda_i2c_probe+0x65/0x90 [snd_hda_scodec_cs35l41_i2c] ? cs35l41_hda_i2c_remove+0x20/0x20 [snd_hda_scodec_cs35l41_i2c] i2c_device_probe+0x252/0x2b0 Fixes: 6450ef55 ("ASoC: cs35l41: CS35L41 Boosted Smart Amplifier") Reviewed-by: Lucas Tanure <tanureal@opensource.cirrus.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: Hui Wang <hui.wang@canonical.com> Link: https://lore.kernel.org/r/20220328123535.50000-2-hui.wang@canonical.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Hui Wang authored
otp_map[].size is a key variable to compute the value of otp_val and to update the bit_offset, it is helpful to debug if could put it in the debug log. Reviewed-by: Lucas Tanure <tanureal@opensource.cirrus.com> Signed-off-by: Hui Wang <hui.wang@canonical.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220328123535.50000-1-hui.wang@canonical.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Rikard Falkeborn authored
These structs only have their address assigned to the dapm_{routes,widget} fields in the snd_soc_card struct, both which are pointers to const data. Make them const to allow the compiler to put them in read-only memory. Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20220330204227.25081-1-rikard.falkeborn@gmail.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Stephen Kitt authored
As part of the ongoing i2c transition to the simple probe ("probe_new"), this patch uses i2c_match_id to retrieve the driver_data for the probed device. The id parameter is thus no longer necessary and the simple probe can be used instead. This patch follows the model set by da7218_of_get_id(). Signed-off-by: Stephen Kitt <steve@sk2.org> Reviewed-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Link: https://lore.kernel.org/r/20220325171904.1223539-1-steve@sk2.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Stephen Kitt authored
The i2c probe functions here don't use the id information provided in their second argument, so the single-parameter i2c probe function ("probe_new") can be used instead. This avoids scanning the identifier tables during probes. Signed-off-by: Stephen Kitt <steve@sk2.org> Reviewed-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Link: https://lore.kernel.org/r/20220325171243.1218003-1-steve@sk2.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Judy Hsiao authored
Add Machine driver support for ALC5682I-VS codec. Signed-off-by: Judy Hsiao <judyhsiao@chromium.org> Link: https://lore.kernel.org/r/20220331084201.62815-1-judyhsiao@chromium.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Takashi Iwai authored
It seems that flush_scheduled_work() is called without any real purpose at sst_context_cleanup() (the driver doesn't put works on the global queue at all). As the flush_schedule_work() function is going to be abolished in near future, let's drop it now. Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220322154826.19400-1-tiwai@suse.deSigned-off-by: Mark Brown <broonie@kernel.org>
-
Stephen Kitt authored
As part of the ongoing i2c transition to the simple probe ("probe_new"), this patch uses i2c_match_id to retrieve the driver_data for the probed device. The id parameter is thus no longer necessary and the simple probe can be used instead. Signed-off-by: Stephen Kitt <steve@sk2.org> Reviewed-by: Nuno Sá <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20220325165452.1212975-1-steve@sk2.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Martin Povišer authored
This function is an analogue of snd_soc_of_get_dai_link_codecs to help machine drivers read CPU DAI lists from devicetrees. Signed-off-by: Martin Povišer <povik+lin@cutebit.org> Link: https://lore.kernel.org/r/20220331000449.41062-5-povik+lin@cutebit.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Srinivasa Rao Mandadapu authored
Update error handling in power domain init and exit handlers, as existing handling may cause issues in device remove function. Use appropriate pm core api for power domain get and sync to avoid redundant code. Fixes: 9e3d83c5 ("ASoC: codecs: Add power domains support in digital macro codecs") 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> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/1647965937-32203-1-git-send-email-quic_srivasam@quicinc.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jaroslav Kysela authored
Use the new sound control LED layer instead the direct ledtrig_audio_set() call - see 22d8de62 ("ALSA: control - add generic LED trigger module as the new control layer"). Signed-off-by: Jaroslav Kysela <perex@perex.cz> Cc: Bard Liao <yung-chuan.liao@linux.intel.com> Cc: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220329120039.2394138-1-perex@perex.czSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 04 Apr, 2022 17 commits
-
-
Mark Brown authored
The AT91SAM9G20-EK audio driver is replacing any error code returned by atmel_ssc_set_audio() with -EINVAL which could be unhelpful for debugging. Pass through the error code, and include it in the log message we print for good measure. Signed-off-by: Mark Brown <broonie@kernel.org> Reviewed-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Link: https://lore.kernel.org/r/20220325154241.1600757-4-broonie@kernel.org
-
Mark Brown authored
The error handling in the AT91SAM9G20-EK machine driver probe did not consistently free the SSC in error paths, sometimes immediately returning an error rather than doing cleanup. Fix this. Signed-off-by: Mark Brown <broonie@kernel.org> Reviewed-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Link: https://lore.kernel.org/r/20220325154241.1600757-3-broonie@kernel.org
-
Mark Brown authored
The MCLK of the WM8731 on the AT91SAM9G20-EK board is connected to the PCK0 output of the SoC, intended in the reference software to be supplied using PLLB and programmed to 12MHz. As originally written for use with a board file the audio driver was responsible for configuring the entire tree but in the conversion to the common clock framework the registration of the named pck0 and pllb clocks was removed so the driver has failed to instantiate ever since. Since the WM8731 driver has had support for managing a MCLK provided via the common clock framework for some time we can simply drop all the clock management code from the machine driver other than configuration of the sysclk rate, the CODEC driver still respects that configuration from the machine driver. Fixes: ff78a189 ("ARM: at91: remove old at91-specific clock driver") Signed-off-by: Mark Brown <broonie@kernel.org> Reviewed-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Link: https://lore.kernel.org/r/20220325154241.1600757-2-broonie@kernel.org
-
Trevor Wu authored
This patch adds compatible string "mediatek,mt8195-mt6359-max98390-rt5682" to support mt8195 board with mt6359, max98390 and rt5682. Signed-off-by: Trevor Wu <trevor.wu@mediatek.com> Acked-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220324053851.27350-7-trevor.wu@mediatek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Trevor Wu authored
This patch adds support for mt8195 board with mt6359, max98390 and rt5682. Signed-off-by: Trevor Wu <trevor.wu@mediatek.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Reviewed-by: Tzung-Bi Shih <tzungbi@kernel.org> Link: https://lore.kernel.org/r/20220324053851.27350-6-trevor.wu@mediatek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Trevor Wu authored
In order to be able to reuse the same configurations in user space, rename the controls to generic names. "Headphone Jack" -> "Headphone" "Speakers" -> "Ext Spk" "Left Speaker" -> "Left Spk" "Right Speaker" -> "Right SPk" Signed-off-by: Trevor Wu <trevor.wu@mediatek.com> Reviewed-by: Tzung-Bi Shih <tzungbi@kernel.org> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20220324053851.27350-5-trevor.wu@mediatek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Trevor Wu authored
Because the same binding components can be shared by all codecs combinations, we only reserve one binding file for mt8195 machine driver and rename to a generic name. We use compatible string to separate different codec combination instead of creating a new binding file for new codec combination. Signed-off-by: Trevor Wu <trevor.wu@mediatek.com> Reviewed-by: Miles Chen <miles.chen@mediatek.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220324053851.27350-4-trevor.wu@mediatek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Trevor Wu authored
Because most functions can be reused in different codec combinations, mt8195 machine drivers are combined to one common file. The model and compatible string are used to decide which codecs are being used. As a result, We can prevent from copy-paste functions when new codec combination is introduced. Signed-off-by: Trevor Wu <trevor.wu@mediatek.com> Reviewed-by: Tzung-Bi Shih <tzungbi@kernel.org> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20220324053851.27350-3-trevor.wu@mediatek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Trevor Wu authored
Revise driver for the coming driver combination. There are two major parts including in the patch. 1. Apply some suggested changes used in mt8195-mt6359-rt1011-rt5682.c. 2. Reorder the layout for centralizing the codec related code. Signed-off-by: Trevor Wu <trevor.wu@mediatek.com> Reviewed-by: Tzung-Bi Shih <tzungbi@kernel.org> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20220324053851.27350-2-trevor.wu@mediatek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
The WM8731 driver has been refactored so the I2C and SPI bus code is separate modules. Refresh multi_v5_defconfig to reflect this. Signed-off-by: Mark Brown <broonie@kernel.org> Cc: soc@kernel.org Acked-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325153121.1598494-8-broonie@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Convert the WM8731 DT bindings to YAML format, including addition of documentation for the regulator and clock bindings which the driver has had for some time but which were not covered in the bindings document. Signed-off-by: Mark Brown <broonie@kernel.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: devicetree@vger.kernel.org Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220325153121.1598494-7-broonie@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
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.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
The code for initialising the MCLK and mutex is identical in the I2C and SPI probe functions so just move this out into wm8731_init(). Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325153121.1598494-5-broonie@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
The supplies used by the wm8731 do not depend on the bus and there is no need to do anything with the supplies prior to instantiating the regmap so move the request into wm8731_init(). Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325153121.1598494-4-broonie@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Both the I2C and SPI bus code register the component immediately after they call wm8731_hw_init(), factor the code out into the the common function and rename it to just be plain wm8731_init() while we're at it since it's not just for hardware init any more. This refactoring means we need to move the function after the declaration of the component driver. Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325153121.1598494-3-broonie@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
As part of retiring the old defines used to specify DAI formats update the wm8731 driver to use the modern names. Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220325153121.1598494-2-broonie@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
Other functions used for callbacks are named after function they call, however function calling control_load seems to be an exception. Rename it to soc_tplg_control_load(). Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220401120200.4047867-7-amadeuszx.slawinski@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-