summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs
AgeCommit message (Collapse)AuthorLines
2026-03-05Merge tag 'asoc-fix-v7.0-rc2' of ↵Takashi Iwai-5/+28
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Fixes for v7.0 A moderately large pile of fixes, though none of them are super major, plus a few new quirks and device IDs.
2026-03-01ASoC: cs35l56: Suppress pointless warning about number of GPIO pullsRichard Fitzgerald-2/+2
In cs35l56_process_xu_onchip_speaker_id() the warning that the number of pulls != number of GPIOs should only be printed if pulls are defined. Pull settings are optional because there would normally be an external resistor providing the pull. The warning would still be true if pulls are not defined, but in that case is just log noise. While we're changing that block of code, also fix the indenting of the arguments to the dev_warn(). Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260226113511.1768838-1-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-03-01ASoC: rt1321: fix DMIC ch2/3 mask issueShuming Fan-2/+3
This patch fixed the DMIC ch2/3 mask missing problem. Signed-off-by: Shuming Fan <shumingf@realtek.com> Link: https://patch.msgid.link/20260225091210.3648905-1-shumingf@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-03-01ASoC: cs35l56: Only patch ASP registers if the DAI is part of a DAIlinkRichard Fitzgerald-1/+23
Move the ASP register patches to a separate struct and apply this from the ASP DAI probe() function so that the registers are only patched if the DAI is part of a DAI link. Some systems use the ASP as a special-purpose interconnect and on these systems the ASP registers are configured by a third party (the firmware, the BIOS, or another device using the amp's secondary host control interface). If the machine driver does not hook up the ASP DAI then the ASP registers must be omitted from the patch to prevent overwriting the third party configuration. If the machine driver includes the ASP DAI in a DAI link, this implies that the machine driver and higher components (such as alsa-ucm) are taking ownership of the ASP. In this case the ASP registers are patched to known defaults and the machine driver should configure the ASP. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260226110137.1664562-1-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-28ALSA: hda/tas2781: A workaround solution to lower-vol issue among lower ↵Shenghao Ding-0/+94
calibrated-impedance micro-speaker on TAS2781 On TAS2781, if the Speaker calibrated impedance is lower than default value hard-coded inside the TAS2781, it will cuase vol lower than normal. In order to fix this issue, the parameter of SineGainI need updating. Signed-off-by: Shenghao Ding <shenghao-ding@ti.com> Tested-by: Matthew Schwartz <matthew.schwartz@linux.dev> Link: https://patch.msgid.link/20260227144641.1243-1-shenghao-ding@ti.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2026-02-23ASoC: cs42l43: Report insert for exotic peripheralsCharles Keepax-0/+1
For some exotic peripherals the type detect can return a reserved value of 0x4. This will currently return an error and not report anything to user-space, update this to report the insert normally. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20260223093616.3800350-1-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-22Convert remaining multi-line kmalloc_obj/flex GFP_KERNEL usesKees Cook-7/+6
Conversion performed via this Coccinelle script: // SPDX-License-Identifier: GPL-2.0-only // Options: --include-headers-for-types --all-includes --include-headers --keep-comments virtual patch @gfp depends on patch && !(file in "tools") && !(file in "samples")@ identifier ALLOC = {kmalloc_obj,kmalloc_objs,kmalloc_flex, kzalloc_obj,kzalloc_objs,kzalloc_flex, kvmalloc_obj,kvmalloc_objs,kvmalloc_flex, kvzalloc_obj,kvzalloc_objs,kvzalloc_flex}; @@ ALLOC(... - , GFP_KERNEL ) $ make coccicheck MODE=patch COCCI=gfp.cocci Build and boot tested x86_64 with Fedora 42's GCC and Clang: Linux version 6.19.0+ (user@host) (gcc (GCC) 15.2.1 20260123 (Red Hat 15.2.1-7), GNU ld version 2.44-12.fc42) #1 SMP PREEMPT_DYNAMIC 1970-01-01 Linux version 6.19.0+ (user@host) (clang version 20.1.8 (Fedora 20.1.8-4.fc42), LLD 20.1.8) #1 SMP PREEMPT_DYNAMIC 1970-01-01 Signed-off-by: Kees Cook <kees@kernel.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-02-21Convert more 'alloc_obj' cases to default GFP_KERNEL argumentsLinus Torvalds-22/+11
This converts some of the visually simpler cases that have been split over multiple lines. I only did the ones that are easy to verify the resulting diff by having just that final GFP_KERNEL argument on the next line. Somebody should probably do a proper coccinelle script for this, but for me the trivial script actually resulted in an assertion failure in the middle of the script. I probably had made it a bit _too_ trivial. So after fighting that far a while I decided to just do some of the syntactically simpler cases with variations of the previous 'sed' scripts. The more syntactically complex multi-line cases would mostly really want whitespace cleanup anyway. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-02-21Convert 'alloc_flex' family to use the new default GFP_KERNEL argumentLinus Torvalds-2/+2
This is the exact same thing as the 'alloc_obj()' version, only much smaller because there are a lot fewer users of the *alloc_flex() interface. As with alloc_obj() version, this was done entirely with mindless brute force, using the same script, except using 'flex' in the pattern rather than 'objs*'. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-02-21Convert 'alloc_obj' family to use the new default GFP_KERNEL argumentLinus Torvalds-17/+17
This was done entirely with mindless brute force, using git grep -l '\<k[vmz]*alloc_objs*(.*, GFP_KERNEL)' | xargs sed -i 's/\(alloc_objs*(.*\), GFP_KERNEL)/\1)/' to convert the new alloc_obj() users that had a simple GFP_KERNEL argument to just drop that argument. Note that due to the extreme simplicity of the scripting, any slightly more complex cases spread over multiple lines would not be triggered: they definitely exist, but this covers the vast bulk of the cases, and the resulting diff is also then easier to check automatically. For the same reason the 'flex' versions will be done as a separate conversion. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-02-21treewide: Replace kmalloc with kmalloc_obj for non-scalar typesKees Cook-53/+54
This is the result of running the Coccinelle script from scripts/coccinelle/api/kmalloc_objs.cocci. The script is designed to avoid scalar types (which need careful case-by-case checking), and instead replace kmalloc-family calls that allocate struct or union object instances: Single allocations: kmalloc(sizeof(TYPE), ...) are replaced with: kmalloc_obj(TYPE, ...) Array allocations: kmalloc_array(COUNT, sizeof(TYPE), ...) are replaced with: kmalloc_objs(TYPE, COUNT, ...) Flex array allocations: kmalloc(struct_size(PTR, FAM, COUNT), ...) are replaced with: kmalloc_flex(*PTR, FAM, COUNT, ...) (where TYPE may also be *VAR) The resulting allocations no longer return "void *", instead returning "TYPE *". Signed-off-by: Kees Cook <kees@kernel.org>
2026-02-20Merge tag 'sound-fix-7.0-rc1' of ↵Linus Torvalds-3/+47
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound fixes from Takashi Iwai: "Here are a bunch of updates, but there should be no big surprises; mostly device-specific quirks and fix-ups or non-code changes: - Quirks for ASoC AMD, HD-audio and USB-audio - Fixes in ASoC fsl, rockchip, renesas, aw codecs - Fixes for USB-audio packet handling in the implicit feedback mode - Updates of SPDX license IDs in some files" * tag 'sound-fix-7.0-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (28 commits) ASoC: rockchip: i2s-tdm: Use param rate if not provided by set_sysclk ALSA: hda/hdmi: Add quirk for TUXEDO IBS14G6 ASoC: dt-bindings: asahi-kasei,ak5558: Fix the supply names ASoC: dt-bindings: asahi-kasei,ak4458: Fix the supply names ASoC: dt-bindings: asahi-kasei,ak4458: set unevaluatedProperties:false ASoC: amd: amd_sdw: add machine driver quirk for Lenovo models ASoC: amd: acp: Add ACP7.0 match entries for Realtek parts ALSA: echoaudio: Add SPDX ids to some files ALSA: isa: Add SPDX id lines to some files ALSA: core: Add SPDX license id to files ASoC: tas2783A: add explicit port prepare handling ASoC: renesas: rz-ssi: Fix playback and capture ALSA: hda/realtek: Fix headset mic on ASUS Zenbook 14 UX3405MA ALSA: hda/conexant: Fix headphone jack handling on Acer Swift SF314 ASoC: qcom: sm8250: Add quinary MI2S support ASoC: amd: yc: Add DMI quirk for ASUS Vivobook Pro 15X M6501RR ALSA: usb-audio: Avoid potentially repeated XRUN error messages ALSA: usb-audio: Add sanity check for OOB writes at silencing ALSA: usb-audio: Optimize the copy of packet sizes for implicit fb handling ALSA: usb-audio: Update the number of packets properly at receiving ...
2026-02-17Merge tag 'soundwire-7.0-rc1' of ↵Linus Torvalds-69/+23
git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire Pull soundwire updates from Vinod Koul: - support for Qualcomm v2.2.0 controllers - bus method updates for .probe(), .remove() and .shutdown() and remove function return value updates - Avell B.ON dmi-quirks mapping - mark cs42l45 codec as wake capable * tag 'soundwire-7.0-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire: soundwire: intel_ace2x: add SND_HDA_CORE dependency dt-bindings: soundwire: qcom: Add SoundWire v2.2.0 compatible soundwire: Use bus methods for .probe(), .remove() and .shutdown() soundwire: Make remove function return no value soundwire: dmi-quirks: add mapping for Avell B.ON (OEM rebranded of NUC15) soundwire: qcom: Use guard to avoid mixing cleanup and goto soundwire: intel_auxdevice: add cs42l45 codec to wake_capable_list
2026-02-17ASoC: tas2783A: add explicit port prepare handlingNiranjan H Y-0/+43
TAS2783a required port prepare bits to be set during playback even when it is using simplified CP_SM. Normally, SoundWire core handles prepare sequencing automatically depending on the type of the device available. For simplified CP_SM there is no need to set the prepare bits. However, due to a hardware limitation in TAS2783A, the port must still be explicitly prepared and de-prepared by the driver to ensure reliable playback. Add a custom .port_prep() callback to program DPN_PREPARECTRL during PRE_PREP and PRE_DEPREP operations. Signed-off-by: Niranjan H Y <niranjan.hy@ti.com> Link: https://patch.msgid.link/20260214104710.632-1-niranjan.hy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-12ASoC: codecs: aw88261: Fix erroneous bitmask logic in Awinic initAlexandre Ferrieux-1/+2
The aw88261_dev_reg_update() function sets the Awinic registers in a rather nonuniform way: - most registers get directly overwritten from the firmware blob - but a handful of them need more delicate logic to preserve some bits from their current value, according to a register- specific mask For the latter, the logic is basically NEW = (OLD & MASK) | (VAL & ~MASK) However, the ~MASK value is hand-computed, and in the specific case of the SYSCTRL register, in a buggy way. This patch restores the proper ~MASK value. Fixes: 028a2ae25691 ("ASoC: codecs: Add aw88261 amplifier driver") Signed-off-by: Alexandre Ferrieux <alexandre.ferrieux@orange.com> Link: https://patch.msgid.link/20260211-aw88261-fwname-v1-1-e24e833a019d@fairphone.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-10ASoC: Merge up releaseMark Brown-6/+33
We need to fix some commits that went into the final release.
2026-02-10ASoC: rt721-sdca: Fix issue of fail to detect OMTP jack typeJack Yu-2/+2
Add related HP-JD settings to fix issue of fail to detect OMTP jack type. Signed-off-by: Jack Yu <jack.yu@realtek.com> Link: https://patch.msgid.link/20260210074335.2337830-1-jack.yu@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-09Merge tag 'asoc-v6.20' of ↵Takashi Iwai-1359/+5354
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Updates for v7.0 This release is almost all abut driers, there's very little core work here, although some of that driver work is in more generic areas like SDCA and SOF: - Generic SDCA support for reporting jack events. - Continuing platform support, cleanup and feature improements for the AMD, Intel, Qualcomm and SOF code. - Platform description improvements for the Cirrus drivers. - Support for NXP i.MX952, Realtek RT1320 and RT5575, and Sophogo CV1800B. We also pulled in one small SPI API update and some more substantial regmap work (cache description improvements) for use in drivers.
2026-02-05ASoC: cs35l56: More support for new Dell laptopsMark Brown-4/+1280
Merge series from Richard Fitzgerald <rf@opensource.cirrus.com>: Some new Dell models use spare pins on the amp as a binary integer value to indicate the speaker type. The driver must use this to select the correct firmware files for the hardware. Patch #1 is the new support. The other patches are for KUnit testing.
2026-02-05ASoC: cs35l56: KUnit tests for parsing and using onchip GPIOsRichard Fitzgerald-0/+273
Add KUnit test cases for: - cs35l56_process_xu_properties() which reads the onchip GPIO definitions. - cs35l56_set_fw_name() calls functions to configure and set the GPIOs. - cs35l56_set_fw_name() saves the ID value in cs35l56_priv.speaker_id. - cs35l56_set_fw_name() does not overwrite a speaker ID that was already found some other way. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260205164838.1611295-4-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-05ASoC: cs35l56-shared: KUnit tests for onchip speaker ID gpiosRichard Fitzgerald-0/+701
Add KUnit testing of: cs35l56_check_and_save_onchip_spkid_gpios() cs35l56_configure_onchip_spkid_pads() cs35l56_read_onchip_spkid() The test consists of: - A mock regmap that simulates the pad and pin config registers. - Parameterization of the pin list, pulls list, a simulated value for each pin and the speaker ID value that this should produce. - A self-test of the simulated pin and GPIO registers. - A test that the value returned by cs35l56_read_onchip_spkid() is correct. - A test that the pin pull-up/down are set correctly by cs35l56_configure_onchip_spkid_pads() - A test that cs35l56_configure_onchip_spkid_pads() and cs35l56_read_onchip_spkid(0 return the expected values if cs35l56_base->num_onchip_spkid_gpios == 0. - A test that cs35l56_check_and_save_onchip_spkid_gpios() saves the configuration. - A test that cs35l56_check_and_save_onchip_spkid_gpios() rejects illegal GPIO numbers. - A test that cs35l56_check_and_save_onchip_spkid_gpios() rejects illegal pull types. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260205164838.1611295-3-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-05ASoC: cs35l56: Support for reading speaker ID from on-chip GPIOsRichard Fitzgerald-4/+306
Add support for using the state of pins on the amplifier to indicate the type of speaker fitted. Previously, where there were alternate speaker vendors, this was indicated using host CPU GPIOs. Some new Dell models use spare pins on the CS35L63 as GPIOs for the speaker ID detection. Cirrus-specific SDCA Disco properties provide a list of the pins to be used, and pull-up/down settings for the pads. This list is ordered, MSbit to LSbit. The code to set the firmware filename has been modified to check for using chip pins for speaker ID. The entire block of code to set firmware name has been moved out of cs35l56_component_probe() into its own function to make it easier to KUnit test. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260205164838.1611295-2-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-05ASoC: cs4271: Fix resource leak in cs4271_soc_resume()Harshit Mogalapalli-3/+9
Smatch detects this resource leak: sound/soc/codecs/cs4271.c:548 cs4271_soc_resume() warn: 'cs4271->clk' from clk_prepare_enable() not released on lines: 540,546. Instead of direct returns, unprepare the clock and disable regulators on the error paths. Fixes: cf6bf51b5325 ("ASoC: cs4271: Add support for the external mclk") Fixes: 9a397f473657 ("ASoC: cs4271: add regulator consumer support") Signed-off-by: Harshit Mogalapalli <harshit.m.mogalapalli@oracle.com> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Acked-by: Herve Codina <herve.codina@bootlin.com> Reviewed-by: Alexander Sverdlin <alexander.sverdlin@gmail.com> Link: https://patch.msgid.link/20260110195337.2522347-1-harshit.m.mogalapalli@oracle.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-04ASoC: tas2781: Put three different calibrated data solution into the same ↵Shenghao Ding-36/+113
data structure TAS2781 driver supports three solutions of calibrated data. The first is from the driver itself: driver reads the calibrated files directly during probe; The second is from user space: during init of audio hal, the audio hal will pass the calibrated data via kcontrol interface. Driver will store this data in "struct calidata" for use. The third is from UEFI, mainly used in hda device. These three solutions save the calibrated data into different data structures. It is time to put them together into "struct calidata" for use. Signed-off-by: Shenghao Ding <shenghao-ding@ti.com> Link: https://patch.msgid.link/20260202102757.532-1-shenghao-ding@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-03ASoC: rt1320: fix intermittent no-sound issueShuming Fan-0/+2
This patch adds a setting to resolve the intermittent no-sound issue. Signed-off-by: Shuming Fan <shumingf@realtek.com> Link: https://patch.msgid.link/20260203084827.768238-1-shumingf@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: es8328: error handling and resume fixesMark Brown-43/+73
Merge series from Hsieh Hung-En <hungen3108@gmail.com>: This series fixes some issues and improves robustness in the es8328 driver.
2026-02-02Anbernic RG-DS AW87391 Speaker AmpsMark Brown-9/+254
Merge series from Chris Morgan <macroalpha82@gmail.com>: Add support for the Anbernic RG-DS Speaker Amplifiers. The Anbernic RG-DS uses two AW87391 ICs at 0x58 and 0x5B on i2c2. However, the manufacturer did not provide a firmware file, only a sequence of register writes to each device to enable and disable them. Add support for this *specific* configuration in the AW87390 driver. Since we are relying on a device specific sequence I am using a device specific compatible string. This driver does not currently support the aw87391 for any other device as I have none to test with valid firmware. Attempts to create firmware with the AwinicSCPv4 have not been successful.
2026-02-02ASoC: wcd-mbhc-v2: remove unnecessary module_init/exit functionsEthan Nelson-Moore-12/+0
The wcd-mbhc-v2 driver has unnecessary empty module_init and module_exit functions. Remove them. Note that if a module_init function exists, a module_exit function must also exist; otherwise, the module cannot be unloaded. Signed-off-by: Ethan Nelson-Moore <enelsonmoore@gmail.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Link: https://patch.msgid.link/20260131020111.46108-1-enelsonmoore@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: es8328: Add error unwind in resumeHsieh Hung-En-2/+8
Handle failures in the resume path by unwinding previously enabled resources. If enabling regulators or syncing the regcache fails, disable regulators and unprepare the clock to avoid leaking resources and leaving the device in a partially resumed state. Signed-off-by: Hsieh Hung-En <hungen3108@gmail.com> Link: https://patch.msgid.link/20260130160017.2630-6-hungen3108@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: es8328: Use cached regmap on resumeHsieh Hung-En-6/+3
Use the regmap stored in the driver private data when restoring the register cache on resume, instead of looking it up from the device. This keeps the resume path consistent with the regmap instance used by the driver and avoids relying on a separate dev_get_regmap() lookup. Signed-off-by: Hsieh Hung-En <hungen3108@gmail.com> Link: https://patch.msgid.link/20260130160017.2630-5-hungen3108@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: es8328: Check errors in set_dai_fmt()Hsieh Hung-En-9/+21
Check and propagate return values from snd_soc_component_update_bits() in es8328_set_dai_fmt(). This avoids silent failures when register updates fail and ensures the DAI format is not left in an inconsistent state. Signed-off-by: Hsieh Hung-En <hungen3108@gmail.com> Link: https://patch.msgid.link/20260130160017.2630-4-hungen3108@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: es8328: Propagate errors in set_bias_level()Hsieh Hung-En-23/+37
Register writes and updates in set_bias_level() ignored return values, potentially masking I/O failures during bias level transitions. Check and propagate errors from component register writes and updates. Signed-off-by: Hsieh Hung-En <hungen3108@gmail.com> Link: https://patch.msgid.link/20260130160017.2630-3-hungen3108@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: es8328: Fix DAC deemphasis control handlingHsieh Hung-En-3/+4
The DAC deemphasis control updated the hardware before updating the cached state, causing the previous setting to be applied. Update the cached deemphasis state first and then apply the setting. Also check and propagate errors from es8328_set_deemph() in hw_params(). Signed-off-by: Hsieh Hung-En <hungen3108@gmail.com> Link: https://patch.msgid.link/20260130160017.2630-2-hungen3108@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: codecs: aw87390: Add Anbernic RG-DS amp driverChris Morgan-8/+253
Add support for Anbernic's RG-DS audio amplifiers, powered by Awinic AW87391 amplifier ICs. These chips typically require an init sequence provided by firmware, but the manufacturer did not provide firmware in this case. As a result we had to hard-code the init sequence and use a device specific binding (rather than a binding just for the aw87391). Signed-off-by: Chris Morgan <macromorgan@hotmail.com> Link: https://patch.msgid.link/20260128174608.1498-3-macroalpha82@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: rt5575: fix SPI dependencyArnd Bergmann-1/+2
The rt5575 driver fails to link when SPI support is in a loadable module but the codec is built-in: x86_64-linux-ld: vmlinux.o: in function `rt5575_i2c_probe': rt5575.c:(.text+0x9792ce): undefined reference to `rt5575_spi_get_device' rt5575.c:(.text+0x979332): undefined reference to `rt5575_spi_fw_load' Change the symbol in to a 'bool' and add a dependency that rules out the broken configuration. Fixes: 420739112e95 ("ASoC: rt5575: Add the codec driver for the ALC5575") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Link: https://patch.msgid.link/20260202095432.1234133-1-arnd@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2026-02-02ASoC: cs42l43: Correct handling of 3-pole jack load detectionCharles Keepax-6/+31
The load detection process for 3-pole jacks requires slightly updated reference values to ensure an accurate result. Update the code to apply different tunings for the 3-pole and 4-pole cases. This also updates the thresholds overall so update the relevant comments to match. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20260130150927.2964664-1-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-30ASoC: codecs: max98390: Check return value of devm_gpiod_get_optional() in ↵Chen Ni-0/+3
max98390_i2c_probe() The devm_gpiod_get_optional() function may return an error pointer (ERR_PTR) in case of a genuine failure during GPIO acquisition, not just NULL which indicates the legitimate absence of an optional GPIO. Add an IS_ERR() check after the function call to catch such errors and propagate them to the probe function, ensuring the driver fails to load safely rather than proceeding with an invalid pointer. Signed-off-by: Chen Ni <nichen@iscas.ac.cn> Link: https://patch.msgid.link/20260130091904.3426149-1-nichen@iscas.ac.cn Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-28ASoC: wm8962: add .set_tdm_slot callback functionShengjiu Wang-4/+31
The slot_width can be different with the params_width(), for example, DSP_A mode, slot_width = 32, but data format is S16_LE, if the word length is configured to be 16, there is no sound on the right speaker. So add .set_tdm_slot() callback function to configure the slot_width and update the word length according to slot_width in hw_params(). Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20260128025955.2562331-1-shengjiu.wang@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-28ASoC: capsuling struct snd_soc_dapm_contextMark Brown-2/+2
Merge series from Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>: Now, all DAPM users are using function to handling it. We can capsuling it. This patchset moves struct snd_soc_dapm_context into soc-dapm.c, and remove un-used functions. Link: https://lore.kernel.org/r/87zf7jrx52.wl-kuninori.morimoto.gx@renesas.com
2026-01-28ASoC: codec: Remove ak4641/pxa2xx-ac97 and convert toMark Brown-649/+0
Merge series from "Peng Fan (OSS)" <peng.fan@oss.nxp.com>: The main goal is to convert drivers to use GPIO descriptors. While reading the code, I think it is time to remove ak4641 and pxa2xx-ac97 driver, more info could be found in commit log of each patch. Then only need to convert sound/arm/pxa2xx-ac97-lib.c to use GPIO descriptors. Not have hardware to test the pxa2xx ac97.
2026-01-27ASoC: codec: Remove ak4641Peng Fan-649/+0
Since commit d6df7df7ae5a0 ("ARM: pxa: remove unused board files"), there has been no in-tree user of the AK4641 codec driver. The last user (HP iPAQ hx4700) was a non-DT PXA board file that instantiated the device via I2C board data; that code was removed as part of the PXA board-file purge. The AK4641 driver was introduced ~2011 and still probes only via the I2C device-ID table ('.id_table'), without an 'of_match_table', so there are no upstream Devicetree users to retain. With no in-tree users left, remove the driver. Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com> Acked-by: Andy Shevchenko <andriy.shevchenko@intel.com> Link: https://patch.msgid.link/20260122-sound-cleanup-v1-1-0a91901609b8@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-26ASoC: codecs: wm8731: Remove unnecessary NULL check before ↵Chen Ni-7/+4
clk_prepare_enable/clk_disable_unprepare clk_prepare_enable() and clk_disable_unprepare() already checked NULL clock parameter. Remove unneeded NULL check for wm8731->mclk here. Signed-off-by: Chen Ni <nichen@iscas.ac.cn> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20260126073528.1826406-1-nichen@iscas.ac.cn Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-26ASoC: codecs: rt1320-sdw: Refactor to reduce stack framesAndy Shevchenko-30/+13
Compiler is not happy about used stack frames in a couple of functions: sound/soc/codecs/rt1320-sdw.c: In function 'rt1320_rae_load': sound/soc/codecs/rt1320-sdw.c:1570:1: error: the frame size of 1336 bytes is larger than 1280 bytes [-Werror=frame-larger-than=] sound/soc/codecs/rt1320-sdw.c: In function 'rt1320_dspfw_load_code': sound/soc/codecs/rt1320-sdw.c:1786:1: error: the frame size of 1520 bytes is larger than 1280 bytes [-Werror=frame-larger-than=] Refactor the code to fix these. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20260124101824.3424793-1-andriy.shevchenko@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-26ASoC: tlv320adcx140: don't use snd_soc_component_get_bias_level()Kuninori Morimoto-2/+2
snd_soc_component_get_bias_level() will be removed. Let's use snd_soc_dapm_get_bias_level() instead. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87o6mpqgxc.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-23ASoC: cs35l56-test: Fix missing module namespace importRichard Fitzgerald-0/+1
The test must import namespace "EXPORTED_FOR_KUNIT_TESTING". Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Fixes: d0ab89951197 ("ASoC: cs35l56: Add KUnit testing of cs35l56_set_fw_suffix()") Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202601221843.kS9IMZ0E-lkp@intel.com/ Link: https://patch.msgid.link/20260123111354.1931986-1-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-23ASoC: codecs: rt56*: Remove IRQF_ONESHOTSebastian Andrzej Siewior-5/+5
Passing IRQF_ONESHOT ensures that the interrupt source is masked until the secondary (threaded) handler is done. If only a primary handler is used then the flag makes no sense because the interrupt can not fire (again) while its handler is running. The flag also disallows force-threading of the primary handler and the irq-core will warn about this. Remove IRQF_ONESHOT from irqflags. Cc: Oder Chiou <oder_chiou@realtek.com> Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: Mark Brown <broonie@kernel.org> Cc: Jaroslav Kysela <perex@perex.cz> Cc: Takashi Iwai <tiwai@suse.com> Cc: linux-sound@vger.kernel.org Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Link: https://patch.msgid.link/20260123113708.416727-13-bigeasy@linutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-21ASoC: cs35l56: Add KUnit testing of cs35l56_set_fw_suffix()Richard Fitzgerald-1/+391
Add a new KUnit test for testing the creation of firmware name qualifiers in the cs35l56 driver. The initial set of test cases are for cs35l56_set_fw_suffix(). Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260121132243.1256019-6-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-21ASoC: cs-amp-lib: Add a Kconfig symbol for enabling test hooksRichard Fitzgerald-11/+13
Add Kconfig symbol CONFIG_SND_SOC_CS_AMP_LIB_TEST_HOOKS to enable calling into functions that would normally abort because of missing EFI functionality. Before this the code paths were only enabled if the KUnit test for cs-amp-lib was enabled. This change allows KUnit tests for clients of cs-amp-lib to install redirection hooks in cs-amp-lib. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260121132243.1256019-5-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-21ASoC: cs-amp-lib-test: Tests for reading SSIDExV2Richard Fitzgerald-0/+169
Adds test cases for getting a Dell SSIDExV2 string by calling cs_amp_devm_get_vendor_specific_variant_id(). This is a fairly simple test harness, the redirected call to cs_amp_get_efi_variable() returns a test string to simulate reading a string from UEFI. The returned string should be the second field in the SSIDExV2 string (if valid). Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260121132243.1256019-4-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-01-21ASoC: cs35l56: Use vendor-specific qualifier in firmware file searchRichard Fitzgerald-14/+55
If cs_amp_devm_get_vendor_specific_variant_id() returns a string, use it as part of the firmware filename. If this firmware isn't found, fall back to the standard firmware name. This re-uses the fwf_suffix fallback mechanism that was introduced in commit e5d5b3aebdc8 ("ASoC: cs35l56: Use SoundWire address as alternate firmware suffix on L56 B0"). This is for handling vendors that use the same PCI SSID on systems with various audio hardware and have a custom vendor-specific way to identify the hardware variant. This is currently used on Dell laptops. Dell create a UEFI variable that indicates varations to the base hardware. This variance can be any part of the hardware (not necessarily affecting the audio). It would be impractical to publish many aliases for the same firmware files to match every possible variance to that base hardware. Hence the fallback to the standard firmware name. This allows alternate firmware files to be published only for variants that need it. For all other variants the fallback will load the firmware for the base SSID. This is not done for CS35L56 B0 because the fallback mechanism is already used for a different purpose for these parts. None of the products with the older L56 B0 silicon revision need the additional vendor-specific descriptor. For SoundWire the resulting firmware searches with a variant descriptor will be: 1. cs35l??-dsp1-misc-SSID-VARIANT-l?u?.wmfw 2. cs35l??-dsp1-misc-SSID-VARIANT.wmfw 3. cs35l??-dsp1-misc-SSID-VARIANT-l?u?.bin 4. cs35l??-dsp1-misc-SSID-VARIANT.bin If this doesn't find a wmfw and bin file it will then fallback to: 5. cs35l??-dsp1-misc-SSID-l?u?.wmfw 6. cs35l??-dsp1-misc-SSID.wmfw 7. cs35l??-dsp1-misc-SSID-l?u?.bin 8. cs35l??-dsp1-misc-SSID.bin With the typical published firmware names and qualifiers (a single wmfw but amp-specific bin file) this will load either: cs35l??-dsp1-misc-SSID-VARIANT.wmfw and cs35l??-dsp1-misc-SSID-VARIANT-l?u?.bin or cs35l??-dsp1-misc-SSID.wmfw and cs35l??-dsp1-misc-SSID-l?u?.bin For non-Soundwire (I2S/TDM) systems the searches and fallbacks are as above except that the "l?u?" component of the name is instead the ALSA name prefix, usually of the form "AMPn". Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260121132243.1256019-3-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>