- 14 Feb, 2020 4 commits
-
-
Jerome Brunet authored
The aiu stored the irq in an unsigned integer which may have discarded an error returned by platform_get_irq_byname(). This is incorrect and should have been a signed integer. Also drop the irq error traces from the probe function as this is already done by platform_get_irq_byname(). Fixes: 6ae9ca9c ("ASoC: meson: aiu: add i2s and spdif support") Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200214131350.337968-4-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Fix the size of allocated memory for the clock bulk data Fixes: 6ae9ca9c ("ASoC: meson: aiu: add i2s and spdif support") Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200214131350.337968-3-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Remove an unused structure definition which slipped through the initial driver submission. Fixes: 6ae9ca9c ("ASoC: meson: aiu: add i2s and spdif support") Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200214131350.337968-2-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Make sure each ASoC component is registered with a unique name. The component is derived from the device name. If a device registers more than one component, the component names will be the same. This usually brings up a warning about the debugfs directory creation of the component since directory already exists. In such case, start numbering the component of the device so the names don't collide anymore. Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200214134704.342501-1-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 13 Feb, 2020 14 commits
-
-
Jerome Brunet authored
Add support for the sound card used on the amlogic GX SoC family Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-10-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Add the dt-binding documentation of sound card supporting the amlogic GX SoC family Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-9-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
This prepares the addition of the GX SoC family sound card driver. The GX sound card, while slightly different, will be similar to the AXG one. The purpose of this change is to share the utils common to both sound card driver. Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-8-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Add the codec to codec component which handles the routing between the audio producers and the internal audio DAC found on the amlogic GXL SoC family Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-7-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Add the codec to codec component which handles the routing between the audio producers (PCM and I2S) and the synopsys hdmi controller on the amlogic GX SoC family Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-6-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Add support for the i2s and spdif audio outputs (AIU) found in the amlogic Gx SoC family Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-5-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
Add the dt-bindings and documentation of the AIU audio controller. This component provides most of the audio outputs found on the Amlogic Gx SoC family. Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-4-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
The hdmi routing mechanism used on g12a hdmi is also used: * other Amlogic SoC types * for the internal DAC path Each of these codec glues are slightly different but the idea behind it remains the same. This change extract some helper functions from the g12a-tohdmitx driver to make them available for other Amlogic codecs. Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-3-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jerome Brunet authored
At the moment, querying the dai_name will stop of the first component matching the dt node. This does not allow a device (single dt node) to provide several ASoC components which could then be used through DT. This change let the search go on if the xlate function of the component returns an error, giving the possibility to another component to match and return the dai_name. Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200213155159.3235792-2-jbrunet@baylibre.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
derek.fang authored
Enable RT5682 PLL2 function to implement the more complex frequency conversion. Signed-off-by: derek.fang <derek.fang@realtek.com> Link: https://lore.kernel.org/r/1581577510-1807-1-git-send-email-derek.fang@realtek.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Tzung-Bi Shih authored
1. Moves headset jack to card-specific storage. 2. Removes trailing blank line. 3. Moves card registration to the end of probe. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200213112003.4.Ia542007f51d3de753a9e0a83135ee074581dbf71@changeidSigned-off-by: Mark Brown <broonie@kernel.org>
-
Tzung-Bi Shih authored
Supports TDM out and 8ch I2S out. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200213112003.3.I30f0b8c87d5ec2a0e5f1b0fabf0a8ccef374f5ea@changeidSigned-off-by: Mark Brown <broonie@kernel.org>
-
Tzung-Bi Shih authored
1. Switch TDM GPIO pins according to playback on or off. 2. Pull TDM GPIO pins down when probed to avoid current leakage. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200213112003.2.I1d568b0c99742c6e755d051aadfd52e4be3cc0a5@changeidSigned-off-by: Mark Brown <broonie@kernel.org>
-
Tzung-Bi Shih authored
DL2 and UL1 are for BTSCO. Provides only 16-bit, mono, 8kHz and 16kHz to userspace. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200213112003.1.Ie5aedb9d34ebfc7f05ceb382bfe346c45331cd63@changeidSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 12 Feb, 2020 11 commits
-
-
Geert Uytterhoeven authored
Fixes for missing miscellaneous support: ERROR: "abx500_get_register_interruptible" [...] undefined! ERROR: "abx500_set_register_interruptible" [...] undefined! ERROR: "arizona_free_irq" [...] undefined! ERROR: "arizona_request_irq" [...] undefined! ERROR: "arizona_set_irq_wake" [...] undefined! ERROR: "mc13xxx_reg_rmw" [...] undefined! ERROR: "mc13xxx_reg_write" [...] undefined! ERROR: "snd_soc_free_ac97_component" [...] undefined! ERROR: "snd_soc_new_ac97_component" [...] undefined! Reported-by: Randy Dunlap <rdunlap@infradead.org> Fixes: ea00d952 ("ASoC: Use imply for SND_SOC_ALL_CODECS") Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Link: https://lore.kernel.org/r/20200212145650.4602-4-geert@linux-m68k.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Geert Uytterhoeven authored
Fixes for CONFIG_I2C=n: WARNING: unmet direct dependencies detected for REGMAP_I2C Depends on [n]: I2C [=n] Selected by [m]: - SND_SOC_ADAU1781_I2C [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] - SND_SOC_ADAU1977_I2C [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] - SND_SOC_RT5677 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] sound/soc/codecs/...: error: type defaults to ‘int’ in declaration of ‘module_i2c_driver’ [-Werror=implicit-int] drivers/base/regmap/regmap-i2c.c: In function ‘regmap_smbus_byte_reg_read’: drivers/base/regmap/regmap-i2c.c:25:8: error: implicit declaration of function ‘i2c_smbus_read_byte_data’; did you mean ‘i2c_set_adapdata’? [-Werror=implicit-function-declaration] Fixes: ea00d952 ("ASoC: Use imply for SND_SOC_ALL_CODECS") Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Link: https://lore.kernel.org/r/20200212145650.4602-3-geert@linux-m68k.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Geert Uytterhoeven authored
Fixes for CONFIG_SPI=n: WARNING: unmet direct dependencies detected for REGMAP_SPI Depends on [n]: SPI [=n] Selected by [m]: - SND_SOC_ADAU1781_SPI [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] - SND_SOC_ADAU1977_SPI [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] ERROR: "spi_async" [...] undefined! ERROR: "spi_get_device_id" [...] undefined! ERROR: "__spi_register_driver" [...] undefined! ERROR: "spi_setup" [...] undefined! ERROR: "spi_sync" [...] undefined! ERROR: "spi_write_then_read" [...] undefined! Reported-by: Randy Dunlap <rdunlap@infradead.org> Fixes: ea00d952 ("ASoC: Use imply for SND_SOC_ALL_CODECS") Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Randy Dunlap <rdunlap@infradead.org> # build-tested Link: https://lore.kernel.org/r/20200212145650.4602-2-geert@linux-m68k.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Dafna Hirschfeld authored
This was tested and verified with: make dt_binding_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/sound/google,cros-ec-codec.yaml Signed-off-by: Dafna Hirschfeld <dafna.hirschfeld@collabora.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20200127091806.11403-1-dafna.hirschfeld@collabora.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
soc_pcm_open() operation order is not good. At first, soc_pcm_open() operation order is 1) CPU DAI startup 2) Component open 3) Codec DAI startup 4) rtd startup But here, 2) will call try_module_get() if component has module_get_upon_open flags. This means 1) CPU DAI startup will be operated *before* its module was loaded. DAI should be called *after* Component. Second, soc_pcm_close() operation order is 1) CPU DAI shutdown 2) Codec DAI shutdown 3) rtd shutdown 4) Component close soc_pcm_open() and soc_pcm_close() are paired function, but, its operation order is unbalance. This patch tidyup soc_pcm_open() order to Component -> rtd -> DAI. This is one of prepare for cleanup soc-pcm-open() Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/871rr3cext.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
This patch moves soc_pcm_close() next to soc_pcm_open(). This is prepare for soc_pcm_open() cleanup. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/8736bjcexx.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
Current soc_pcm_open() calls snd_soc_component_open() under loop. Thus, it needs to care about opened/not-yet-opened Component. But, if soc-component.c is handling it, soc-pcm.c don't need to care about it. This patch adds opened flag to soc-component.h, and simplify soc-pcm.c. This is one of prepare for cleanup soc-pcm-open() Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/874kvzcey1.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Tzung-Bi Shih authored
Da7219 and max98357a share the same I2S lines. When writing audio data to the I2S, both codecs generate sound. Da7219 already has a separate control "Headphone Switch". Adds a new control "Speakers Switch" for turning on/off max98357a. Userspace program can decide to turn on/off which codecs by different use cases. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200212124608.2.I5fa3fdca69dbb5d3dd5031c939b9b24095065a94@changeidSigned-off-by: Mark Brown <broonie@kernel.org>
-
Tzung-Bi Shih authored
Some machine may share the same I2S lines for multiple codecs. For example, mediatek/mt8183/mt8183-da7219-max98357 shares the same lines between max98357a and da7219. When writing audio data through the I2S lines, all codecs on the lines would try to generate sound if they accepts DO line. As a result, multiple codecs generate sound at a time. Moves control of SD_MODE to DAPM so that machine drivers have chances to manipulate DAPM widget to turn on/off max98357a. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200212124608.1.I73b26b5e319de173d05823e79f5861bf1826261c@changeidSigned-off-by: Mark Brown <broonie@kernel.org>
-
Gustavo A. R. Silva authored
The current codebase makes use of the zero-length array language extension to the C90 standard, but the preferred mechanism to declare variable-length types such as these ones is a flexible array member[1][2], introduced in C99: struct foo { int stuff; struct boo array[]; }; By making use of the mechanism above, we will get a compiler warning in case the flexible array does not occur last in the structure, which will help us prevent some kind of undefined behavior bugs from being inadvertenly introduced[3] to the codebase from now on. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732 ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20200211200549.GA12072@embeddedorSigned-off-by: Mark Brown <broonie@kernel.org>
-
Geert Uytterhoeven authored
The alignment of the continuation of the devm_ioremap() call in fsi_probe() was broken. Join the lines, as all parameters can fit on a single line. Fixes: 4bdc0d67 ("remove ioremap_nocache and devm_ioremap_nocache") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20200212085008.9652-1-geert+renesas@glider.beSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 11 Feb, 2020 11 commits
-
-
Mark Brown authored
Merge branch 'for-5.6' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-5.7
-
Peter Ujfalusi authored
Some DMA engines can have big FIFOs which adds to the latency. The DMAengine framework can report the FIFO utilization in bytes. Use this information for the delay reporting. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Reviewed-by: Takashi Iwai <tiwai@suse.de> Link: https://lore.kernel.org/r/20200210153336.10218-1-peter.ujfalusi@ti.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
Current soc_pcm_open() calls snd_soc_dai_startup() under loop. Thus, it needs to care about started/not-yet-started codec DAI. But, if soc-dai.c is handling it, soc-pcm.c don't need to care about it. This patch adds started flag to soc-dai.h, and simplify soc-pcm.c. This is one of prepare for cleanup soc-pcm-open() Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://lore.kernel.org/r/875zgfcey5.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
Current soc-pcm is using bit-OR'ed error ret |= snd_soc_component_close(component, substream); ret |= snd_soc_component_hw_free(component, substream); The driver may return arbitrary error codes so they can conflict. The bit-OR'ed error works only if the return code is always consistent. This patch fixup it, and use *last* ret value. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://lore.kernel.org/r/877e0vceyc.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
This patch adds new for_each_dapm_widgets() macro and use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/878slbceyg.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
commit 3635bf09 ("ASoC: soc-pcm: add symmetry for channels and sample bits") set 0 not only to dai->rate but also to dai->channels and dai->sample_bits if DAI was not active at soc_pcm_close(). and commit d3383420 ("ASoC: soc-pcm: move DAIs parameters cleaning into hw_free()") moved it from soc_pcm_close() to soc_pcm_hw_free(). These happen at v3.14. But, maybe because of branch merge conflict or something similar happen then, soc_pcm_close() still has old settings (care only dai->rate, doesn't care dai->channels/sample_bits). This is 100% duplicated operation. This patch removes soc_pcm_close() side operation which supposed to already moved to soc_pcm_hw_free(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/87a75rceyl.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Kuninori Morimoto authored
ALSA SoC has snd_soc_runtime_activate() / snd_soc_runtime_deactivate(). These increment or decrement DAI/Component activity, but the code difference is only +1 or -1. This patch adds common snd_soc_runtime_action() which can get +1 or -1 as parameter, and use it from snd_soc_runtime_activate/deactivate() to avoid duplicate implementation. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/87blq7ceyq.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Peter Ujfalusi authored
Some DMA engines can have big FIFOs which adds to the latency. The DMAengine framework can report the FIFO utilization in bytes. Use this information for the delay reporting. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Reviewed-by: Takashi Iwai <tiwai@suse.de> Link: https://lore.kernel.org/r/20200210151402.29634-1-peter.ujfalusi@ti.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Ranjani Sridharan authored
Trace DMA is disabled by default when the DSP is in D0I3. Add a debug option to keep trace DMA enabled when the DSP is in D0I3 during S0. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Keyon Jie <yang.jie@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200129220726.31792-10-pierre-louis.bossart@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Ranjani Sridharan authored
This patch implements support for DSP D0i3 when the system is in S0. The basic idea is to schedule a delayed work after every successful IPC TX that checks if there are only D0I3-compatible streams active and if so transition the DSP to D0I3. With the introduction of DSP D0I3 in S0, we need to ensure that the DSP is in D0I0 before sending any new IPCs. The exception for this would be the compact IPCs that are used to set the DSP in D0I3/D0I0 states. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200129220726.31792-9-pierre-louis.bossart@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Ranjani Sridharan authored
Amend the DSP state transition diagram in preparation for introducing the feature to support opportunistic DSP D0I3 state when the system is in S0. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200129220726.31792-8-pierre-louis.bossart@linux.intel.comSigned-off-by: Mark Brown <broonie@kernel.org>
-