aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs (follow)
AgeCommit message (Collapse)AuthorFilesLines
2019-07-11Merge tag 'tag-chrome-platform-for-v5.3' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linuxLinus Torvalds1-4/+4
Pull chrome platform updates from Benson Leung "CrOS EC: - Add new CrOS ISHTP transport protocol - Add proper documentation for debugfs entries and expose resume and uptime files - Select LPC transport protocol variant at runtime. - Add lid angle sensor driver - Fix oops on suspend/resume for lightbar driver - Set CrOS SPI transport protol in realtime Wilco EC: - Add telemetry char device interface - Add support for event handling - Add new sysfs attributes Misc: - Contains ib-mfd-cros-v5.3 immutable branch from mfd, with cros_ec_commands.h header freshly synced with Chrome OS's EC project" * tag 'tag-chrome-platform-for-v5.3' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux: (54 commits) mfd / platform: cros_ec_debugfs: Expose resume result via debugfs platform/chrome: lightbar: Get drvdata from parent in suspend/resume iio: cros_ec: Add lid angle driver platform/chrome: wilco_ec: Add circular buffer as event queue platform/chrome: cros_ec_lpc_mec: Fix kernel-doc comment first line platform/chrome: cros_ec_lpc: Choose Microchip EC at runtime platform/chrome: cros_ec_lpc: Merge cros_ec_lpc and cros_ec_lpc_reg Input: cros_ec_keyb: mask out extra flags in event_type platform/chrome: wilco_ec: Fix unreleased lock in event_read() platform/chrome: cros_ec_debugfs: cros_ec_uptime_fops can be static platform/chrome: cros_ec_debugfs: Add debugfs ABI documentation platform/chrome: cros_ec_debugfs: Fix kernel-doc comment first line platform/chrome: cros_ec_debugfs: Add debugfs entry to retrieve EC uptime mfd: cros_ec: Update I2S API mfd: cros_ec: Add Management API entry points mfd: cros_ec: Add SKU ID and Secure storage API mfd: cros_ec: Add API for rwsig mfd: cros_ec: Add API for Fingerprint support mfd: cros_ec: Add API for Touchpad support mfd: cros_ec: Add API for EC-EC communication ...
2019-07-08Merge tag 'asoc-v5.3' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linusTakashi Iwai390-2215/+19292
ASoC: Updates for v5.3 This is a very big update, mainly thanks to Morimoto-san's refactoring work and some fairly large new drivers. - Lots more work on moving towards a component based framework from Morimoto-san. - Support for force disconnecting muxes from Jerome Brunet. - New drivers for Cirrus Logic CS47L35, CS47L85 and CS47L90, Conexant CX2072X, Realtek RT1011 and RT1308. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2019-07-06Merge branch 'asoc-5.3' into asoc-nextMark Brown34-323/+18882
2019-07-06Merge branch 'asoc-5.2' into asoc-linusMark Brown4-4/+39
2019-07-06ASoC: hdac_hdmi: report codec link up/down status to busKai Vehmanen1-0/+2
Report codec power status to the HDA codec bus from runtime pm suspend and resume callbacks. This is required to implement runtime idle logic that relies on 'codec_powered' field of hdac_bus to be maintained for all codecs. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Takashi Iwai <tiwai@suse.de> Link: https://lore.kernel.org/r/20190702132428.13129-2-kai.vehmanen@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-05ASoC: rt5665: remove redundant assignment to variable idxColin Ian King1-1/+1
The variable idx is being initialized with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King <colin.king@canonical.com> Link: https://lore.kernel.org/r/20190705075303.14692-1-colin.king@canonical.com Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-05ASoC: wcd9335: remove multiple defines.Srinivas Kandagatla1-5/+0
Found during review that there are multiple defines of same constants. This patch removes them! Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20190704165410.7173-1-srinivas.kandagatla@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-05ALSA: hda: Simplify snd_hdac_refresh_widgets()Takashi Iwai1-1/+1
Along with the recent fix for the races of snd_hdac_refresh_widgets() it turned out that the instantiation of widgets sysfs at snd_hdac_sysfs_reinit() could cause a race. The race itself was already covered later by extending the mutex protection range, the commit 98482377dc72 ("ALSA: hda: Fix widget_mutex incomplete protection"), but this also indicated that the call of *_reinit() is basically superfluous, as the widgets shall be created sooner or later from snd_hdac_device_register(). This patch removes the redundant call of snd_hdac_sysfs_reinit() at first. By this removal, the sysfs argument itself in snd_hdac_refresh_widgets() becomes superfluous, too, because the only case sysfs=false is always with codec->widgets=NULL. So, we drop this redundant argument as well. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2019-07-02ASoC: max98357a: avoid speaker pop when playback startupMac Chiang1-9/+46
Loud speaker pop happens during playback even when in slience playback. Specify Max98357a amp delay times to make sure clocks are always earlier than sdmode on. Signed-off-by: Mac Chiang <mac.chiang@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-02ASoC: cros_ec_codec: use devm_snd_soc_register_component()Kuninori Morimoto1-1/+1
We have devm_xxx version of snd_soc_register_component, let's use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-02ASoC: ak4118: use devm_snd_soc_register_component()Kuninori Morimoto1-9/+2
We have devm_xxx version of snd_soc_register_component, let's use it. This patch also removes related empty functions Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-02ASoC: rt5682: use devm_snd_soc_register_component()Kuninori Morimoto1-10/+3
We have devm_xxx version of snd_soc_register_component, let's use it. This patch also removes related empty functions Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-02ASoC: rt1308: Fix platform_no_drv_owner.cocci warningsYueHaibing1-1/+0
Remove .owner field if calls are used which set it automatically Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci Signed-off-by: YueHaibing <yuehaibing@huawei.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-07-02ASoC: madera: Remove duplicated include from cs47l35.cYueHaibing1-1/+0
Remove duplicated include. Signed-off-by: YueHaibing <yuehaibing@huawei.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-28ASoC: rt1308: Add RT1308 amplifier driverDerek Fang4-0/+1198
This is the initial amplifier driver for rt1308. Signed-off-by: Derek Fang <derek.fang@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-28ASoC: codecs: ad193x: Reset used registers at probeCodrin Ciubotariu1-0/+10
Since the ad193x codecs have no software reset, we have to reinitialize the registers after a hardware reset to assure no previous values are kept. Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-28ASoC: codecs: ad193x: Group register initialization at probeCodrin Ciubotariu1-19/+33
Create a structure with the register initialization values at probe and use it to initialize all the registers at once. Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-26Merge tag 'v5.2-rc6' into asoc-5.3Mark Brown371-1888/+371
Linux 5.2-rc6
2019-06-26ASoC: madera: Update SPDX headersCharles Keepax5-25/+5
The madera driver was merged too late to catch Thomas Gleixner's cleanup of the SPDX headers tree wide. Update the headers to match what was done in that patch. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-26ASoC: codecs: ad193x: Fix memory corruption on BE 64b systemsCodrin Ciubotariu1-4/+2
Since change_bit() requires unsigned long*, making this cast on an unsigned int variable will change a wrong bit on BE platforms, causing memory corruption. Replace this function with a simple XOR. Fixes: 90f6e6803139 ("ASoC: codecs: ad193x: Fix frame polarity for DSP_A format") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-25ASoC: Intel: hdac_hdmi: Set ops to NULL on removeAmadeusz Sławiński1-0/+6
When we unload Skylake driver we may end up calling hdac_component_master_unbind(), it uses acomp->audio_ops, which we set in hdmi_codec_probe(), so we need to set it to NULL in hdmi_codec_remove(), otherwise we will dereference no longer existing pointer. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-25ASoC: rt5677: depop stereo dacCurtis Malainey1-1/+2
Upon enabling the ASRC DAC we need a delay to avoid popping the speakers. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org> Cc: Ross Zwisler <zwisler@chromium.org> Tested-by: Ross Zwisler <zwisler@google.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: rt5514-spi: don't use snd_soc_lookup_component()Kuninori Morimoto1-3/+1
rt5514-spi can use dev_get_drvdata() to get its component because it is using snd_soc_component_set_drvdata(); static int rt5514_spi_pcm_probe(...) { ... => snd_soc_component_set_drvdata(component, ...); ... } We don't need to use snd_soc_lookup_component() for it. This patch uses dev_get_drvdata() instead of snd_soc_lookup_component(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: pcm3168a: Add support for multi DIN/DOUT with TDM slots parameterPeter Ujfalusi1-7/+24
The driver was wired to be only usable in DIN1/DOUT1 mode, switching between TDM and non TDM modes based on the number of channels. While keeping this functionality for compatibility add support for using all DIN1/2/3/4 and DOUT1/2/3 if it is needed by setting the TDM slots to 2. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: pcm3168a: Rename min_frame_size to slot_widthPeter Ujfalusi1-5/+5
It represents slot size and not frame. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: cs47l90: Add codec driver for Cirrus Logic CS47L90Richard Fitzgerald3-0/+2665
Adds the codec driver for the CS47L90 SmartCodec. This is a multi-functional codec based on the Cirrus Logic Madera platform. Signed-off-by: Nikesh Oswal <nikesh@opensource.cirrus.com> Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: cs47l85: Add codec driver for Cirrus Logic CS47L85Richard Fitzgerald3-0/+2742
Adds the codec driver for the CS47L85 SmartCodec. This is a multi-functional codec based on the Cirrus Logic Madera platform. Signed-off-by: Nariman Poushin <npoushin@opensource.cirrus.com> Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: cs47l35: Add codec driver for Cirrus Logic CS47L35Richard Fitzgerald3-0/+1790
Adds the codec driver for the CS47L35 SmartCodec. This is a multi-functional codec based on the Cirrus Logic Madera platform. Signed-off-by: Piotr Stankiewicz <piotrs@opensource.cirrus.com> Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-20ASoC: madera: Add common support for Cirrus Logic Madera codecsRichard Fitzgerald4-0/+4634
The Cirrus Logic Madera codecs are a family of related codecs with extensive digital and analogue I/O, digital mixing and routing, signal processing and programmable DSPs. This patch adds common support code shared by all Madera codecs. This patch also adds the pdata to the parent mfd pdata struct. Since there is a circular build dependency it's convenient to patch them both atomically. Signed-off-by: Nariman Poushin <nariman@opensource.cirrus.com> Signed-off-by: Nikesh Oswal <Nikesh.Oswal@cirrus.com> Signed-off-by: Piotr Stankiewicz <piotrs@opensource.cirrus.com> Signed-off-by: Ajit Pandey <ajit.pandey@incubesol.com> Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-19treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500Thomas Gleixner210-877/+210
Based on 2 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation # extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 4122 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Enrico Weigelt <info@metux.net> Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-06-19treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 496Thomas Gleixner1-2/+1
Based on 1 normalized pattern(s): licensed under gpl v2 extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 1 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Enrico Weigelt <info@metux.net> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Armijn Hemel <armijn@tjaldur.nl> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081206.395945938@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-06-19treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 463Thomas Gleixner2-28/+2
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of version 2 of the gnu general public license as published by the free software foundation this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details you should have received a copy of the gnu general public license along with this program if not see http www gnu org licenses the full gnu general public license is included in this distribution in the file called copying extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 4 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Enrico Weigelt <info@metux.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081202.258730266@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-06-19ASoC: rt5677: handle concurrent interruptsBen Zhang1-26/+45
The rt5677 driver writes to the IRQ control register within the IRQ handler in order to flip the polarity of the interrupts that have been signalled. If an interrupt fires in the interval between the regmap_read and the regmap_write, it will not trigger a new call to rt5677_irq. Add a bounded loop to rt5677_irq that keeps checking interrupts until none are seen, so that any interrupts that are signalled in that interval are correctly handled. Signed-off-by: Ben Zhang <benzh@chromium.org> Signed-off-by: Fletcher Woodruff <fletcherw@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-19ASoC: rt5677: clear interrupts by polarity flipBen Zhang2-36/+145
The rt5677 jack detection function has a requirement that the polarity of an interrupt be flipped after it fires in order to clear the interrupt. This patch implements an irq_chip with irq_domain directly instead of using regmap-irq, so that interrupt source line polarities can be flipped in the irq handler. The reason that this patch does not add this feature within regmap-irq is that future patches will add hotword detection support to this irq handler. Those patches will require adding additional logic that would not make sense to have in regmap-irq. Signed-off-by: Ben Zhang <benzh@chromium.org> Signed-off-by: Fletcher Woodruff <fletcherw@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-17ASoC: rt5677: move jack-detect init to i2c probeFletcher Woodruff2-26/+40
This patch moves the code to select the gpios for jack detection from rt5677_probe to rt5677_init_irq (called from rt5677_i2c_probe). It also sets some registers to fix bugs related to jack detection, and adds some constants and comments to make it easier to understand what certain register settings are controlling. Signed-off-by: Ben Zhang <benzh@chromium.org> Signed-off-by: Fletcher Woodruff <fletcherw@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-17ASoC: rt5677: fall back to DT prop names on errorFletcher Woodruff1-37/+37
The rt5677 driver uses ACPI-style property names to read from the device API. However, these do not match the property names in _DSD used on the Chromebook Pixel 2015, which are closer to the Device Tree style. Unify the two functions for reading from the device API so that they try ACPI-style names first and fall back to the DT names on error. With this patch, plugging and unplugging the headphone jack switches between headphones and speakers automatically. Signed-off-by: Fletcher Woodruff <fletcherw@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-17ASoC: cx2072x: mark PM function as __maybe_unusedArnd Bergmann1-1/+1
While the suspend function is already marked __maybe_unused, the resume function is not, which leads to a warning when CONFIG_PM is disabled: sound/soc/codecs/cx2072x.c:1625:12: error: unused function 'cx2072x_runtime_resume' [-Werror,-Wunused-function] Mark this one like the other one. Fixes: a497a4363706 ("ASoC: Add support for Conexant CX2072X CODEC") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-14ASoC: wm_adsp: no need to check return value of debugfs_create functionsGreg Kroah-Hartman1-30/+7
When calling debugfs functions, there is no need to ever check the return value. The function can work or not, but the code logic should never do something different based on this. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-14Merge tag 'sound-5.2-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/soundLinus Torvalds7-11/+46
Pull sound fixes from Takashi Iwai: "It might feel like deja vu to receive a bulk of changes at rc5, and it happens again; we've got a collection of fixes for ASoC. Most of fixes are targeted for the newly merged SOF (Sound Open Firmware) stuff and the relevant fixes for Intel platforms. Other than that, there are a few regression fixes for the recent ASoC core changes and HD-audio quirk, as well as a couple of FireWire fixes and for other ASoC codecs" * tag 'sound-5.2-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (54 commits) Revert "ALSA: hda/realtek - Improve the headset mic for Acer Aspire laptops" ALSA: ice1712: Check correct return value to snd_i2c_sendbytes (EWS/DMX 6Fire) ALSA: oxfw: allow PCM capture for Stanton SCS.1m ALSA: firewire-motu: fix destruction of data for isochronous resources ASoC: Intel: sst: fix kmalloc call with wrong flags ASoC: core: Fix deadlock in snd_soc_instantiate_card() SoC: rt274: Fix internal jack assignment in set_jack callback ALSA: hdac: fix memory release for SST and SOF drivers ASoC: SOF: Intel: hda: use the defined ppcap functions ASoC: core: move DAI pre-links initiation to snd_soc_instantiate_card ASoC: Intel: cht_bsw_rt5672: fix kernel oops with platform_name override ASoC: Intel: cht_bsw_nau8824: fix kernel oops with platform_name override ASoC: Intel: bytcht_es8316: fix kernel oops with platform_name override ASoC: Intel: cht_bsw_max98090: fix kernel oops with platform_name override ASoC: sun4i-i2s: Add offset to RX channel select ASoC: sun4i-i2s: Fix sun8i tx channel offset mask ASoC: max98090: remove 24-bit format support if RJ is 0 ASoC: da7219: Fix build error without CONFIG_I2C ASoC: SOF: Intel: hda: Fix COMPILE_TEST build error ASoC: SOF: fix DSP oops definitions in FW ABI ...
2019-06-13ASoC: tas571x: Fix -Wunused-const-variableNathan Huckleberry1-2/+2
Clang produces the following warning sound/soc/codecs/tas571x.c:666:38: warning: unused variable 'tas5721_controls' [-Wunused-const-variable] In the chip struct definition tas5711_controls is used rather than tac5712_controls. Looks like a typo was made in the original commit. Since tac5711_controls is identical to tas5721_controls we can just swap them Cc: clang-built-linux@googlegroups.com Link: https://github.com/ClangBuiltLinux/linux/issues/522 Signed-off-by: Nathan Huckleberry <nhuck@google.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-13ASoC: codec: hdac_hdmi: fix pin connections at cvt enableKai Vehmanen1-0/+31
In display codecs supported by hdac_hdmi, the connection indices are shared by all converters. At boot and resume from suspend, the connection state may be reset to default values. In case of multiple connected pins (multiple monitors connected with audio capability), routing and mute status of pins that are not connected to any PCM, may interfere with other pins. E.g. after resume from S3 with multiple monitors, unless all converters are in active use, playback to some PCMs may be muted due to the default settings of unrelated converters. Avoid this by ensuring all pin:cvt selections are correct in codec whenever a converter is enabled for playback. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-13Merge tag 'asoc-fix-v5.2-rc4' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linusTakashi Iwai7-11/+46
ASoC: Fixes for v5.2 There's an awful lot of fixes here, almost all for the newly introduced SoF DSP drivers (including a few things it turned up in shared code). This is a large and complex piece of code so it's not surprising that there have been quite a few issues here, fortunately things seem to have mostly calmed down now. Otherwise there's just a smattering of small fixes.
2019-06-13ASoC: nau8825: fix fake interruption when bootingJohn Hsu2-0/+6
There is no pull-up resistor at IRQ line where it connects from the codec to SoC. When booting, the signal of IRQ pin will keep low which makes the SoC invoke the ISR repeatedly because the IRQ is registered trigger low. It will not stop until the codec sets up the interruption and pulls the signal high. In the patch, nau8825 will internally pull the signal to high at booting in case the fake interrupts happen. Signed-off-by: John Hsu <KCHSU0@nuvoton.com> Tested-by: Cheng-Yi Chiang <cychiang@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-12ASoC: nau8822: support master modeDavid Lin2-0/+25
The driver selects the proper BCLK divide through the BCLK and FS at the hardware parameter when the I2S master mode. Signed-off-by: David Lin <CTLIN0@nuvoton.com> Signed-off-by: John Hsu <KCHSU0@nuvoton.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-10mfd: cros_ec: Update I2S APIGwendal Grignou1-4/+4
Improve I2S API. Rename ec_response_codec_gain into ec_codec_i2s_gain, update caller accordlingly. Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Acked-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Acked-by: Benson Leung <bleung@chromium.org> Reviewed-by: Fabien Lahoudere <fabien.lahoudere@collabora.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2019-06-07ASoC: msm8916-wcd-digital: Add sidetone supportSrinivas Kandagatla1-0/+282
This patch adds sidetone support via one of the 3 RX Mix paths using IIR1 and IIR2. IIR1 can be feed by any Decimators or RX paths, and IIRx can also be looped back to RX mixers to provide sidetone functionality. Two IIR filters are used for Side tone equalization and each filter is 5 stage. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-06Merge branch 'asoc-5.2' into asoc-5.3Mark Brown2-1/+18
2019-06-06ASoC: rt1011: fix warning reported by kbuild test robot and minor issueShuming Fan1-4/+7
This patch fixes following issues: - warning: this decimal constant is unsigned only in ISO C90 - sparse: incorrect type in assignment - check if value.integer.value is zero for "R0 Load Mode" control Signed-off-by: Shuming Fan <shumingf@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-06ASoC: rt1011: Mark format integer literals as unsignedNathan Chancellor1-2/+2
Clang warns: sound/soc/codecs/rt1011.c:1291:12: warning: integer literal is too large to be represented in type 'long', interpreting as 'unsigned long' per C89; this literal will have type 'long long' in C99 onwards [-Wc99-compat] format = 2147483648; /* 2^24 * 128 */ ^ sound/soc/codecs/rt1011.c:2123:13: warning: integer literal is too large to be represented in type 'long', interpreting as 'unsigned long' per C89; this literal will have type 'long long' in C99 onwards [-Wc99-compat] format = 2147483648; /* 2^24 * 128 */ ^ 2 warnings generated. Mark the integer literals as unsigned explicitly so that if the kernel does ever bump the C standard it uses, the behavior is consitent. Fixes: d6e65bb7ff0d ("ASoC: rt1011: Add RT1011 amplifier driver") Link: https://github.com/ClangBuiltLinux/linux/issues/506 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com> Reviewed-by: Nick Desaulniers <ndesaulniers@google.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-06SoC: rt274: Fix internal jack assignment in set_jack callbackAmadeusz Sławiński1-1/+2
When we call snd_soc_component_set_jack(component, NULL, NULL) we should set rt274->jack to passed jack, so when interrupt is triggered it calls snd_soc_jack_report(rt274->jack, ...) with proper value. This fixes problem in machine where in register, we call snd_soc_register(component, &headset, NULL), which just calls rt274_mic_detect via callback. Now when machine driver is removed "headset" will be gone, so we need to tell codec driver that it's gone with: snd_soc_register(component, NULL, NULL), but we also need to be able to handle NULL jack argument here gracefully. If we don't set it to NULL, next time the rt274_irq runs it will call snd_soc_jack_report with first argument being invalid pointer and there will be Oops. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>