summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2020-07-31ASoC: core: Relocate and expose snd_soc_component_initializeCezary Rojewski
To allow for two-step component registration, expose snd_soc_component_initialize function and move it back to soc-core.c. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20200731144146.6678-2-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30Merge series "drop unnecessary list_empty" from Julia Lawall ↵Mark Brown
<Julia.Lawall@inria.fr>: The various list iterators are able to handle an empty list. The only effect of avoiding the loop is not initializing some index variables. Drop list_empty tests in cases where these variables are not used. The semantic patch that makes these changes is as follows: (http://coccinelle.lip6.fr/) <smpl> @@ expression x,e; iterator name list_for_each_entry; statement S; identifier i; @@ -if (!(list_empty(x))) { list_for_each_entry(i,x,...) S - } ... when != i ? i = e @@ expression x,e; iterator name list_for_each_entry_safe; statement S; identifier i,j; @@ -if (!(list_empty(x))) { list_for_each_entry_safe(i,j,x,...) S - } ... when != i when != j ( i = e; | ? j = e; ) @@ expression x,e; iterator name list_for_each; statement S; identifier i; @@ -if (!(list_empty(x))) { list_for_each(i,x) S - } ... when != i ? i = e @@ expression x,e; iterator name list_for_each_safe; statement S; identifier i,j; @@ -if (!(list_empty(x))) { list_for_each_safe(i,j,x) S - } ... when != i when != j ( i = e; | ? j = e; ) // ------------------- @@ expression x,e; statement S; identifier i; @@ -if (!(list_empty(x))) list_for_each_entry(i,x,...) S ... when != i ? i = e @@ expression x,e; statement S; identifier i,j; @@ -if (!(list_empty(x))) list_for_each_entry_safe(i,j,x,...) S ... when != i when != j ( i = e; | ? j = e; ) @@ expression x,e; statement S; identifier i; @@ -if (!(list_empty(x))) list_for_each(i,x) S ... when != i ? i = e @@ expression x,e; statement S; identifier i,j; @@ -if (!(list_empty(x))) list_for_each_safe(i,j,x) S ... when != i when != j ( i = e; | ? j = e; ) </smpl> --- drivers/media/pci/saa7134/saa7134-core.c | 14 ++--- drivers/media/usb/cx231xx/cx231xx-core.c | 16 ++---- drivers/media/usb/tm6000/tm6000-core.c | 24 +++------- drivers/net/ethernet/mellanox/mlx5/core/steering/dr_matcher.c | 13 ++--- drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c | 5 -- drivers/net/ethernet/sfc/ptp.c | 20 +++----- drivers/net/wireless/ath/dfs_pattern_detector.c | 15 ++---- sound/soc/intel/atom/sst/sst_loader.c | 10 +--- sound/soc/intel/skylake/skl-pcm.c | 8 +-- sound/soc/intel/skylake/skl-topology.c | 5 -- 10 files changed, 53 insertions(+), 77 deletions(-)
2020-07-30ASoC: rk3399_gru_sound: Add DAPM pins, kcontrols for jack detectionAlper Nebi Yasak
PulseAudio (and perhaps other userspace utilities) can not detect any jack for rk3399_gru_sound as the driver doesn't expose related Jack kcontrols. This patch adds two DAPM pins to the headset jack, where the snd_soc_card_jack_new() call automatically creates "Headphones Jack" and "Headset Mic Jack" kcontrols from them. With an appropriate ALSA UCM config specifying JackControl fields for the "Headphones" and "Headset" (mic) devices, PulseAudio can detect plug/unplug events for both of them after this patch. Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com> Link: https://lore.kernel.org/r/20200721182709.6895-1-alpernebiyasak@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: wm8962: Do not access WM8962_GPIO_BASEFabio Estevam
According to the WM8962 datasheet, there is no register at address 0x200. WM8962_GPIO_BASE is just a base address for the GPIO registers and not a real register, so remove it from wm8962_readable_register(). Also, Register 515 (WM8962_GPIO_BASE + 3) does not exist, so skip its access. This fixes the following errors: wm8962 0-001a: ASoC: error at soc_component_read_no_lock on wm8962.0-001a: -16 wm8962 0-001a: ASoC: error at soc_component_read_no_lock on wm8962.0-001a: -16 Signed-off-by: Fabio Estevam <festevam@gmail.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20200717135959.19212-1-festevam@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: SOF: imx: use resource_sizeJulia Lawall
Use resource_size rather than a verbose computation on the end and start fields. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) <smpl> @@ struct resource ptr; @@ - (ptr.end - ptr.start + 1) + resource_size(&ptr) </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr> Link: https://lore.kernel.org/r/1595751933-4952-1-git-send-email-Julia.Lawall@inria.fr Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: Intel: drop unnecessary list_emptyJulia Lawall
list_for_each_entry_safe is able to handle an empty list. The only effect of avoiding the loop is not initializing the index variable. Drop list_empty tests in cases where these variables are not used. Note that list_for_each_entry_safe is defined in terms of list_first_entry, which indicates that it should not be used on an empty list. But in list_for_each_entry_safe, the element obtained by list_first_entry is not really accessed, only the address of its list_head field is compared to the address of the list head, so the list_first_entry is safe. The semantic patch that makes this change is as follows (with another variant for the no brace case): (http://coccinelle.lip6.fr/) <smpl> @@ expression x,e; iterator name list_for_each_entry_safe; statement S; identifier i,j; @@ -if (!(list_empty(x))) { list_for_each_entry_safe(i,j,x,...) S - } ... when != i when != j ( i = e; | ? j = e; ) </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr> Link: https://lore.kernel.org/r/1595761112-11003-2-git-send-email-Julia.Lawall@inria.fr Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30Merge series "ASoC: Intel: KMB: TDM Enablement patches" from Michael Sit Wei ↵Mark Brown
Hong <michael.wei.hong.sit@intel.com>: This patch series is to enable multiple features on the Keembay Platform Michael Sit Wei Hong (4): ASoC: Intel: KMB: Add 8kHz audio support ASoC: Intel: KMB: Rework disable channel function ASoC: Intel: KMB: Enable TDM audio capture dt-bindings: sound: intel,keembay-i2s: Add channel-max property .../bindings/sound/intel,keembay-i2s.yaml | 8 + sound/soc/intel/keembay/kmb_platform.c | 137 +++++++++++++----- sound/soc/intel/keembay/kmb_platform.h | 1 + 3 files changed, 112 insertions(+), 34 deletions(-) -- 2.17.1
2020-07-30Merge series "ASoC: meson: tdm fixes" from Jerome Brunet <jbrunet@baylibre.com>:Mark Brown
This patcheset is collection of fixes for the TDM input and output the axg audio architecture. Its fixes: - slave mode format setting - g12 and sm1 skew offset - tdm clock inversion - standard daifmt props names which don't require a specific prefix Jerome Brunet (4): ASoC: meson: axg-tdm-interface: fix link fmt setup ASoC: meson: axg-tdmin: fix g12a skew ASoC: meson: axg-tdm-formatters: fix sclk inversion ASoC: meson: cards: remove DT_PREFIX for standard daifmt properties sound/soc/meson/axg-tdm-formatter.c | 11 ++++++----- sound/soc/meson/axg-tdm-formatter.h | 1 - sound/soc/meson/axg-tdm-interface.c | 26 +++++++++++++++++--------- sound/soc/meson/axg-tdmin.c | 16 +++++++++++++++- sound/soc/meson/axg-tdmout.c | 3 --- sound/soc/meson/meson-card-utils.c | 2 +- 6 files changed, 39 insertions(+), 20 deletions(-) -- 2.25.4
2020-07-30ASoC: dt-bindings: ak4613: switch to yaml base DocumentationKuninori Morimoto
This patch switches from .txt base to .yaml base Document. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/87mu4cxlo2.wl-kuninori.morimoto.gx@renesas.com Link: https://lore.kernel.org/r/87o8pf3923.wl-kuninori.morimoto.gx@renesas.com Link: https://lore.kernel.org/r/873659bpbk.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: amd: Added hw_params support for ALC1015Ravulapati Vishnu vardhan rao
Adding rt1015 hw_params which set Bit-clock ratio, PLL and appropriate sys clk specific with RTK1015. Signed-off-by: Ravulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com> Link: https://lore.kernel.org/r/20200728160255.31020-6-Vishnuvardhanrao.Ravulapati@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: amd: Adding DAI LINK for rt1015 codecRavulapati Vishnu vardhan rao
DAI link support for RTK 1015 and providing the codec details depending on the snd_soc_card selected by ACPI ID. Signed-off-by: Ravulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com> Link: https://lore.kernel.org/r/20200728160255.31020-5-Vishnuvardhanrao.Ravulapati@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: amd: Adding support for ALC1015 codec in machine driverRavulapati Vishnu vardhan rao
Adding support for ALC1015 RTK codec in machine driver. Passing specific card structure based on its ACPI ID. Signed-off-by: Ravulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com> Link: https://lore.kernel.org/r/20200728160255.31020-4-Vishnuvardhanrao.Ravulapati@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: amd: Passing card structure based on codecRavulapati Vishnu vardhan rao
Passing specific snd_soc_card structure depending on the ACPI ID. In future we can add other IDs in the ACPI table and pass the structure. Signed-off-by: Ravulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com> Link: https://lore.kernel.org/r/20200728160255.31020-3-Vishnuvardhanrao.Ravulapati@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: amd: Renaming snd-soc-card structure and fieldsRavulapati Vishnu vardhan rao
As in future our machine driver supports multiple codecs So changing naming convention of snd_soc_card struct and its fields. Signed-off-by: Ravulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com> Link: https://lore.kernel.org/r/20200728160255.31020-2-Vishnuvardhanrao.Ravulapati@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: samsung: Add sound support for Midas boardsSimon Shields
This patch adds support for voice and BT calls, along with standard audio output via the speaker, earpiece, headphone jack, HDMI, and any accessories compatible with Midas boards. This patch also supports headphone/headset detection and headsets with inline buttons. [m.szyprowski: adaptation to v5.1+ kernels (DAI links initialization)] [s.nawrocki: removal of the clk API calls for CODEC MCLK, the jack data structure moved to struct midas_priv, coding style and typo fixes, conversion to new cpu/codec/dai-node binding] Signed-off-by: Simon Shields <simon@lineageos.org> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Acked-by: Krzysztof Kozlowski <krzk@kernel.org> Link: https://lore.kernel.org/r/20200728131111.14334-2-s.nawrocki@samsung.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: samsung: Document DT bindings for Midas sound subsystemSylwester Nawrocki
This patch adds documentation of DT biding for the Midas sound complex. Partially based on the *txt version by Simon Shields <simon@lineageos.org>. Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> Link: https://lore.kernel.org/r/20200728131111.14334-1-s.nawrocki@samsung.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: tlv320adcx140: Move device reset to before programmingDan Murphy
Reset the device before programming the registers or all programming will be lost as the device resets registers to default settings. Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200730142419.28205-2-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: tlv320adcx140: Fix GPO register start addressDan Murphy
The header was updated to align with the data sheet to start the GPO_CFG at GPO_CFG0. The code was not updated to the change and therefore the GPO_CFG0 register was not written to. Fixes: 6617cff6a05e ("ASoC: tlv320adcx140: Add GPO configuration and drive output config") Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200730142419.28205-1-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: Intel: KMB: Rework disable channel functionMichael Sit Wei Hong
All channels are enabled at boot up, this patch ensures that all channels are disabled at boot and whenever the function is called. Signed-off-by: Michael Sit Wei Hong <michael.wei.hong.sit@intel.com> Reviewed-by: Sia Jee Heng <jee.heng.sia@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200730055319.1522-3-michael.wei.hong.sit@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: Intel: KMB: Add 8kHz audio supportMichael Sit Wei Hong
Enable 8kHz audio support for Intel Keem Bay platform. Signed-off-by: Michael Sit Wei Hong <michael.wei.hong.sit@intel.com> Reviewed-by: Sia Jee Heng <jee.heng.sia@intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200730055319.1522-2-michael.wei.hong.sit@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: meson: cards: remove DT_PREFIX for standard daifmt propertiesJerome Brunet
Standard dai format property don't need the "amlogic," prefix. There nothing amlogic specific about them. Just remove it. Fixes: 435857e015dc ("ASoC: meson: align axg card driver with DT bindings documentation") Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200729154456.1983396-5-jbrunet@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: meson: axg-tdm-formatters: fix sclk inversionJerome Brunet
After carefully checking, it appears that both tdmout and tdmin require the rising edge of the sclk they get to be synchronized with the frame sync event (which should be a rising edge of lrclk). TDMIN was improperly set before this patch. Remove the sclk_invert quirk which is no longer needed and fix the sclk phase. Fixes: 1a11d88f499c ("ASoC: meson: add tdm formatter base driver") Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200729154456.1983396-4-jbrunet@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: meson: axg-tdmin: fix g12a skewJerome Brunet
After carefully checking the result provided by the TDMIN on the g12a and sm1 SoC families, the TDMIN skew offset appears to be 3 instead of 2 on the axg. Fixes: f01bc67f58fd ("ASoC: meson: axg-tdm-formatter: rework quirks settings") Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200729154456.1983396-3-jbrunet@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-30ASoC: meson: axg-tdm-interface: fix link fmt setupJerome Brunet
The .set_fmt() callback of the axg tdm interface incorrectly test the content of SND_SOC_DAIFMT_MASTER_MASK as if it was a bitfield, which it is not. Implement the test correctly. Fixes: d60e4f1e4be5 ("ASoC: meson: add tdm interface driver") Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Link: https://lore.kernel.org/r/20200729154456.1983396-2-jbrunet@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-29ASoC: tlv320adcx140: Add GPO configuration and drive output configDan Murphy
Add General Purpose Output (GPO) configuration and driver output configuration. The GPOs can be configured as a GPO, IRQ, SDOUT or a PDMCLK output. In addition the output drive can be configured with various configurations. Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200728160833.24130-2-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-29dt-bindings: tlv320adcx140: Add GPO config and drive configDan Murphy
Add properties for configuring the General Purpose Outputs (GPO). The GPOs. There are 2 settings for each GPO, configuration and the output drive type. Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200728160833.24130-1-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-29ASoC: tlv320adcx140: Fix various style errors and warningsDan Murphy
Fix white space issues and remove else case where it was not needed. Convert "static const char *" to "static const char * const" Fixes: 689c7655b50 ("ASoC: tlv320adcx140: Add the tlv320adcx140 codec driver family") Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200728164339.16841-1-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: ak4613: Undo conversion to YAML bindingsMark Brown
Revert 5b235b5522bf38 ("ASoC: dt-bindings: ak4613: switch to yaml base Documentation") for the time being since it depends on other conversions. Reported-by: Rob Herring <robh+dt@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: bcm2835: Silence clk_get() error on -EPROBE_DEFERSeung-Woo Kim
Silence clk_get() error with dev_dbg() on -EPROBE_DEFER. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Link: https://lore.kernel.org/r/1595564371-13692-1-git-send-email-sw0312.kim@samsung.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28Merge series "SOF Fixes for S0iX suspend/resume sequence" from Ranjani ↵Mark Brown
Sridharan <ranjani.sridharan@linux.intel.com>: This set of patches is required for facilitating system S0ix entry when the DSP is in D0I3. This first patch adds the missing CORB/RIRB DMA stop and restart to the suspend/resume sequence along with powering up/down the links. The second patch ensures that the FW traces are disabled when the system enters S0ix with the DSP in D0I3. Marcin Rajwa (2): ASoC: SOF: Intel: fix the suspend procedure to support s0ix entry ASoC: SOF: Intel: disable traces when switching to S0Ix D0I3 sound/soc/sof/intel/hda-dsp.c | 48 ++++++++++++++++++++++++++++++++--- 1 file changed, 44 insertions(+), 4 deletions(-) -- 2.25.1
2020-07-28ASoC: tas2562: Convert the tas2562 binding to yamlDan Murphy
Convert the TAS2562 text file to yaml format. Signed-off-by: Dan Murphy <dmurphy@ti.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20200723160838.9738-1-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: tas2562: Update shutdown GPIO propertyDan Murphy
Update the shutdown GPIO property to be shutdown from shut-down. Fixes: c173dba44c2d2 ("ASoC: tas2562: Introduce the TAS2562 amplifier") Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200723160838.9738-2-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: convert Everest ES8316 binding to yamlKatsuhiro Suzuki
This patch converts Everest Semiconductor ES8316 low power audio CODEC binding to DT schema. Signed-off-by: Katsuhiro Suzuki <katsuhiro@katsuster.net> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20200724155933.1040501-1-katsuhiro@katsuster.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: madera: Add channel numbers to AIFsCharles Keepax
Set the channel number on each AIF widget to allow unused channels not to be powered up across AIFs. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20200728144141.16104-1-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: SOF: Intel: disable traces when switching to S0Ix D0I3Marcin Rajwa
We should always disable DMA trace on S0Ix. When staying at S0-D0I3, we should enable DMA trace while both DMA Trace debug is enabled and hda_enable_trace_D0I3_S0 is set. This commit corrects the existed logic errors about that. Signed-off-by: Marcin Rajwa <marcin.rajwa@linux.intel.com> Signed-off-by: Keyon Jie <yang.jie@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Link: https://lore.kernel.org/r/20200727183613.1419005-3-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-28ASoC: SOF: Intel: fix the suspend procedure to support s0ix entryMarcin Rajwa
This patch fixes the suspend & resume procedure to allow entry into the low power states with some streams being active as a wake source - wake on voice is a perfect example. The current implementation does not stop the CORB/RIRB DMA and does not power down the HDA links. With firmware's help, the platform has been able to still enter s0ix state on older platforms, but the sequence is still incorrect, and the additional driver actions are needed to ensure correct s0ix behaviour. Signed-off-by: Marcin Rajwa <marcin.rajwa@linux.intel.com> Signed-off-by: Keyon Jie <yang.jie@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Link: https://lore.kernel.org/r/20200727183613.1419005-2-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-27Merge series "ASoC: intel: use asoc_substream_to_rtd()" from Kuninori ↵Mark Brown
Morimoto <kuninori.morimoto.gx@renesas.com>: Hi Mark I have posted "ASoC: add asoc_substream_to_rtd() macro" patch-set to ALSA SoC ML (= see Link), and then Pierre-Louis wanted that Intel patch was separated for boards. The patches which are not for Intel were already accepted. This is for Intel, and Intel boards. Link: https://lore.kernel.org/r/87y2nf0yw2.wl-kuninori.morimoto.gx@renesas.com Link: https://lore.kernel.org/r/877duz0ysw.wl-kuninori.morimoto.gx@renesas.com Kuninori Morimoto (2): ASoC: intel/boards: use asoc_substream_to_rtd() ASoC: intel: use asoc_substream_to_rtd() sound/soc/intel/atom/sst-mfld-platform-pcm.c | 6 +++--- sound/soc/intel/baytrail/sst-baytrail-pcm.c | 16 ++++++++-------- sound/soc/intel/boards/bdw-rt5650.c | 2 +- sound/soc/intel/boards/bdw-rt5677.c | 4 ++-- sound/soc/intel/boards/broadwell.c | 2 +- sound/soc/intel/boards/bxt_rt298.c | 2 +- sound/soc/intel/boards/byt-rt5640.c | 2 +- sound/soc/intel/boards/bytcht_da7213.c | 4 ++-- sound/soc/intel/boards/bytcr_rt5640.c | 2 +- sound/soc/intel/boards/bytcr_rt5651.c | 2 +- sound/soc/intel/boards/cht_bsw_max98090_ti.c | 2 +- sound/soc/intel/boards/cht_bsw_nau8824.c | 2 +- sound/soc/intel/boards/cht_bsw_rt5645.c | 2 +- sound/soc/intel/boards/cht_bsw_rt5672.c | 2 +- sound/soc/intel/boards/cml_rt1011_rt5682.c | 4 ++-- sound/soc/intel/boards/ehl_rt5660.c | 2 +- sound/soc/intel/boards/glk_rt5682_max98357a.c | 2 +- sound/soc/intel/boards/haswell.c | 2 +- sound/soc/intel/boards/kbl_da7219_max98927.c | 8 ++++---- sound/soc/intel/boards/kbl_rt5660.c | 2 +- sound/soc/intel/boards/kbl_rt5663_max98927.c | 4 ++-- .../intel/boards/kbl_rt5663_rt5514_max98927.c | 4 ++-- sound/soc/intel/boards/skl_nau88l25_max98357a.c | 2 +- sound/soc/intel/boards/skl_nau88l25_ssm4567.c | 2 +- sound/soc/intel/boards/skl_rt286.c | 2 +- sound/soc/intel/boards/sof_da7219_max98373.c | 2 +- sound/soc/intel/boards/sof_maxim_common.c | 4 ++-- sound/soc/intel/boards/sof_pcm512x.c | 4 ++-- sound/soc/intel/boards/sof_rt5682.c | 4 ++-- sound/soc/intel/boards/sof_sdw_rt1308.c | 2 +- sound/soc/intel/boards/sof_wm8804.c | 2 +- sound/soc/intel/haswell/sst-haswell-pcm.c | 12 ++++++------ sound/soc/intel/keembay/kmb_platform.c | 2 +- sound/soc/intel/skylake/skl-pcm.c | 8 ++++---- 34 files changed, 62 insertions(+), 62 deletions(-) -- 2.25.1
2020-07-27ASoC: dt-bindings: q6asm: Add Q6ASM_DAI_{TX_RX, TX, RX} definesStephan Gerhold
Right now the direction of a DAI has to be specified as a literal number in the device tree, e.g.: dai@0 { reg = <0>; direction = <2>; }; but this does not make it immediately clear that this is a playback/RX-only DAI. Actually, q6asm-dai.c has useful defines for this. Move them to the dt-bindings header to allow using them in the dts(i) files. The example above then becomes: dai@0 { reg = <0>; direction = <Q6ASM_DAI_RX>; }; which is immediately recognizable as playback/RX-only DAI. Signed-off-by: Stephan Gerhold <stephan@gerhold.net> Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200727082502.2341-1-stephan@gerhold.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-27ASoC: AMD: Restore PME_EN state at Power OnAkshu Agrawal
PME_EN state needs to restored to the value set by fmw. For the devices which are not using I2S wake event which gets enabled by PME_EN bit, keeping PME_EN enabled burns considerable amount of power as it blocks low power state. For the devices using I2S wake event, PME_EN gets enabled in fmw and the state should be maintained after ACP Power On. Signed-off-by: Akshu Agrawal <akshu.agrawal@amd.com> Link: https://lore.kernel.org/r/20200724195600.11798-1-akshu.agrawal@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-27ASoC: intel: use asoc_substream_to_rtd()Kuninori Morimoto
Now we can use asoc_substream_to_rtd() macro, let's use it. 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/87tuxtydcz.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-27ASoC: intel/boards: use asoc_substream_to_rtd()Kuninori Morimoto
Now we can use asoc_substream_to_rtd() macro, let's use it. 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/87v9i9yddc.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: dapm: don't call pm_runtime_* on card deviceTzung-Bi Shih
runtime_usage of sound card has been observed to grow without bound. For example: $ cat /sys/devices/platform/sound/power/runtime_usage 46 $ sox -n -t s16 -r 48000 -c 2 - synth 1 sine 440 vol 0.1 | \ aplay -q -D hw:0,0 -f S16_LE -r 48000 -c 2 $ cat /sys/devices/platform/sound/power/runtime_usage 52 Commit 4e872a46823c ("ASoC: dapm: Don't force card bias level to be updated") stops to force update bias_level on card. If card doesn't provide set_bias_level callback, the snd_soc_dapm_set_bias_level() is equivalent to NOP for card device. As a result, dapm_pre_sequence_async() doesn't change the bias_level of card device correctly. Thus, pm_runtime_get_sync() would be called in dapm_pre_sequence_async() without symmetric pm_runtime_put() in dapm_post_sequence_async(). Don't call pm_runtime_* on card device. Signed-off-by: Tzung-Bi Shih <tzungbi@google.com> Link: https://lore.kernel.org/r/20200724070731.451377-1-tzungbi@google.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24Merge series "ASoC: qcom: Use qcom_snd_parse_of() for apq8016_sbc" from ↵Mark Brown
Stephan Gerhold <stephan@gerhold.net>: At the moment we have two separate functions to parse the sound card properties from the device tree: qcom_snd_parse_of() for DPCM and apq8016_sbc_parse_of() without DPCM. These functions are almost identical except for a few minor differences. This patch set extends qcom_snd_parse_of() to handle links without DPCM, so that we can use one common function for all (qcom) machine drivers. Stephan Gerhold (7): ASoC: qcom: Use devm for resource management ASoC: qcom: common: Use snd_soc_dai_link_set_capabilities() ASoC: q6afe: Remove unused q6afe_is_rx_port() function ASoC: qcom: common: Support parsing links without DPCM ASoC: qcom: common: Parse properties with "qcom," prefix ASoC: qcom: apq8016_sbc: Use qcom_snd_parse_of() ASoC: qcom: common: Avoid printing errors for -EPROBE_DEFER sound/soc/qcom/Kconfig | 1 + sound/soc/qcom/apq8016_sbc.c | 120 ++++------------------------------- sound/soc/qcom/apq8096.c | 28 +------- sound/soc/qcom/common.c | 58 ++++++++++------- sound/soc/qcom/qdsp6/q6afe.c | 8 --- sound/soc/qcom/qdsp6/q6afe.h | 1 - sound/soc/qcom/sdm845.c | 40 ++---------- 7 files changed, 59 insertions(+), 197 deletions(-) -- 2.27.0
2020-07-24ASoC: max98390: update dsm param bin max sizeSteve Lee
MAX98390_DSM_PARAM_MAX_SIZE is changed to support extended register update. Signed-off-by: Steve Lee <steves.lee@maximintegrated.com> Link: https://lore.kernel.org/r/20200724085644.9837-1-steves.lee@maximintegrated.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: max98390: Update dsm init sequence and condition.Steve Lee
Modify dsm_init sequence and dsm param bin check condition. - Move dsm_init() to after amp init setting to make sure dsm init is last setting. - dsm param bin check condition changed for extended register setting. Signed-off-by: Steve Lee <steves.lee@maximintegrated.com> Link: https://lore.kernel.org/r/20200724060149.19261-1-steves.lee@maximintegrated.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: soc-component: don't report of_xlate_dai_name failuresJerome Brunet
With commit e2329eeba45f ("ASoC: soc-component: add soc_component_err()") every error different for ENOTSUPP or EPROBE_DEFER will log an error. However, as explained in snd_soc_get_dai_name(), this callback may error to indicate that the DAI is not matched by the component tested. If the device provides other components, those may still match. Logging an error in this case is misleading. Don't use soc_component_ret() in snd_soc_component_of_xlate_dai_name() to avoid spamming the log. Fixes: e2329eeba45f ("ASoC: soc-component: add soc_component_err()") Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://lore.kernel.org/r/20200723142020.1338740-1-jbrunet@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: qcom: common: Avoid printing errors for -EPROBE_DEFERStephan Gerhold
qcom_snd_parse_of() tends to produce lots of error messages during bootup: MultiMedia1: error getting cpu dai name This happens because the DAIs are not probed until the ADSP remoteproc has booted, which takes a while. Until it is ready, snd_soc_of_get_dai_name() returns -EDEFER_PROBE to retry probing later. This is perfectly normal, so cleanup the kernel log a bit by not printing in case of -EPROBE_DEFER. Signed-off-by: Stephan Gerhold <stephan@gerhold.net> Tested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200723183904.321040-8-stephan@gerhold.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: qcom: apq8016_sbc: Use qcom_snd_parse_of()Stephan Gerhold
Now that we have updated qcom_snd_parse_of() to handle the device tree bindings used for apq8016_sbc, update the apq8016_sbc driver to use the common function and remove the duplicated code. Signed-off-by: Stephan Gerhold <stephan@gerhold.net> Tested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200723183904.321040-7-stephan@gerhold.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: qcom: common: Parse properties with "qcom," prefixStephan Gerhold
The apq8016_sbc device tree binding uses a "qcom," vendor prefix for all device tree properties, while qcom_snd_parse_of() uses the same properties without a prefix. In the future it would be nice to make this consistent, however, for backwards compatibility we need to parse both names to allow apq8016_sbc to use the common qcom_snd_parse_of() function. Signed-off-by: Stephan Gerhold <stephan@gerhold.net> Tested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200723183904.321040-6-stephan@gerhold.net Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-24ASoC: qcom: common: Support parsing links without DPCMStephan Gerhold
So far qcom_snd_parse_of() was only used to parse the device tree for boards using the QDSP6 driver together with DPCM. apq8016_sbc uses an almost identical version (apq8016_sbc_parse_of()) which parses links without DPCM. Given the similarity of the two functions it is useful to combine these two. To allow using qcom_snd_parse_of() in apq8016_sbc we need to support parsing links without DPCM as well. This is pretty simple: A DPCM link in the device tree is defined using: - DPCM frontend: "cpu" - DPCM backend: "cpu", "platform" and "codec" ... while a link without DPCM has "cpu" and "codec" (but no "platform"). Add a few more if conditions to handle links without DPCM correctly. Signed-off-by: Stephan Gerhold <stephan@gerhold.net> Tested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200723183904.321040-5-stephan@gerhold.net Signed-off-by: Mark Brown <broonie@kernel.org>