summaryrefslogtreecommitdiff
path: root/sound/soc
AgeCommit message (Collapse)AuthorFilesLines
2023-10-26ASoC: codecs: adav80x: Handle component name prefixKrzysztof Kozlowski1-1/+1
Use snd_soc_dapm_widget_name_cmp() helper when comparing widget names, to include also the component's name prefix. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20231023095428.166563-4-krzysztof.kozlowski@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-26ASoC: codecs: adau1373: Handle component name prefixKrzysztof Kozlowski1-1/+1
Use snd_soc_dapm_widget_name_cmp() helper when comparing widget names, to include also the component's name prefix. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Nuno Sa <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20231023095428.166563-3-krzysztof.kozlowski@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-26ASoC: codecs: 88pm860x: Handle component name prefixKrzysztof Kozlowski1-2/+2
Use snd_soc_dapm_widget_name_cmp() helper when comparing widget names, to include also the component's name prefix. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20231023095428.166563-2-krzysztof.kozlowski@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add machine driver support for acp7.0Syed Saba Kareem1-0/+9
add machine driver support for ACP7.0 on legacy stack. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-13-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: Add pci legacy driver support for acp7.0 platformSyed Saba Kareem5-1/+273
Add pci legacy driver support and create platform driver for acp7.0 platform. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-12-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: change acp power on mask macro valueSyed Saba Kareem1-1/+1
change acp power on mask macro value so that same macro can be used for all amd platforms. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-11-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: change acp-deinit function argumentsSyed Saba Kareem3-6/+6
acp-deinit function will not be same for all platforms. To make platform specific changes in acp-deinit function, instead of passing base address pass chip structure which contains acp_rev feild. chip->acp_rev will be used to add platform specific code in acp-deinit(). Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-10-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add machine driver support for pdm use caseSyed Saba Kareem2-11/+30
add pdm use case machine driver support Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-9-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add condition check for i2s clock generationSyed Saba Kareem2-6/+18
for only PDM endpoint i2s master clock is not required. Add a condition check for the same based on chip flag value. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-8-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add platform and flag data to acp data structureSyed Saba Kareem4-1/+13
add name of the platform and flag data in private data structure. name of the platform will be used to differentiate platforms where as flag will be used to know what kind of endpoint configuration is selected where its legacy(I2S + PDM) or only ACP PDM. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-7-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add code for scanning acp pdm controllerSyed Saba Kareem5-1/+86
Add common code for scanning acp pdm controller and create platform device for the same. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-6-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add Kconfig options for acp6.3 based platform driverSyed Saba Kareem2-0/+13
ACP6.3 based platform legacy drivers can be built by selecting necessary kernel config option. This patch enables build support of the same. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-5-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add machine driver support for acp6.3 platformSyed Saba Kareem2-0/+16
add legacy machine driver support for acp6.3 based platform. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-4-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: add i2s clock generation support for acp6.3 based platformsSyed Saba Kareem1-3/+16
Add I2S LRCLK & BCLK generation code for ACP6.3 based platforms. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-3-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: refactor acp i2s clock generation codeSyed Saba Kareem2-39/+32
Refactor acp i2s LRCLK,BCLK generation code and move to commnon file. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-2-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: amd: acp: Add acp6.3 pci legacy driver supportSyed Saba Kareem4-0/+326
Add pci legacy driver support and create platform driver for acp6.3 based platforms. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/20231021145110.478744-1-Syed.SabaKareem@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: Intel: Skylake: add an error code check in skl_pcm_triggerSu Hui1-0/+3
skl_decoupled_trigger() can return error code like -EPIPE if failed, add check for this. Signed-off-by: Su Hui <suhui@nfschina.com> Link: https://lore.kernel.org/r/20231020092619.210520-1-suhui@nfschina.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: codecs: wcd938x: use defines for entries in snd_soc_dai_driver arrayKrzysztof Kozlowski1-2/+2
snd_soc_dai_driver array in wcd938x driver has two entries whose order must match order of wcd938x->sdw_priv array. The wcd938x_bind() and wcd938x_codec_set_sdw_stream() rely on this order. wcd938x->sdw_priv array is indexed by enum with AIF1_PB and AIF1_CAP, so use the same defines instead of raw numners for snd_soc_dai_driver array. No functional impact. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20231019144108.42853-1-krzysztof.kozlowski@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: qcom: q6apm-lpass-dais: pass max number of channels to AudioreachKrzysztof Kozlowski1-2/+2
Using the params_channels() helper when setting hw_params, results in passing to Audioreach minimum number of channels valid for given hardware. This is not valid for any hardware which sets minimum channels to two and maximum to something bigger, like four channels. Instead pass the maximum number of supported channels to allow playback of multi-channel formats. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20231017161429.431663-1-krzysztof.kozlowski@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: qcom: sc7180: Add support for qdsp6 baked soundNikita Travkin1-22/+173
Some sc7180 devices use audio adsp to play sound. The setup for this adsp is similar to the dirrect lpass usage but requires the use of different link ids and clocks. This commit adds support for the qdsp based audio, reusing the common parts like audio codec setup and jack creation. Since the setup is mostly generic and codec specific setup is guarded behind a check, a generic compatible is added, similar to other platforms. Even though those changes target Acer Aspire 1 as the only user of the adsp audio on this platform present upstream at the moment of the commit, those changes should be either dirrectly compatible or trivially expandable to the other devices that will be added in the future. Signed-off-by: Nikita Travkin <nikita@trvn.ru> Link: https://lore.kernel.org/r/20231020-sc7180-qdsp-sndcard-v1-2-157706b7d06f@trvn.ru Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: Intel: bytcr_wm5102: Add BYT_WM5102_IN_MAP quirkHans de Goede1-7/+53
Unlike all designs supported sofar the Lenovo Yoga Tab 3 YT3-X90 does not have its internal microphone (intmic) on IN3L with the headset microphone on IN1L. Instead this tablet has the intmic on IN1L and the hsmic on IN2L. Add a BYT_WM5102_IN_MAP quirk mechanism to allow selecting between different input maps and add support for both setups with the current settings being the default map. The new INTMIC_IN1L_HSMIC_IN2L map is enabled by default on CHT because the Lenovo Yoga Tab 3 YT3-X90 model is the only Cherry Trail design currently supported. If different CHT designs turn up which need different input maps we can add DMI quirks to select a different map later. The userspace UCM profile also needs to know about this so extend the components string with this info too. Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20231025143513.291753-5-hdegoede@redhat.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: Intel: bytcr_wm5102: Add BYT_WM5102_OUT_MAP quirkHans de Goede1-9/+63
Some x86 WM5102 designs don't use the SPK pins for speaker output instead they use the HPOUT2L + HPOUT2R for the speakers. Add an BYT_WM5102_OUT_MAP quirk mechanism to allow selecting between 2 output maps, one for the speakers on the SPK output pins and one for the speakers on the HPOUT2 pins. The new HPOUT2 map is enabled by default on CHT because this is used on the Lenovo Yoga Tab 3 YT3-X90 model which is the only Cherry Trail design currently supported. If different CHT designs turn up which need different output maps we can add DMI quirks to select a different map later. The userspace UCM profile also needs to know about this so setup a components string with this info too. While at it also drop the unused "Line Out" route. Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20231025143513.291753-4-hdegoede@redhat.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: Intel: bytcr_wm5102: Add BYT_WM5102_MCLK_19_2MHZ quirkHans de Goede1-5/+13
The Cherry Trail SoC only supports 19200000 as clk-frequency for the pmc_plt_clk used for the audio codec. Add a BYT_WM5102_MCLK_19_2MHZ quirk for this and enable this by default on Cherry Trail SoCs. Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20231025143513.291753-3-hdegoede@redhat.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: Intel: bytcr_wm5102: Add BYT_WM5102_SSP2 quirkHans de Goede1-13/+80
Add the standard intel board file quirk mechanism also used in many other intel board drivers and add a BYT_WM5102_SSP2 quirk setting for designs using SSP2 instead of SSP0. And enable the new BYT_WM5102_SSP2 quirk on Cherry Trail devices since those always use SSP2. The logging of the quirks uses dev_info_once() because probe() may run multiple times because of snd_soc_register_card() returning -EPROBE_DEFER. Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20231025143513.291753-2-hdegoede@redhat.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: codecs: Add aw88399 amplifier driverWeidong Wang4-0/+2526
Add i2c and amplifier registration for aw88399 and their associated operation functions. Signed-off-by: Weidong Wang <wangweidong.a@awinic.com> Link: https://lore.kernel.org/r/20231025112625.959587-4-wangweidong.a@awinic.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: codecs: Add code for bin parsing compatible with aw88399Weidong Wang2-0/+4
Add aw88399 compatible code to the aw88395_lib.c file so that it can parse aw88399's bin file. Reviewed-by: Herve Codina <herve.codina@bootlin.com> Signed-off-by: Weidong Wang <wangweidong.a@awinic.com> Link: https://lore.kernel.org/r/20231025112625.959587-3-wangweidong.a@awinic.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-25ASoC: SOF: Make return of remove_late void, tooTakashi Iwai4-9/+5
Like the change we've done for remove callback, the newly introduced remove_late callback should be changed to void return, too. Fixes: 17baaa1f950b ("ASoC: SOF: core: Add probe_early and remove_late callbacks") Acked-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20231023153605.863-1-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
2023-10-24ASoC: Intel: bytcr_wm5102: Add support for Lenovo Yoga Tab 3 Pro YT3-X90Hans de Goede1-5/+6
The Lenovo Yoga Tab 3 Pro YT3-X90 x86 tablet, which ships with Android with a custom kernel as factory OS, does not list the used WM5102 codec inside its DSDT. So acpi_dev_get_first_match_dev() is going to fail on this board. Fallback to using "spi-$(mach->id)" as codec device name in this case to allow bytcr_wm5102 to work on these tablets. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20231021211534.114991-2-hdegoede@redhat.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-24ASoC: Intel: soc-acpi-cht: Add Lenovo Yoga Tab 3 Pro YT3-X90 quirkHans de Goede1-0/+43
The Lenovo Yoga Tab 3 Pro YT3-X90 x86 tablet, which ships with Android with a custom kernel as factory OS, does not list the used WM5102 codec inside its DSDT. Workaround this with a new snd_soc_acpi_intel_baytrail_machines[] entry which matches on the SST id instead of the codec id like nocodec does, combined with using a machine_quirk callback which returns NULL on other machines to skip the new entry on other machines. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20231021211534.114991-1-hdegoede@redhat.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-24ASoC: mediatek: mt8186: remove redundant assignments to variable tdm_conColin Ian King1-2/+0
There are two occurrences where variable tdm_con is being initialized to zero and the next statement re-assigns tdm_con to a new value. The initializations are redundant and can be removed. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20231023151704.670240-1-colin.i.king@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-24ASoC: mediatek: Remove redundant code and addMark Brown2-35/+31
Merge series from Maso Huang <maso.huang@mediatek.com>: Add support for sample rate checking on the MT7986.
2023-10-24ASoC: mediatek: mt7986: add sample rate checkerMaso Huang1-4/+19
mt7986 only supports 8/12/16/24/32/48/96/192 kHz Signed-off-by: Maso Huang <maso.huang@mediatek.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20231024035019.11732-4-maso.huang@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-24ASoC: mediatek: mt7986: remove the mt7986_wm8960_priv structureMaso Huang1-21/+12
Remove the mt7986_wm8960_priv structure. Signed-off-by: Maso Huang <maso.huang@mediatek.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20231024035019.11732-3-maso.huang@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-24ASoC: mediatek: mt7986: drop the remove callback of mt7986_wm8960Maso Huang1-10/+0
Drop the remove callback of mt7986_wm8960. Signed-off-by: Maso Huang <maso.huang@mediatek.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://lore.kernel.org/r/20231024035019.11732-2-maso.huang@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: codecs: rt298: remove redundant assignment to d_len_codeColin Ian King1-1/+0
Variable d_len_code is being initialized to zero and then re-assigned a different value in all the valid cases in the following switch statement. The only place it is not being assigned a value is on the return for a default case and in this case it does not need to be assigned. The initialization is redundant and can be removed. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Link: https://lore.kernel.org/r/20231023154917.671595-1-colin.i.king@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: ti: ams-delta: Allow it to be test compiledJanusz Krzysztofik2-4/+3
The driver is now built only when MACH_AMS_DELTA is selected, which requires a very specific selection of ARCH settings. As a consequence, it gets very little attention from build-bots, if not none. Drop the driver dependency on <asm/mach-types.h>, no longer required since conversion to snd_soc_register_card() and drop of machine_is_ams_delta(). With that in place, allow the driver to be built in any environment as long as COMPILE_TEST is selected. Take care of not selecting SND_SOC_OMAP_MCBSP if COMMON_CLK is not selected. Signed-off-by: Janusz Krzysztofik <jmkrzyszt@gmail.com> Link: https://lore.kernel.org/r/20231008135601.542356-1-jmkrzyszt@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: Merge up v6.6-rc7Mark Brown6-10/+12
Get fixes needed so we can enable build of ams-delta in more configurations.
2023-10-23ASoc: Another series to convert to structMark Brown23-40/+26
Merge series from Uwe Kleine-König <u.kleine-koenig@pengutronix.de>: This is another series to convert ASoC drivers to use struct platform_driver:remove_new(). The rockchip one was already send before but with a wrong subject prefix, the cs42l43 driver is newer than the last series. The remaining five patches are for driver combos that my coccinelle patch failed to detect before.
2023-10-23ASoC: SOF: amd: add option to use sram for data bin loadingVijendar Mukunda2-7/+49
Provide an option to load DSP data bin to ACP SRAM. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://lore.kernel.org/r/20231020062822.3913760-5-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: SOF: amd: refactor acp dram usage for data bin loadingVijendar Mukunda2-17/+22
DSP data bin can be loaded in to ACP DRAM or ACP SRAM. Add conditional check for ACP DRAM usage for data bin loading. Rename DRAM base address macro to have symmetry. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://lore.kernel.org/r/20231020062822.3913760-4-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: SOF: amd: increase DSP cache window rangeVijendar Mukunda1-1/+1
Increase DSP cache window range to 2.5MB to align with ACP memory. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://lore.kernel.org/r/20231020062822.3913760-3-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: SOF: amd: add support for acp6.3 based platformVijendar Mukunda5-0/+267
Add SOF support for ACP6.3 version based platform Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://lore.kernel.org/r/20231020062822.3913760-2-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: amd: Add acpi machine id for acp6.3 version based platformVijendar Mukunda2-0/+13
Add acpi machine id for ACP6.3 version based platform and configure driver data to enable SOF sound card support on newer boards. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://lore.kernel.org/r/20231020062822.3913760-1-Vijendar.Mukunda@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: es8328: Use rounded rate for es8328_set_sysclk()Chris Morgan1-1/+8
I have a board (RK3588 based) that sets the sysclk to 12287999. The es8328 driver fails to match this to the 12288000 rate and fails to load. Allow the rate comparison to work if the frequency is within 100hz by dividing it by 100 and rounding it, then multiplying it back by 100. Note the 100hz value was chosen arbitrarily by me, but it has only been tested with a 1hz difference. Signed-off-by: Chris Morgan <macromorgan@hotmail.com> Link: https://lore.kernel.org/r/20231020171539.65513-1-macroalpha82@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: codecs: Modify max_register usage errorWeidong Wang1-1/+1
Modify the value of max_register, otherwirse the AW88261_EFRL1_REG register will not be accessible. Signed-off-by: Weidong Wang <wangweidong.a@awinic.com> Link: https://lore.kernel.org/r/20231020083426.302925-3-wangweidong.a@awinic.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: uniphier: Make uniphier_aio_remove() return voidUwe Kleine-König4-6/+4
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is (mostly) ignored and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new() which already returns void. uniphier_aio_remove() returned zero unconditionally. Make it return void instead and convert all users to struct platform_device::remove_new(). Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20231013221945.1489203-16-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: qcom: lpass: Make asoc_qcom_lpass_cpu_platform_remove() return voidUwe Kleine-König6-9/+6
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is (mostly) ignored and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new() which already returns void. asoc_qcom_lpass_cpu_platform_remove() returned zero unconditionally. Make it return void instead and convert all users to struct platform_device::remove_new(). Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20231013221945.1489203-15-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: meson: Make meson_card_remove() return voidUwe Kleine-König4-6/+4
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is (mostly) ignored and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new() which already returns void. meson_card_remove() returned zero unconditionally. Make it return void instead and convert all users to struct platform_device::remove_new(). Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20231013221945.1489203-14-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: simple-card-utils: Make simple_util_remove() return voidUwe Kleine-König6-8/+6
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is (mostly) ignored and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new() which already returns void. simple_util_remove() returned zero unconditionally. Make it return void instead and convert all users to struct platform_device::remove_new(). Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Herve Codina <herve.codina@bootlin.com> Link: https://lore.kernel.org/r/20231013221945.1489203-13-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
2023-10-23ASoC: starfive/jh7110-pwmdac: Convert to platform remove callback returning voidUwe Kleine-König1-3/+2
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is ignored (apart from emitting a warning) and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new(), which already returns void. Eventually after all drivers are converted, .remove_new() will be renamed to .remove(). Trivially convert this driver from always returning zero in the remove callback to the void returning variant. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20231013221945.1489203-12-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>