summaryrefslogtreecommitdiffstats
path: root/sound
AgeCommit message (Collapse)AuthorFilesLines
2022-05-16ALSA: hda: cs35l41: Add Support for InterruptsStefan Binding3-1/+137
The CS35L41 can produce interrupts on error. When the interrupts occur, the driver will report the error, but errors will only be fixed after playback finishes. Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220509214703.4482-5-vitalyr@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-16ALSA: hda: cs35l41: Remove Set Channel Map api from bindingStefan Binding3-56/+1
This API was required for CLSA0100 laptop, which did not have correct properties inside ACPI. The required values are now hardcoded inside the driver so this is no longer needed. Without this api, there CLSA0100 can now use the generic cs35l41 fixup, like the other laptops. All other laptops will read the Speaker Position from ACPI and set the channel map from within the driver. Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220509214703.4482-4-vitalyr@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-16ALSA: hda: cs35l41: Set Speaker Position for CLSA0100 LaptopStefan Binding1-0/+1
This laptop does not contain required properties inside ACPI, instead the values are be hardcoded inside the driver. Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220509214703.4482-3-vitalyr@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-16ALSA: hda: cs35l41: Fix error in spi cs35l41 hda driver nameStefan Binding1-1/+1
For consistency, rename spi cs35l41 hda driver name so that it matches i2c. Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220509214703.4482-2-vitalyr@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-16ALSA: hda/realtek: fix right sounds and mute/micmute LEDs for HP machineAndy Chi1-0/+1
The HP EliteBook 630 is using ALC236 codec which used 0x02 to control mute LED and 0x01 to control micmute LED. Therefore, add a quirk to make it works. Signed-off-by: Andy Chi <andy.chi@canonical.com> Cc: <stable@vger.kernel.org> Link: https://lore.kernel.org/r/20220513121648.28584-1-andy.chi@canonical.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-16m68k: coldfire: drop ISA_DMA_API supportArnd Bergmann2-3/+1
After a build regression report, I took a look at possible users of CONFIG_ISA_DMA_API on m68k and found none, which Greg confirmed. The CONFIG_GENERIC_ISA_DMA option in turn is only needed to implement ISA_DMA_API, and is clearly not used on the platforms with ISA support. The CONFIG_ISA support for AMIGA_PCMCIA is probably also unneeded, but this is less clear. Unlike other PCMCIA implementations, this one does not use the drivers/pcmcia subsystem at all and just supports the "apne" network driver. When it was first added, one could use ISA drivers on it as well, but this probably broke at some point. With no reason to keep this, let's just drop the corresponding files and prevent the remaining ISA drivers that use this from getting built. The remaining definitions in asm/dma.h are used for PCI support. Link: https://lore.kernel.org/lkml/9e5ee1c3-ca80-f343-a1f5-66f3dd1c0727@linux-m68k.org/ Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Ulf Hansson <ulf.hansson@linaro.org> # For MMC Acked-by: Greg Ungerer <gerg@linux-m68k.org> Acked-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Ungerer <gerg@linux-m68k.org>
2022-05-13ALSA: hda/realtek: Add quirk for TongFang devices with pop noiseWerner Sembach1-0/+8
When audio stops playing there is an audible "pop"-noise when using headphones on the TongFang GMxMRxx, GKxNRxx, GMxZGxx, GMxTGxx and GMxAGxx. This quirk fixes this mostly. Signed-off-by: Werner Sembach <wse@tuxedocomputers.com> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20220512180956.281804-1-wse@tuxedocomputers.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-12ASoC: SOF: Add IPC4 FW loader supportMark Brown9-13/+500
Merge series from Ranjani Sridharan <ranjani.sridharan@linux.intel.com>: The patches in this series add support for FW loading for IPC4 in the SOF driver.
2022-05-12ASoC: max98396: Fix build error for implicit function declarationHui Tang1-0/+1
sound/soc/codecs/max98396.c: In function ‘max98396_i2c_probe’: sound/soc/codecs/max98396.c:1555:25: error: implicit declaration of function ‘devm_gpiod_get_optional’; did you mean ‘devm_regulator_get_optional’? [-Werror=implicit-function-declaration] max98396->reset_gpio = devm_gpiod_get_optional(&i2c->dev, ^~~~~~~~~~~~~~~~~~~~~~~ devm_regulator_get_optional sound/soc/codecs/max98396.c:1556:23: error: ‘GPIOD_OUT_HIGH’ undeclared (first use in this function); did you mean ‘GPIOF_INIT_HIGH’? "reset", GPIOD_OUT_HIGH); ^~~~~~~~~~~~~~ GPIOF_INIT_HIGH sound/soc/codecs/max98396.c:1556:23: note: each undeclared identifier is reported only once for each function it appears in sound/soc/codecs/max98396.c:1565:3: error: implicit declaration of function ‘gpiod_set_value_cansleep’; did you mean ‘gpio_set_value_cansleep’? [-Werror=implicit-function-declaration] gpiod_set_value_cansleep(max98396->reset_gpio, 0); ^~~~~~~~~~~~~~~~~~~~~~~~ gpio_set_value_cansleep cc1: all warnings being treated as errors Include header file <linux/gpio/consumer.h> Fixes: b58581136770 ("ASoC: max98396: add amplifier driver") Signed-off-by: Hui Tang <tanghui20@huawei.com> Link: https://lore.kernel.org/r/20220512074640.75550-2-tanghui20@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASoC: SOF: amd: add missing platform_device_unregister in acp_pci_rn_probeZheng Bin1-0/+1
acp_pci_rn_probe misses a call platform_device_unregister in error path, this patch fixes that. Signed-off-by: Zheng Bin <zhengbin13@huawei.com> Link: https://lore.kernel.org/r/20220512013728.4128903-1-zhengbin13@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASoC: samsung: Fix refcount leak in aries_audio_probeMiaoqian Lin1-1/+1
of_parse_phandle() returns a node pointer with refcount incremented, we should use of_node_put() on it when done. If extcon_find_edev_by_node() fails, it doesn't call of_node_put() Calling of_node_put() after extcon_find_edev_by_node() to fix this. Fixes: 7a3a7671fa6c ("ASoC: samsung: Add driver for Aries boards") Signed-off-by: Miaoqian Lin <linmq006@gmail.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20220512043828.496-1-linmq006@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASoC: SOF: Intel: HDA: Set up sof_ipc4_fw_data for IPC4Ranjani Sridharan3-0/+35
Allocate the sof_ipc4_fw_data struct for IPC4 and set the fw header offset for the platforms which will be used by the core when loading the firmware image. The core expects that the "private" field in struct snd_sof_dev (which is unused today with IPC3) is used to save this data. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220511171648.1622993-6-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASoC: SOF: IPC4: Add FW loader opsRanjani Sridharan4-1/+230
Define and add the FW loader ops for IPC4. Also, introduce a new structure, struct sof_ipc4_private_data that will be used to define some IPC4-sepcific data. Co-developed-by: Rander Wang <rander.wang@intel.com> Signed-off-by: Rander Wang <rander.wang@intel.com> Co-developed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Co-developed-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220511171648.1622993-5-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASoC: SOF: Add IPC4 private headerRanjani Sridharan1-0/+27
Add a struct sof_ipc4_fw_data to hold the firmware module data and manifest FW header offset. The FW reports data about the modules supported by the base FW in its manifest and the FW header offset is platform dependent information. This structure will be allocated when the ops are initialized for each platform and populated when the FW is loaded. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220511171648.1622993-3-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASoC: SOF: Intel: HDA: Set IPC4-specific DSP ops for CaVS platformsRanjani Sridharan5-12/+208
Add implementation of low level, platform dependent IPC4 message handling and set the DSP ops for IPC4 for APL, CNL and TGL platforms. Co-developed-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220511171648.1622993-2-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-12ASOC: Fix the error handling code of the probeMark Brown5-8/+14
Merge series from Zheyu Ma <zheyuma97@gmail.com>: These drivers mishandle the regulator resource in the probe function, failing to disable the regulator for probing failure.
2022-05-12ALSA: Add generic serial MIDI driver using serial bus APIDaniel Kaehn3-0/+394
Generic serial MIDI driver adding support for using serial devices compatible with the serial bus as raw MIDI devices, allowing using additional serial devices not compatible with the existing serial-u16550 driver. Supports only setting standard serial baudrates on the underlying serial device; however, the underlying serial device can be configured so that a requested 38.4 kBaud is actually the standard MIDI 31.25 kBaud. Supports DeviceTree configuration. Signed-off-by: Daniel Kaehn <kaehndan@gmail.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220509145933.1161526-3-kaehndan@gmail.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-12ALSA: hda/cs8409: Add Speaker Playback Switch for WarlockStefan Binding2-0/+3
Add support for a Speaker Playback Switch, which disables the Amp connected to cs8409. The Switch is not added automatically because cs8409 does not have an output amp for the speaker NID. Note: This switch uses a different GPIO to Cyborg/Odin variants Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220511100207.1268321-4-sbinding@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-12ALSA: hda/cs8409: Add Speaker Playback Switch for CyborgStefan Binding2-11/+64
Add support for a Speaker Playback Switch, which disables the Amp connected to cs8409. The Switch is not added automatically because cs8409 does not have an output amp for the speaker NID. Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220511100207.1268321-3-sbinding@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-12ALSA: hda/cs8409: Support new Odin VariantsStefan Binding3-3/+29
Odin Variants have the internal mic connected directly to the CPU rather than codec. Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220511100207.1268321-2-sbinding@opensource.cirrus.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-11ASoC: wm9090: Remove redundant endianness flagCharles Keepax1-1/+0
The endianness flag is used on the CODEC side to specify an ambivalence to endian, typically because it is lost over the hardware link. This device has no DAI links and as such the flag would have no effect, remove the redundant flag. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220510153843.1029540-2-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: wm2000: Remove redundant endianness flagCharles Keepax1-1/+0
The endianness flag is used on the CODEC side to specify an ambivalence to endian, typically because it is lost over the hardware link. This device has no DAI links and as such the flag would have no effect, remove the redundant flag. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220510153843.1029540-1-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: mxs-saif: Fix refcount leak in mxs_saif_probeMiaoqian Lin1-0/+1
of_parse_phandle() returns a node pointer with refcount incremented, we should use of_node_put() on it when done. Fixes: 08641c7c74dd ("ASoC: mxs: add device tree support for mxs-saif") Signed-off-by: Miaoqian Lin <linmq006@gmail.com> Link: https://lore.kernel.org/r/20220511133725.39039-1-linmq006@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: cs42l56: Fix the error handling of cs42l56_i2c_probe()Zheyu Ma1-1/+1
The driver should goto label 'err_enable' when failing at regmap_read(). Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220511015514.1777923-1-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: imx-hdmi: Fix refcount leak in imx_hdmi_probeMiaoqian Lin1-0/+1
of_find_device_by_node() takes reference, we should use put_device() to release it. when devm_kzalloc() fails, it doesn't have a put_device(), it will cause refcount leak. Add missing put_device() to fix this. Fixes: 6a5f850aa83a ("ASoC: fsl: Add imx-hdmi machine driver") Fixes: f670b274f7f6 ("ASoC: imx-hdmi: add put_device() after of_find_device_by_node()") Signed-off-by: Miaoqian Lin <linmq006@gmail.com> Link: https://lore.kernel.org/r/20220511052740.46903-1-linmq006@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: fsl_ssi: Add support multi fifo scriptShengjiu Wang1-2/+32
With dual fifo enabled, the case that recording mono sound in the background, playback mono sound twice in parallal, at second time playback sound may distort, the possible reason is using dual fifo to playback mono sound is not recommended. This patch is to provide a option to use multi fifo script, which can be dynamically configured as one fifo or two fifo mode. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Link: https://lore.kernel.org/r/1652183808-3745-1-git-send-email-shengjiu.wang@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: fsl: Fix refcount leak in imx_sgtl5000_probeMiaoqian Lin1-6/+8
of_find_i2c_device_by_node() takes a reference, In error paths, we should call put_device() to drop the reference to aviod refount leak. Fixes: 81e8e4926167 ("ASoC: fsl: add sgtl5000 clock support for imx-sgtl5000") Signed-off-by: Miaoqian Lin <linmq006@gmail.com> Reviewed-by: Fabio Estevam <festevam@gmail.com> Link: https://lore.kernel.org/r/20220511065803.3957-1-linmq006@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: cs42l46: Fix the error handling of cs42l56_i2c_probe()Zheyu Ma1-1/+1
The driver should goto label 'err_enable' when failing at regmap_read(). Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Link: https://lore.kernel.org/r/20220510153251.1741210-2-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: wm8903: Fix the error handling of wm8903_i2c_probe()Zheyu Ma1-1/+1
The driver should goto label 'err' when failing to request the irq. Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220510153251.1741210-7-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: tas6424: Fix the error handling of tas6424_i2c_probe()Zheyu Ma1-2/+6
After enabling the regulator, The driver should disable the regulator when failing at probing. Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Link: https://lore.kernel.org/r/20220510153251.1741210-6-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: tas571x: Fix the error handling of tas571x_i2c_probe()Zheyu Ma1-2/+4
After enabling the regulator, The driver should disable the regulator when failing at probing. Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Link: https://lore.kernel.org/r/20220510153251.1741210-5-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: rt5645: Fix the error handling of rt5645_i2c_probe()Zheyu Ma1-2/+2
After enabling the regulator, The driver should disable the regulator when failing at probing. Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Link: https://lore.kernel.org/r/20220510153251.1741210-4-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: cs35l36: Fix the error handling of cs35l36_i2c_probe()Zheyu Ma1-1/+1
The driver should goto label 'err' when failing at regmap_read(). Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220510153251.1741210-3-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-11ASoC: Intel: boards: Chromebook configuration updatesMark Brown5-2/+81
Merge series from Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>: Two minor changes to enable DMIC and capture for CS35L41, and one new configuration for AlderLake hardware.
2022-05-11ALSA: hda/realtek: Add quirk for the Framework LaptopDustin L. Howett1-0/+11
Some board revisions of the Framework Laptop have an ALC295 with a disconnected or faulty headset mic presence detect. The "dell-headset-multi" fixup addresses this issue, but also enables an inoperative "Headphone Mic" input device whenever a headset is connected. Adding a new quirk chain specific to the Framework Laptop resolves this issue. The one introduced here is based on the System76 "no headphone mic" quirk chain. The VID:PID f111:0001 have been allocated to Framework Computer for this board revision. Revision history: - v2: Moved to a custom quirk chain to suppress the "Headphone Mic" pincfg. Signed-off-by: Dustin L. Howett <dustin@howett.net> Link: https://lore.kernel.org/r/20220511010759.3554-1-dustin@howett.net Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-10ALSA: wavefront: Proper check of get_user() errorTakashi Iwai1-1/+2
The antient ISA wavefront driver reads its sample patch data (uploaded over an ioctl) via __get_user() with no good reason; likely just for some performance optimizations in the past. Let's change this to the standard get_user() and the error check for handling the fault case properly. Reported-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: <stable@vger.kernel.org> Link: https://lore.kernel.org/r/20220510103626.16635-1-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-05-10ASoC: fsl_micfil: Add support for i.MX8MPlusShengjiu Wang1-0/+13
On i.MX8Plus there are two updates for micfil module. One is that the output format is S32_LE, only the 24 more significative bits have information, the other bits are always zero. Add 'formats' variable in soc data to distinguish the format on different platform. Another is that the fifo depth is 32 entries. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Link: https://lore.kernel.org/r/1652087663-1908-1-git-send-email-shengjiu.wang@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10ASoC: samsung: spdif: remove unnecessary check of mem_resYang Yingliang1-2/+1
The resource is checked in probe function, so there is no need do this check in remove function. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20220510124749.2663874-1-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10ASoC: Intel: sof_ssp_amp: enable capture stream from cs35l41Brent Lu1-0/+3
Enable capture stream of the cs35l41 dai link to support feedback stream from amplifier. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220509170922.54868-4-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10ASoC: Intel: sof_ssp_amp: fix no DMIC BE Link on ChromebooksBrent Lu1-2/+14
The SOF topology supports 2 BE Links(dmic01 and dmic16k) and each link supports up to four DMICs. However, Chromebook does not implement ACPI NHLT table so the mach->mach_params.dmic_num is always zero. We add a quirk so machine driver knows it's running on a Chromebook and need to create BE Links for DMIC. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220509170922.54868-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10ASoC: Intel: sof_rt5682: Add support for adl_rt1019_rt5682sVamshi Krishna4-0/+64
This patch adds the driver data for two rt1019 speaker amplifiers on SSP1 and rt5682s on SSP0 for ADL platform Reviewed-by: Brent Lu <brent.lu@intel.com> Signed-off-by: Vamshi Krishna <vamshi.krishna.gopal@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220509170922.54868-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10ASoC: tlv320adcx140: Register a callback to disable the regulator_disableZheyu Ma1-0/+11
The driver should register a callback that will deal with the disabling when it fails to probe. Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Link: https://lore.kernel.org/r/20220510053031.1685337-1-zheyuma97@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10ASoC: codecs: rt715-sdca: remove useless assignment of opsPierre-Louis Bossart1-2/+0
The ops are already part of the 'struct sdw_driver', it's unclear why this was copied into the 'slave' structure - no other driver does so. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220509185729.59884-1-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-10Clean up usage of the endianness flagMark Brown37-89/+81
Merge series from Charles Keepax <ckeepax@opensource.cirrus.com>: Before componentisation any part registered as a CODEC would have automatically supported both little and big endian, ie. the core would duplicate any supported LE or BE PCM format to support the other endian as well. As componentisation removed the distinction between CODEC drivers and platform drivers, a flag was added to specify if this behaviour is required for a particular component. However, as most systems tend to use little endian the absence of the flag is rarely noticed. Also the naming of the flag "endianness" is a little unobvious as to if it should be applied to a particular component. This series adds a comment to better explain the meaning of the flag and then tidys up the usage of the flag. A couple of uses of the flag are removed where is has been used inappropriately on the CPU side of the DAI link, this is clearly not valid in the cases it has been used, and I suspect never would be valid. Then some redundant formats are removed, since they would be covered by existing endianness flags. And finally a bunch of devices that are missing the flag have it added. It is worth noting that since componenisation there are now a couple of cases where it is not entire clear to me that the flag should be applied to all CODECs as it was before. In those cases I haven't updated the driver to add the flag and they are outlined here: 1) Build into the AP CODECs, these are actual silicon inside the main processor and they typically receive audio directly from an internal bus. It is not obvious to me that these can happily ignore endian. On the CODEC side these include: jz4725b.c, jz4760.c, jz4770.c, rk3328_codec.c, lpass-va-macro.c, lpass-rx-macro.c, lpass-tx-macro.c, lpass-wsa-macro.c. There are also some examples of this scattered around the various platform support directories in sound/soc. 2) Devices behind non-audio buses, SPI just moves bits and doesn't really define an endian for audio data on the bus. Thus it seems the CODEC probably can care about the endian. The only devices that fall into this group (mostly for AoV) are: rt5514-spi.c, rt5677-spi.c, cros_ec_codec.c (only the AoV). 3) CODECs with no DAIs, these could specify the flag and plenty of them do; CODECs from the initial conversion to componentisation. But the flag makes no difference here since there is nothing for it to apply to. This includes purely analogue CODECs: aw8738.c, ssm2305.c, tpa6130a2.c, tda7419.c, max9759.c, max9768.c, max9877.c, lm4857.c, simple-mux.c, simple-amplifier.c. And devices that only do jack detection: ts3a227e.c, mt6359-accdet.c. If there are any opinions on adding the flag to any of those three groups they would be greatfully received. But I am leaning towards leaving 1,2 without endianness flags since it feels inappropriate, and removing the endian flag from devices in catagory 3 that already have it. Assuming no one objects to that I will do a follow up series for that.
2022-05-09ASoC: SOF: sof-client: Update for different IPC versionsMark Brown4-27/+227
Merge series from Peter Ujfalusi <peter.ujfalusi@linux.intel.com>: Hi, The current IPC client infrastructure can only be used with IPC3. This series carries updates for the core side of the client support to handle IPC4 messages and updates the ipc message injector to be usable with IPC4. The IPC flood test is only supported by SOF_IPC (IPC3), we are not going to create the aux device for it at all if the firmware is using IPC4. Regards, Peter --- Peter Ujfalusi (8): ASoC: SOF: sof-client: Add API to get the maximum IPC payload size ASoC: SOF: ipc-msg-injector: Query the maximum IPC payload size ASoC: SOF: sof-client-probes: Query the maximum IPC payload size ASoC: SOF: sof-client: Add API to get the ipc_type ASoC: SOF: sof-client: Add support IPC4 message sending ASoC: SOF: ipc-msg-injector: Separate the message sending ASoC: SOF: ipc-msg-injector: Add support for IPC4 messages ASoC: SOF: sof-client: IPC flood test can only work with SOF_IPC sound/soc/sof/sof-client-ipc-msg-injector.c | 181 ++++++++++++++++++-- sound/soc/sof/sof-client-probes.c | 5 +- sound/soc/sof/sof-client.c | 66 ++++++- sound/soc/sof/sof-client.h | 2 + 4 files changed, 227 insertions(+), 27 deletions(-) -- 2.36.0
2022-05-09ASoC: SOF: trace: The dtrace is only available with SOF_IPCPeter Ujfalusi1-0/+4
Currently the dtrace only supported with SOF_IPC. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220506130229.23354-1-peter.ujfalusi@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-09ASoC: sam9g20_wm8731: Use dev_err_probe() for snd_soc_register_card()Mark Brown1-1/+2
Log the error code when snd_soc_regster_card() fails, but fold in the silencing of deferred probe errors. Signed-off-by: Mark Brown <broonie@kernel.org> Reviewed-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Link: https://lore.kernel.org/r/20220506130349.451452-1-broonie@kernel.org
2022-05-09ASoC: mediatek: mt8195: Fix build warning without CONFIG_OFYueHaibing1-4/+0
sound/soc/mediatek/mt8195/mt8195-mt6359.c:1639:32: warning: ‘mt8195_mt6359_max98390_rt5682_card’ defined but not used [-Wunused-variable] 1639 | static struct mt8195_card_data mt8195_mt6359_max98390_rt5682_card = { | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ sound/soc/mediatek/mt8195/mt8195-mt6359.c:1634:32: warning: ‘mt8195_mt6359_rt1011_rt5682_card’ defined but not used [-Wunused-variable] 1634 | static struct mt8195_card_data mt8195_mt6359_rt1011_rt5682_card = { | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ sound/soc/mediatek/mt8195/mt8195-mt6359.c:1629:32: warning: ‘mt8195_mt6359_rt1019_rt5682_card’ defined but not used [-Wunused-variable] 1629 | static struct mt8195_card_data mt8195_mt6359_rt1019_rt5682_card = { | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Since all users of this driver do need CONFIG_OF anyway, there is no need to save a few bytes on kernel builds while CONFIG_OF disabled, so just remove the #ifdef to fix this warning. Fixes: 86a6b9c9dfff ("ASoC: mediatek: mt8195: add machine support for max98390 and rt5682") Signed-off-by: YueHaibing <yuehaibing@huawei.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Link: https://lore.kernel.org/r/20220509120918.9000-1-yuehaibing@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-09ASoC: wm8940: add devicetree supportLukasz Majewski2-1/+8
This adds devicetree support to the wm8940 codec driver. With a DT-based kernel, there is no board-specific setting to select the driver so allow it to be manually chosen. Signed-off-by: Lukasz Majewski <lukma@denx.de> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220509121055.31103-1-lukma@denx.de Signed-off-by: Mark Brown <broonie@kernel.org>
2022-05-09ASoC: SOF: sof-client: IPC flood test can only work with SOF_IPCPeter Ujfalusi1-0/+3
Currently the ipc flood test is only supported with SOF_IPC. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220506132647.18690-9-peter.ujfalusi@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>