summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2024-09-19ASoC: topology: Fix incorrect addressing assignmentsTang Bin1-2/+2
The variable 'kc' is handled in the function soc_tplg_control_dbytes_create(), and 'kc->private_value' is assigned to 'sbe', so In the function soc_tplg_dbytes_create(), the right 'sbe' should be 'kc.private_value', the same logical error in the function soc_tplg_dmixer_create(), thus fix them. Fixes: 0867278200f7 ("ASoC: topology: Unify code for creating standalone and widget bytes control") Fixes: 4654ca7cc8d6 ("ASoC: topology: Unify code for creating standalone and widget mixer control") Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Reviewed-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Link: https://patch.msgid.link/20240914081608.3514-1-tangbin@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-19ASoC: amd: yc: Add quirk for HP Dragonfly pro oneDavid Lawrence Glanzman1-0/+7
Adds a quirk entry to enable the mic on HP Dragonfly pro one laptop Signed-off-by: David Lawrence Glanzman <davidglanzman@yahoo.com> Link: https://patch.msgid.link/1249c09bd6bf696b59d087a4f546ae397828656c.camel@yahoo.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-18ASoC: amd: acp: don't set card long_nameVijendar Mukunda1-5/+0
UCM can load a board-specific file based on the card long_name. Remove the constant "AMD Soundwire SOF" long_name so that the ASoC core can set the long_name based on DMI information. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://patch.msgid.link/20240916061318.3147988-1-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: topology: Fix redundant logical jumpTang Bin1-6/+3
In the function soc_tplg_dai_config, the logical jump of 'goto err' is redundant, so remove it. Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Link: https://patch.msgid.link/20240908140259.3859-1-tangbin@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: tas2781: Add Calibration Kcontrols for ChromebookShenghao Ding4-11/+1030
Add calibration related kcontrol for speaker impedance calibration and speaker leakage check for Chromebook. Signed-off-by: Shenghao Ding <shenghao-ding@ti.com> Link: https://patch.msgid.link/20240911232739.1509-1-shenghao-ding@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13AMD SoundWire machine driver code refactorMark Brown4-573/+354
Merge series from Vijendar Mukunda <Vijendar.Mukunda@amd.com>: This patch series moves common Soundwire endpoint parsing and dai creation logic to common placeholder from Intel generic SoundWire machine driver code to make it generic. AMD SoundWire machine driver code is refactored to use these functions for SoundWire endpoint parsing and dai creation logic. Link: https://github.com/thesofproject/linux/pull/5171
2024-09-13ASoC: amd: acp: refactor SoundWire machine driver codeVijendar Mukunda1-386/+154
Refactor Soundwire machine driver code by using common SoundWire endpoint parsing helper functions. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240913090631.1834543-6-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: sdw_utils/intel: move soundwire endpoint parsing helper functionsVijendar Mukunda3-158/+171
Move SoundWire endpoint parsing helper functions to common place holder. These functions will be used by other platform machine driver code. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240913090631.1834543-5-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: sdw_util/intel: move soundwire endpoint and dai link structuresVijendar Mukunda2-21/+21
Move Soundwire endpoint and dai link structures from Intel generic machine driver code to common place holder(soc_sdw_utils.h). These structures will be used in other platform SoundWire machine driver code. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240913090631.1834543-4-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: intel: sof_sdw: rename soundwire parsing helper functionsVijendar Mukunda1-10/+10
Rename SoundWire parsing helper functions with 'asoc_sdw' tag to make it generic. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240913090631.1834543-3-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: intel: sof_sdw: rename soundwire endpoint and dailink structuresVijendar Mukunda1-14/+14
Rename SoundWire endpoint and dai link structures with asoc tag to make it generic. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240913090631.1834543-2-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-13ASoC: atmel: mchp-pdmc: Retain Non-Runtime ControlsCodrin Ciubotariu1-42/+15
Avoid removing these controls, as doing so can cause issues if the stream is initiated from another control. Ensure these controls remain intact when the stream is started or finished. Instead of removing them, return an -EBUSY error code to indicate that the controller is busy, especially when the audio filter and the SINC filter are in use. [andrei.simion@microchip.com: Reword the commit title and the commit message. Replace spinlock and busy variable with atomic_t busy_stream.] Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Andrei Simion <andrei.simion@microchip.com> Link: https://patch.msgid.link/20240913120621.79088-1-andrei.simion@microchip.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: boards: updates for 6.12 - part 2Mark Brown14-386/+259
Merge series from Bard Liao <yung-chuan.liao@linux.intel.com>: Cleanup from Brent Lu and add HDMI-In capture supports from Balamurugan C.
2024-09-12ASoC: mediatek: mt7986-afe-pcm: Remove redundant error messageTang Bin1-4/+3
In the function mt7986_afe_pcm_dev_probe, when get irq failed, the function platform_get_irq() logs an error message, so remove redundant one here. Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Link: https://patch.msgid.link/20240912084110.1854-1-tangbin@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoc: mediatek: mt8365: Remove unneeded assignmentMuhammad Usama Anjum1-2/+1
The ret is being assigned, but not being used. Remove the assignment. One of the reviewer mentioned that dev_warn should be replaced with dev_info. Make this change as well. Fixes: 1bf6dbd75f76 ("ASoc: mediatek: mt8365: Add a specific soundcard for EVK") Signed-off-by: Muhammad Usama Anjum <usama.anjum@collabora.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://patch.msgid.link/20240911123629.125686-1-usama.anjum@collabora.com Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: ARL: Add entry for HDMI-In capture support to non-I2S codec boards.Balamurugan C2-0/+12
Adding HDMI-In capture support for the ARL products which doesn't have onboard I2S codec. But need to support HDMI-In capture via I2S and audio playback through HDMI/DP monitor. Signed-off-by: Balamurugan C <balamurugan.c@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-8-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: sof_rt5682: Add HDMI-In capture with rt5682 support for ARL.Balamurugan C2-0/+20
Added match table entry on arl machines to support HDMI-In capture with rt5682 I2S audio codec. also added the respective quirk configuration in rt5682 machine driver. Signed-off-by: Balamurugan C <balamurugan.c@intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-7-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: SOF: Intel: hda: remove common_hdmi_codec_drvBrent Lu2-3/+0
Do not set common_hdmi_codec_drv in SOF platform driver since no machine driver needs it. Remove member variable common_hdmi_codec_drv from snd_soc_acpi_mach_params structure. Signed-off-by: Brent Lu <brent.lu@intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-6-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: sof_pcm512x: do not check common_hdmi_codec_drvBrent Lu1-2/+1
The variable common_hdmi_codec_drv is always true on SOF platform so we could remove the reference in machine driver. Signed-off-by: Brent Lu <brent.lu@intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-5-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: ehl_rt5660: do not check common_hdmi_codec_drvBrent Lu1-2/+1
The variable common_hdmi_codec_drv is always true on SOF platform so we could remove the reference in machine driver. Signed-off-by: Brent Lu <brent.lu@intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-4-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: skl_hda_dsp_generic: use common module for DAI linksBrent Lu5-379/+70
Use intel_board module to create DAI link array for Intel iDisp HDMI, HDA external codec, DMIC01, DMIC16K, and BT audio offload DAI BE links. Signed-off-by: Brent Lu <brent.lu@intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-3-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Intel: board_helpers: support HDA link initializationBrent Lu2-0/+155
Add a helper function for machine drivers to initialize HDA external codec DAI link. Signed-off-by: Brent Lu <brent.lu@intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20240912120308.134762-2-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-12ASoC: Improvements for mchp-pdmcMark Brown1-11/+29
Merge series from Andrei Simion <andrei.simion@microchip.com>: This patch set is intended to enhance the functionality and maintainability of the mchp-pdmc driver: - Enhances performance by refining maxburst logic. - Introduces a name for better identification and management.
2024-09-11ASoC: dt-bindings: microchip,sama7g5-spdifrx: Add common DAI referenceAndrei Simion1-1/+4
Update the spdifrx yaml file to reference the dai-common.yaml schema, enabling the use of the 'sound-name-prefix' property Signed-off-by: Andrei Simion <andrei.simion@microchip.com> Acked-by: Rob Herring (Arm) <robh@kernel.org> Link: https://patch.msgid.link/20240910082202.45972-1-andrei.simion@microchip.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11ASoC: dt-bindings: renesas,rsnd: add post-init-providers propertyKuninori Morimoto1-0/+6
At least if rsnd is using DPCM connection on Audio-Graph-Card2, fw_devlink might doesn't have enough information to break the cycle (Same problem might occur with Multi-CPU/Codec or Codec2Codec). In such case, rsnd driver will not be probed. Add post-init-providers support to break the link cycle. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Rob Herring (Arm) <robh@kernel.org> Link: https://patch.msgid.link/87wmjkifob.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11Add support for primary mi2s on SM8250Mark Brown1-0/+8
Merge series from Jens Reidel <adrian@travitia.xyz>: This patch adds support for the primary mi2s interface on devices using SM8250 audio drivers. Tested on SM7150 (xiaomi-davinci). SM7150 sound is close to SM8250 and we intend to use it as a fallback in the future. To: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> To: Liam Girdwood <lgirdwood@gmail.com> To: Mark Brown <broonie@kernel.org> To: Jaroslav Kysela <perex@perex.cz> To: Takashi Iwai <tiwai@suse.com> Cc: alsa-devel@alsa-project.org Cc: linux-arm-msm@vger.kernel.org Cc: linux-sound@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: linux@mainlining.org Jens Reidel (1): ASoC: qcom: sm8250: enable primary mi2s sound/soc/qcom/sm8250.c | 8 ++++++++ 1 file changed, 8 insertions(+) -- 2.46.0
2024-09-11ASoC: atmel: mchp-pdmc: Add snd_soc_dai_driver nameCodrin Ciubotariu1-0/+1
Set snd_soc_dai_driver name to improve controller's display of the DAI name. Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Andrei Simion <andrei.simion@microchip.com> Link: https://patch.msgid.link/20240911122909.133399-3-andrei.simion@microchip.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11ASoC: atmel: mchp-pdmc: Improve maxburst calculation for better performanceCodrin Ciubotariu1-11/+28
Improve the DMA descriptor calculation by dividing the period size by the product of sample size and DMA chunk size, rather than just DMA chunk size. Ensure that all DMA descriptors start from a well-aligned address to improve the reliability and efficiency of DMA operations and avoid potential issues related to misaligned descriptors. [andrei.simion@microchip.com: Adjust the commit title. Reword the commit message. Add MACROS for each DMA size chunk supported by mchp-pdmc. Add DMA_BURST_ALIGNED preprocesor function to check the alignment of the DMA burst.] Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Andrei Simion <andrei.simion@microchip.com> Link: https://patch.msgid.link/20240911122909.133399-2-andrei.simion@microchip.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11ASoC: mediatek: mt8365: check validity before usage of i2s_dataMuhammad Usama Anjum1-1/+4
There may be a case where i2s_data may not get initialized by the for loop which will cause the kernel crash. Initialize the i2s_data to NULL and abort execute if it isn't found. Fixes: 402bbb13a195 ("ASoC: mediatek: mt8365: Add I2S DAI support") Signed-off-by: Muhammad Usama Anjum <usama.anjum@collabora.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://patch.msgid.link/20240911111317.4072349-1-usama.anjum@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11ASoC: amd: acp: remove MODULE_ALIAS for sof based generic machine driverVijendar Mukunda1-7/+0
As module device table added for AMD sof based generic machine driver, MODULE_ALIAS is not required. Remove MODULE_ALIAS for AMD sof based generic machine driver. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://patch.msgid.link/20240911093554.2076872-2-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11ASoC: amd: acp: remove MODULE_ALIAS for legacy machine driverVijendar Mukunda1-7/+0
As module device table added for AMD legacy machine driver, MODULE_ALIAS is not required. Remove MODULE_ALIAS for AMD legacy machine driver. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://patch.msgid.link/20240911093554.2076872-1-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-11ASoC: tlv320aic31xx: Fix typosAndrew Kreimer1-1/+1
Fix typos in comments. Reported-by: Matthew Wilcox <willy@infradead.org> Signed-off-by: Andrew Kreimer <algonell@gmail.com> Link: https://patch.msgid.link/20240910211302.8909-1-algonell@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-10ASoC: meson: Remove unused declartion in header fileZhang Zekun1-2/+0
The declaration of aiu_fifo_hw_free() has been removed since commit e05cde84eabc ("ASoC: meson: Use managed DMA buffer allocation"). Let's remove the unused declaration. Fixes: e05cde84eabc ("ASoC: meson: Use managed DMA buffer allocation") Signed-off-by: Zhang Zekun <zhangzekun11@huawei.com> Reviewed-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://patch.msgid.link/20240910122330.70684-1-zhangzekun11@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-10ASoC: qcom: sm8250: enable primary mi2sJens Reidel1-0/+8
When using primary mi2s on sm8250-compatible SoCs, the correct clock needs to get enabled to be able to use the mi2s interface. Signed-off-by: Jens Reidel <adrian@travitia.xyz> Tested-by: Danila Tikhonov <danila@jiaxyga.com> # sm7325-nothing-spacewar Link: https://patch.msgid.link/20240826134920.55148-2-adrian@travitia.xyz Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-10ASoC: loongson: Add the correct judgement returnTang Bin2-8/+8
Use the function dev_err_probe can simplify code, but the error return should not be deleted, that is unreasonable, thus fix it. Fixes: 3d2528d6c021 ("ASoC: loongson: Simplify with dev_err_probe()") Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Link: https://patch.msgid.link/20240910021104.3400-1-tangbin@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-10ASoC: soc-ac97: Fix the incorrect descriptionTang Bin1-2/+2
In the function snd_soc_alloc_ac97_component & snd_soc_new_ac97_component, the error return is ERR_PTR, so fix the incorrect description. Fixes: 47e039413cac ("ASoC: Add support for allocating AC'97 device before registering it") Fixes: 7361fbeaeaab ("ASoC: ac97: Add support for resetting device before registration") Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Link: https://patch.msgid.link/20240910013303.2044-1-tangbin@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-10ASoC: mt8365: Fix -Werror buildsMark Brown8-153/+120
Merge series from Mark Brown <broonie@kernel.org>: Nathan reported that the newly added mt8365 drivers were causing a number of warnings which break -Werror builds, these were only visible on arm64 since the drivers did not have COMPILE_TEST enabled. Fix this and some other minor stuff I noticed while doing so.
2024-09-10ASoC: loongson: Simplify code formattingMark Brown5-159/+157
Merge series from Binbin Zhou <zhoubinbin@loongson.cn>: This patchset attempts to improve code readability by simplifying code formatting. No functional changes.
2024-09-09ASoC: Switch back to struct platform_driver::remove()Uwe Kleine-König184-184/+184
After commit 0edb555a65d1 ("platform: Make platform_driver::remove() return void") .remove() is (again) the right callback to implement for platform drivers. Convert all drivers below sound/soc to use .remove(), with the eventual goal to drop struct platform_driver::remove_new(). As .remove() and .remove_new() have the same prototypes, conversion is done by just changing the structure member name in the driver initializer. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> Link: https://patch.msgid.link/20240909151230.909818-2-u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: atmel: mchp-i2s-mcc: Remove interface name from stream_nameCodrin Ciubotariu1-2/+2
Remove the interface name from the stream_name. The interface name (and the index of the interface) can be set in DT using the sound-name-prefix string property. [andrei.simion@microchip: Adjust the commit title] Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Andrei Simion <andrei.simion@microchip.com> Link: https://patch.msgid.link/20240909083530.14695-2-andrei.simion@microchip.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: codecs: fix the right check and simplify codeTang Bin1-5/+5
In the file drivers/base/platform.c, the return description of platform_get_irq is 'non-zero IRQ number on success, negative error number on failure.', so the check is wrong, fix it. And when get irq failed, the function platform_get_irq logs an error message. Fixes: 5e2404493f9f ("ASoC: codecs: add MT6357 support") Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Link: https://patch.msgid.link/20240908134604.3652-1-tangbin@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Allow build coverageMark Brown1-1/+1
There is no build time dependency on anything specific to ARCH_MEDIATEK so enable COMPILE_TEST builds. Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-7-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Remove unused DMIC IIR coefficient configurationMark Brown1-30/+0
Nothing ever calls mt8365_dai_load_dmic_iirc_coeff_table() so the compiler warns about an unused static function. While it seems likely that something should be calling the function I don't know what and this is breaking -Werror builds like allmodconfig so let's just remove it. It can be added again along with the user. Reported-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-6-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Remove unused variablesMark Brown2-3/+1
Silence compiler warnings by removing unused variables. Reported-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-5-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Make non-exported functions staticMark Brown2-8/+8
The compilers warn if functions without a prototype are not static so add appropriate static declarations. Reported-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-4-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Remove unused prototype for mt8365_afe_clk_group_48k()Mark Brown1-1/+0
The function is not used outside of the file it is defined and the equivalent function for 44.1kHz is not prototyped so remove the prototype for this function. Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-3-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Remove spurious unsigned long castsMark Brown1-3/+3
The regmap APIs take unsigned ints not unsigned longs so casting their arguments to unsigned longs is not a good choice, the constants being cast here are all unsigned ints anyway. Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-2-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: mt8365: Open code BIT() to avoid spurious warningsMark Brown1-107/+107
The mt8365 driver uses bits.h to define bitfields but BIT() uses unsigned long constants so does not play well with being bitwise negated and converted to an unsigned int, the compiler complains about width reduction on a number of architectures. Just open code the shifting to avoid the issue. Generated with s/BIT(/(1U << / Reported-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-1-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: loongson: Factor out loongson i2s enable clock functionsBinbin Zhou1-39/+47
There are a few i2s clock enable operations in loongson_i2s_set_fmt(), convert them to simple helper functions called loongson_i2s_enable_mclk() and loongson_i2s_enable_bclk(). Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn> Link: https://patch.msgid.link/d6f6c818b0ecee87277f704b6a801cbbf5e712ce.1725844530.git.zhoubinbin@loongson.cn Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-09ASoC: loongson: Factor out loongson_card_acpi_find_device() functionBinbin Zhou1-24/+31
The operations for reading the cpu and codec nodes in loongson_card_parse_acpi() are similar, so we convert them into a simple helper function called loongson_card_acpi_find_device(). Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn> Link: https://patch.msgid.link/3b7da05e5fd4326e7944aa749bf06dd44e964f6c.1725844530.git.zhoubinbin@loongson.cn Signed-off-by: Mark Brown <broonie@kernel.org>