- 12 Jul, 2022 1 commit
-
-
Peter Ujfalusi authored
It is not yet clear, but it is possible to create a firmware so broken that it will send a reply message before a FW_READY message (it is not yet clear if FW_READY will arrive later). Since the reply_data is allocated only after the FW_READY message, this will lead to a NULL pointer dereference if not filtered out. The issue was reported with IPC4 firmware but the same condition is present for IPC3. Reported-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> 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/20220712122357.31282-2-peter.ujfalusi@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 11 Jul, 2022 16 commits
-
-
Mark Brown authored
Merge series from Cezary Rojewski <cezary.rojewski@intel.com>: Series consists of loosely connected patches and does not concentrate on one specific subject. First, as generic HDAudio codec driver is now part of ASoC, avs-driver core is updated to register missing ext_bus operations. This completes driver's core implementation. The next change adds the last missing piece for port descriptions coming from topology in formatted string format e.g.: ssp%d have full effect. To do that, the port value needs to be provided to respective copier configuration. Third change relaxes core transition timings so that scenarios where modules are interfering with each other while being on separate cores are not occasionally causing trouble. All other changes are addressing warnings, cleaning things up a little and protecting driver from invalid firmware behavior - while not expected in release binaries, does not hurt to add them.
-
Seven Lee authored
This patch adds the function of headphone button detection, Button detection will be enabled if the device tree has a key_enable property. Signed-off-by: Seven Lee <wtli@nuvoton.com> Link: https://lore.kernel.org/r/20220627032959.3442064-1-wtli@nuvoton.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Merge series from Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>: Our tests platforms do use realtek codecs, while implementing avs driver and machine boards for it, we identified some problems with those codec drivers. This series aims to fix those issues.
-
Mark Brown authored
Merge series from V sujith kumar Reddy <Vsujithkumar.Reddy@amd.com>: Add Generic driver to support multiple platform, ADD HS control instance for Rembrandt platform. Add nau8825,max98560 and rt5682s,rt1019 combination support for legacy platform.
-
Mark Brown authored
Merge series from Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>: Two patches to improve error and memory handling. When IPC4 is used, some of the flows were incorrect.
-
Pierre-Louis Bossart authored
We should only have an error when enforcing strict mapping between kernel and firmware versions. In all other cases, there is no reason to throw a warning. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220708200719.26961-1-pierre-louis.bossart@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Claudiu Beznea authored
Remove extra space in front of mchp_pdmc_dt_init(). Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com> Link: https://lore.kernel.org/r/20220711112212.888895-1-claudiu.beznea@microchip.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Needed for the Rockchip driver.
-
Amadeusz Sławiński authored
Make sure that component is set to proper value, otherwise we may dereference freed component in interrupt. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707125701.3518263-6-amadeuszx.slawinski@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
Make sure that component is set to proper value, otherwise we may dereference freed component in interrupt. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707125701.3518263-5-amadeuszx.slawinski@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
Make sure that component is set to proper value, otherwise we may dereference freed component in interrupt. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707125701.3518263-4-amadeuszx.slawinski@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
On our RVP platforms using rt298 with combojack we've seen issues with controls being in incorrect state after suspend/resume cycle. This is caused by codec driver not setting pins to correct state and causing codec suspend method to not be called. Which on resume caused codec registers to be in undefined state. Fix this by setting pins correctly in jack detect function. Above problem is caused by the fact that when jack == NULL code doesn't reach rt298_jack_detect() function which sets pins. Alternatively problem could be fixed by just moving rt298_jack_detect, but as rt298 codec is similar to rt286, align the code by setting pins explicitly. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707125701.3518263-3-amadeuszx.slawinski@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
Set rt298->jack to passed value in mic_detect, otherwise when jack is set to NULL on next interrupt call, we may use freed pointer. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707125701.3518263-2-amadeuszx.slawinski@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Alexandru Elisei authored
Commit a5450aba ("ASoC: rockchip: i2s: switch BCLK to GPIO") switched BCLK to GPIO functions when probing the i2s bus interface, but missed adding a check for when devm_pinctrl_get() returns an error. This can lead to the following NULL pointer dereference on a rockpro64-v2 if there are no "pinctrl" properties in the i2s device tree node. Check that i2s->pinctrl is valid before attempting to search for the bclk_on and bclk_off pinctrl states. Fixes: a5450aba ("ASoC: rockchip: i2s: switch BCLK to GPIO") Signed-off-by: Alexandru Elisei <alexandru.elisei@arm.com> Link: https://lore.kernel.org/r/20220711130522.401551-1-alexandru.elisei@arm.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Shengjiu Wang authored
Avoid build errors when CONFIG_COMMON_CLK is not set/enabled. ERROR: modpost: "__clk_get_name" [sound/soc/fsl/snd-soc-fsl-utils.ko] undefined! Fixes: 7bad8125 ("ASoC: fsl_utils: Add function to handle PLL clock source") Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Link: https://lore.kernel.org/r/1657507190-14546-1-git-send-email-shengjiu.wang@nxp.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Zhongjun Tan authored
Remove condition with no effect Signed-off-by: Zhongjun Tan <tanzhongjun@coolpad.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20220708024651.42999-1-hbut_tan@163.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 08 Jul, 2022 23 commits
-
-
Mark Brown authored
Merge series from Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>: Audio Graph Card2 has Codec2Codec support, but I noticed - Current Codec2Codec setting value is not correct because it is using of_get_property(). - simple-card-utils has default Codec2Codec settings and it is overwriting Card2 settings - This default settings works for non Codec2Codec case (= DPCM::BE case) too. This patch-set solve these issues.
-
Mark Brown authored
Merge series from Brent Lu <brent.lu@intel.com>: 1. Add BT offload fetch to cs42l42 machine driver 2. Support cs42l42+max98360a on ADL platform
-
Libin Yang authored
Free the memories allocated in sof_ipc4_get_audio_fmt in error handling and ipc_free() Fixes: 2cabd02b ("ASoC: SOF: ipc4-topology: Add support for parsing AIF_IN/AIF_OUT widgets") Fixes: abfb536b ("ASoC: SOF: ipc4-topology: Add support for parsing DAI_IN/DAI_OUT widgets") Fixes: 4f838ab2 ("ASoC: SOF: ipc4-topology: Add support for parsing and preparing pga widgets") Fixes: 4d4ba014 ("ASoC: SOF: ipc4-topology: Add support for parsing mixer widgets") Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Libin Yang <libin.yang@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220708200516.26853-3-pierre-louis.bossart@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Libin Yang authored
Set the swidget->private or dai->private to NULL after kfree in the error handling in ipc_setup(). The private needs to be set NULL because if ipc_setup() returns error, ipc_free() will be called later. ipc_free() will judge the private is NULL or not to do the clearing. For dai widget, dai->private is allocated and set in dai widget ipc_setup(). So we need to check dai->private is NULL or not in the ipc_free(). Fixes: 2cabd02b ("ASoC: SOF: ipc4-topology: Add support for parsing AIF_IN/AIF_OUT widgets") Fixes: abfb536b ("ASoC: SOF: ipc4-topology: Add support for parsing DAI_IN/DAI_OUT widgets") Fixes: 4f838ab2 ("ASoC: SOF: ipc4-topology: Add support for parsing and preparing pga widgets") Fixes: 4d4ba014 ("ASoC: SOF: ipc4-topology: Add support for parsing mixer widgets") Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Libin Yang <libin.yang@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220708200516.26853-2-pierre-louis.bossart@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
To reduce the number of places to update if timeouts would have to change, modify the constant declaration. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-13-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
Module unloading operation performs memory unmapping and the weight of the opration does not different from any other standard IPC. There is no dependency on secondary task like in module loading scenario where larger message timeout is recommended. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-12-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
Improve readability of CLDMA reset operation by making use of already defined SD_CTL_STREAM_RESET. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-11-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
If exposed by firmware, count RESERVED parameter as known one to avoid dumping noise in kernel logs. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-10-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
dma_set_mask() and dma_set_coherent_mask() can be performed with one call to dma_set_mask_and_coherent(), which slightly reduces amount of code on our side. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-9-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Amadeusz Sławiński authored
Apparently it is possible for code to allocate large buffers which may cause warnings as reported in [1]. This was fixed for HDA, SOF and skylake in patchset [2], fix it also for avs driver. [1] https://github.com/thesofproject/linux/issues/3430 [2] https://lore.kernel.org/all/20220215132756.31236-1-tiwai@suse.de/Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-8-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
To allow for driver's filesystem interfaces e.g.: debugfs, to be touched even when the device is asleep, mark IPC-channel as blocked when the device is suspended. This causes any invocation of said interfaces that do not toggle PM themselves to gracefully fail with "Operation not permitted" message. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-7-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
Some LARGE_CONFIG_GETs are never expected to return payload of size 0. Check for such situation and collapse if met. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-6-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
There is no need to copy number of bytes specified by IPC message caller if DSP firmware returned lower number. In consequence, LARGE_CONFIG_GET handler is simplified. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-5-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
To avoid any false positives when checking CPA after setting SPA, do a short wait. For stall operation, give HW more time to propagate the change before moving on. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-4-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
For formatted port - ssp%d - descriptions to have an effect, copier module templates need to be updated with specified port value. This value is later propagated to the firmware when module instances are being instantiated. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-3-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cezary Rojewski authored
With ASoC representation of HDAudio codec added, update bus initiazation to complete it. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220707124153.1858249-2-cezary.rojewski@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
V sujith kumar Reddy authored
Add i2s and dmic support for Rembrandt platform, Add machine support for nau8825, max98360 and rt5682s,rt1019 codec in legacy driver for rembrandt platform. Here codec is in a slave mode. Signed-off-by: V sujith kumar Reddy <Vsujithkumar.Reddy@amd.com> Link: https://lore.kernel.org/r/20220707161142.491034-4-Vsujithkumar.Reddy@amd.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
V sujith kumar Reddy authored
ADD Generic code to support to newer platforms, add control threshold, irq control macros ,added structure for register offset differences. Signed-off-by: V sujith kumar Reddy <Vsujithkumar.Reddy@amd.com> Link: https://lore.kernel.org/r/20220707161142.491034-3-Vsujithkumar.Reddy@amd.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
V sujith kumar Reddy authored
Remove rt1019_1 codec configuration which has i2c-10EC1019:01 and i2c-10EC1019:02 codec components, Now Using default i2c-10EC1019:00 and i2c-10EC1019:01 codec components. Signed-off-by: V sujith kumar Reddy <Vsujithkumar.Reddy@amd.com> Link: https://lore.kernel.org/r/20220707161142.491034-2-Vsujithkumar.Reddy@amd.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Brent Lu authored
This patch adds driver data for adl_mx98360a_cs4242 which supports two max98360a speaker amplifiers on SSP1 and cs42l42 headphone codec on SSP0 running on ADL platform. Signed-off-by: Brent Lu <brent.lu@intel.com> Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220708110030.658468-3-brent.lu@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Brent Lu authored
Add the capability to machine driver of creating DAI Link for BT offload. Although BT offload always uses SSP2 port but we reserve the flexibility to assign the port number in macro. Signed-off-by: Brent Lu <brent.lu@intel.com> Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220708110030.658468-2-brent.lu@intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
David Lin authored
The patch is to make driver with flexibility for more platforms support even if the internal design is just one ADC. Besides, many I2S controllers only support 2 channels. Signed-off-by: David Lin <CTLIN0@nuvoton.com> Link: https://lore.kernel.org/r/20220708054647.540621-1-CTLIN0@nuvoton.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Yang Li authored
Fix following includecheck warning: ./sound/soc/amd/acp-es8336.c: linux/module.h is included more than once. Signed-off-by: Yang Li <yang.lee@linux.alibaba.com> Link: https://lore.kernel.org/r/20220707232540.22589-1-yang.lee@linux.alibaba.comSigned-off-by: Mark Brown <broonie@kernel.org>
-