]> git.proxmox.com Git - mirror_ubuntu-kernels.git/log
mirror_ubuntu-kernels.git
5 years agoASoC: topology: Consolidate and fix asoc_tplg_dapm_widget_*_create flow
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:44 +0000 (13:36 +0200)]
ASoC: topology: Consolidate and fix asoc_tplg_dapm_widget_*_create flow

There are a few soc_tplg_dapm_widget_*_create functions with similar
content, but slightly different flow, unify their flow and make sure
that we go to error handler and free memory in case of failure.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Acked-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: topology: Consolidate how dtexts and dvalues are freed
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:43 +0000 (13:36 +0200)]
ASoC: topology: Consolidate how dtexts and dvalues are freed

Provide helper functions and use them to free dtexts and dvalues in
topology. This is followup cleanup after related changes in this area as
suggested in:
https://mailman.alsa-project.org/pipermail/alsa-devel/2019-January/144761.html

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>
5 years agoASoC: Intel: hdac_hdmi: Set ops to NULL on remove
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:42 +0000 (13:36 +0200)]
ASoC: Intel: hdac_hdmi: Set ops to NULL on remove

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>
5 years agoASoC: Intel: Skylake: Fix NULL ptr dereference when unloading clk dev
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:41 +0000 (13:36 +0200)]
ASoC: Intel: Skylake: Fix NULL ptr dereference when unloading clk dev

When driver is probed, we iterate over NHLT and check if clk entries are
present. For each such entry we call register_skl_clk and keep the
result in data->clk[].
Currently data->clk is sparsely indexed using NHLT table iterator, while
when freeing we use number of registered entries. Let's just use
data->avail_clk_cnt as index, so it can be reset back in
unregister_src_clk.

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>
5 years agoASoC: Intel: Skylake: Properly cleanup on component removal
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:40 +0000 (13:36 +0200)]
ASoC: Intel: Skylake: Properly cleanup on component removal

When we remove component we need to reverse things which were done on
init, this consists of topology cleanup, lists cleanup and releasing
firmware.

Currently cleanup handlers are put in wrong places or otherwise missing.
So add proper component cleanup function and perform cleanups in it.

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>
5 years agoASoC: Intel: Skylake: Add function to cleanup debugfs interface
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:39 +0000 (13:36 +0200)]
ASoC: Intel: Skylake: Add function to cleanup debugfs interface

Currently debugfs has no cleanup function. Add skl_debufs_exit function
so we can clean after ourselves properly.

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>
5 years agoASoC: Intel: Skylake: Don't return failure on machine driver reload
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:37 +0000 (13:36 +0200)]
ASoC: Intel: Skylake: Don't return failure on machine driver reload

When we unload and reload machine driver, we shouldn't return that we
failed to initialize. This allows to reload machine driver, without
having to unload whole stack.

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>
5 years agoASoC: compress: Fix memory leak from snd_soc_new_compress
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:36 +0000 (13:36 +0200)]
ASoC: compress: Fix memory leak from snd_soc_new_compress

Change kzalloc to devm_kzalloc, so compr gets automatically freed when
it's no longer needed.

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>
5 years agoALSA: hdac: Fix codec name after machine driver is unloaded and reloaded
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:35 +0000 (13:36 +0200)]
ALSA: hdac: Fix codec name after machine driver is unloaded and reloaded

Currently on each driver reload internal counter is being increased. It
causes failure to enumerate driver devices, as they have hardcoded:
.codec_name = "ehdaudio0D2",
As there is currently no devices with multiple hda codecs and there is
currently no established way to reliably differentiate, between them,
always assign bus->idx = 0;

This fixes a problem when we unload and reload machine driver idx gets
incremented, so .codec_name would've needed to be set to "ehdaudio1D2"
after first reload and so on.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Acked-by: Takashi Iwai <tiwai@suse.de>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: Intel: Skylake: Initialize lists before access so they are safe to use
Amadeusz Sławiński [Mon, 17 Jun 2019 11:36:34 +0000 (13:36 +0200)]
ASoC: Intel: Skylake: Initialize lists before access so they are safe to use

If skl_probe_work() was not run driver ends up dereferencing NULL
pointer when operating on lists in skl_platform_unregister().
To fix this initialize lists in skl_create(). Also run
cancel_work_sync() before all cleanup functions, so we don't end up
unnecessarily running probe work.

Easily reproducible with:
while true; do modprobe snd_soc_skl; rmmod snd_soc_skl; done
(with the assumption that relevant drivers are added to blacklist on
system boot)

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>
5 years agoASoC: Intel: Skylake: Use recommended SDxFMT programming sequence
Paweł Harłoziński [Thu, 13 Jun 2019 19:04:31 +0000 (21:04 +0200)]
ASoC: Intel: Skylake: Use recommended SDxFMT programming sequence

For BXT platforms, the recommended sequence to program the SDxFMT is to
first couple the stream, write the format and decouple again.
For all other platforms said sequence remains unchanged.

To prevent code duplication, IS_BXT (and consequently IS_CFL) macro is
relocated to hda_codec.h file so it can be accessed by SKL driver.

Signed-off-by: Paweł Harłoziński <pawel.harlozinski@intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rt5677: depop stereo dac
Curtis Malainey [Mon, 24 Jun 2019 20:52:39 +0000 (13:52 -0700)]
ASoC: rt5677: depop stereo dac

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>
5 years agoASoC: rk3399_gru_sound: Support 32, 44.1 and 88.2 kHz sample rates
Enric Balletbo i Serra [Fri, 21 Jun 2019 15:58:08 +0000 (17:58 +0200)]
ASoC: rk3399_gru_sound: Support 32, 44.1 and 88.2 kHz sample rates

According to the datasheet the max98357a also supports 32, 44.1 and
88.2 kHz sample rate. This support was also introduced recently by
commit fdf34366d324 ("ASoC: max98357a: add missing supported rates").

Actually the machine driver validates the supported sample rates but
this is not really needed because the component driver can all apply
whatever constraints are needed and do their own validation. So, remove
the checks from the machine driver as are not needed at all. This way,
we also support 32, 44.1 and 88.2 kHz sample rates and we get rid of the
errors like the below.

  rk3399-gru-sound sound: rockchip_sound_max98357a_hw_params() doesn't support this sample rate: 44100
  rk3399-gru-sound sound: ASoC: machine hw_params failed: -22

Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc-core: use soc_find_component() at snd_soc_find_dai()
Kuninori Morimoto [Thu, 20 Jun 2019 00:49:33 +0000 (09:49 +0900)]
ASoC: soc-core: use soc_find_component() at snd_soc_find_dai()

snd_soc_find_dai() finds component first via specified
snd_soc_dai_link_component, and find DAI from it.

We already have soc_find_component() to find component,
but soc_find_dai() has original implementation to find component.

We shouldn't have duplicate implementation to do same things.
This patch uses soc_find_component() at soc_find_dai()

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc-core: soc_find_component() uses snd_soc_dai_link_component
Kuninori Morimoto [Thu, 20 Jun 2019 00:49:27 +0000 (09:49 +0900)]
ASoC: soc-core: soc_find_component() uses snd_soc_dai_link_component

soc_find_component() is using "of_node" and "name" to finding component,
but we should use snd_soc_dai_link_component now, because it is created
to such purpose.

This patch uses snd_soc_dai_link_component for soc_find_component().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc-core: soc_find_component() uses snd_soc_is_matching_component()
Kuninori Morimoto [Thu, 20 Jun 2019 00:49:23 +0000 (09:49 +0900)]
ASoC: soc-core: soc_find_component() uses snd_soc_is_matching_component()

ALSA SoC already has snd_soc_is_matching_component() to confirming
matching component, but, soc_find_component() has original
implementation to confirm component.

We shouldn't have duplicate implementation to do same things.
This patch uses snd_soc_is_matching_component() at soc_find_component()

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc-core: move soc_find_component()
Kuninori Morimoto [Thu, 20 Jun 2019 00:49:17 +0000 (09:49 +0900)]
ASoC: soc-core: move soc_find_component()

move soc_find_component() next to snd_soc_is_matching_component().
This is prepare for soc_find_component() cleanup

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: remove duplicated include from hda.c
YueHaibing [Thu, 20 Jun 2019 14:57:09 +0000 (14:57 +0000)]
ASoC: SOF: Intel: hda: remove duplicated include from hda.c

Remove duplicated include.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rt5514-spi: don't use snd_soc_lookup_component()
Kuninori Morimoto [Thu, 20 Jun 2019 07:03:41 +0000 (16:03 +0900)]
ASoC: rt5514-spi: don't use snd_soc_lookup_component()

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>
5 years agoASoC: pcm3168a: Add support for multi DIN/DOUT with TDM slots parameter
Peter Ujfalusi [Thu, 20 Jun 2019 09:26:56 +0000 (12:26 +0300)]
ASoC: pcm3168a: Add support for multi DIN/DOUT with TDM slots parameter

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>
5 years agoASoC: pcm3168a: Rename min_frame_size to slot_width
Peter Ujfalusi [Thu, 20 Jun 2019 09:26:55 +0000 (12:26 +0300)]
ASoC: pcm3168a: Rename min_frame_size to slot_width

It represents slot size and not frame.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: davinci-mcasp: Fix slot mask settings when using multiple AXRs
Peter Ujfalusi [Thu, 20 Jun 2019 09:20:02 +0000 (12:20 +0300)]
ASoC: ti: davinci-mcasp: Fix slot mask settings when using multiple AXRs

If multiple serializers are connected in the system and the number of
channels will need to use more than one serializer the mask to enable the
serializers were left to 0 if tdm_mask is provided

Fixes: dd55ff8346a97 ("ASoC: davinci-mcasp: Add set_tdm_slots() support")
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: davinci-mcasp: Set unused serializers as INACTIVE
Peter Ujfalusi [Thu, 20 Jun 2019 09:20:01 +0000 (12:20 +0300)]
ASoC: ti: davinci-mcasp: Set unused serializers as INACTIVE

Unused serializers needs to be configured as INACTIVE, otherwise they will
underflow/overflow when multiple serializers are connected, but some are
not needed for the given stream.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: Intel: Skylake: Switch to modern UUID API
Andy Shevchenko [Wed, 19 Jun 2019 15:02:13 +0000 (18:02 +0300)]
ASoC: Intel: Skylake: Switch to modern UUID API

Switch the driver to use modern UUID API, i.e. guid_t type and
accompanying functions, such as guid_equal().

Cc: Liam Girdwood <lgirdwood@gmail.com>
Cc: Mark Brown <broonie@kernel.org>
Cc: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: cs47l90: Add codec driver for Cirrus Logic CS47L90
Richard Fitzgerald [Wed, 19 Jun 2019 13:41:59 +0000 (14:41 +0100)]
ASoC: cs47l90: Add codec driver for Cirrus Logic CS47L90

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>
5 years agoASoC: cs47l85: Add codec driver for Cirrus Logic CS47L85
Richard Fitzgerald [Wed, 19 Jun 2019 13:41:58 +0000 (14:41 +0100)]
ASoC: cs47l85: Add codec driver for Cirrus Logic CS47L85

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>
5 years agoASoC: cs47l35: Add codec driver for Cirrus Logic CS47L35
Richard Fitzgerald [Wed, 19 Jun 2019 13:41:57 +0000 (14:41 +0100)]
ASoC: cs47l35: Add codec driver for Cirrus Logic CS47L35

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>
5 years agoASoC: madera: Add common support for Cirrus Logic Madera codecs
Richard Fitzgerald [Wed, 19 Jun 2019 13:41:56 +0000 (14:41 +0100)]
ASoC: madera: Add common support for Cirrus Logic Madera codecs

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>
5 years agoASoC: madera: Add DT bindings for Cirrus Logic Madera codecs
Richard Fitzgerald [Wed, 19 Jun 2019 13:41:55 +0000 (14:41 +0100)]
ASoC: madera: Add DT bindings for Cirrus Logic Madera codecs

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.

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>
5 years agoASoC: stm32: dfsdm: add 16 bits audio record support
Olivier Moysan [Wed, 19 Jun 2019 11:40:02 +0000 (13:40 +0200)]
ASoC: stm32: dfsdm: add 16 bits audio record support

Add support of audio 16 bits format record to STM32
DFSDM driver.

Signed-off-by: Olivier Moysan <olivier.moysan@st.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc-utils: remove dummy Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:44 +0000 (10:19 +0900)]
ASoC: soc-utils: remove dummy Platform

ALSA SoC used 2 type of Platform if sound card doesn't need
Platform.

1) use Dummy Platform as Platform component
2) use CPU component  as Platform component

Now, ALSA SoC allows "no Platform" settings, and it will behave
same as 2) case selection. And, all sound card which doesn't need
specific Platform are now not selecting Platform any more.

This means, no sound card is using dummy Platform on ALSA SoC any
more. This patch removes unused dummy Platform.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rockchip: rk3399_gru_sound: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:40 +0000 (10:19 +0900)]
ASoC: rockchip: rk3399_gru_sound: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: qcom: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:35 +0000 (10:19 +0900)]
ASoC: qcom: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: simple-card-utils: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:31 +0000 (10:19 +0900)]
ASoC: simple-card-utils: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ux500: mop500: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:28 +0000 (10:19 +0900)]
ASoC: ux500: mop500: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: rx51: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:24 +0000 (10:19 +0900)]
ASoC: ti: rx51: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: omap-twl4030: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:18 +0000 (10:19 +0900)]
ASoC: ti: omap-twl4030: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: omap-hdmi: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:14 +0000 (10:19 +0900)]
ASoC: ti: omap-hdmi: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: omap-abe-twl6040: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:11 +0000 (10:19 +0900)]
ASoC: ti: omap-abe-twl6040: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: ti: davinci-evm: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:08 +0000 (10:19 +0900)]
ASoC: ti: davinci-evm: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: trimslice: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:04 +0000 (10:19 +0900)]
ASoC: tegra: trimslice: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_wm9712: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:19:00 +0000 (10:19 +0900)]
ASoC: tegra: tegra_wm9712: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_wm8903: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:55 +0000 (10:18 +0900)]
ASoC: tegra: tegra_wm8903: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_wm8753: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:51 +0000 (10:18 +0900)]
ASoC: tegra: tegra_wm8753: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_sgtl5000: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:48 +0000 (10:18 +0900)]
ASoC: tegra: tegra_sgtl5000: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_rt5677: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:44 +0000 (10:18 +0900)]
ASoC: tegra: tegra_rt5677: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_rt5640: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:40 +0000 (10:18 +0900)]
ASoC: tegra: tegra_rt5640: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_max98090: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:36 +0000 (10:18 +0900)]
ASoC: tegra: tegra_max98090: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: tegra: tegra_alc5632: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:31 +0000 (10:18 +0900)]
ASoC: tegra: tegra_alc5632: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: sunxi: sun4i-codec: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:27 +0000 (10:18 +0900)]
ASoC: sunxi: sun4i-codec: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: sirf: sirf-audio: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:22 +0000 (10:18 +0900)]
ASoC: sirf: sirf-audio: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: samsung: tm2_wm5110: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:17 +0000 (10:18 +0900)]
ASoC: samsung: tm2_wm5110: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: samsung: snow: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:12 +0000 (10:18 +0900)]
ASoC: samsung: snow: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: samsung: smdk_wm8994: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:09 +0000 (10:18 +0900)]
ASoC: samsung: smdk_wm8994: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: samsung: arndale_rt5631: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:04 +0000 (10:18 +0900)]
ASoC: samsung: arndale_rt5631: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rockchip: rockchip_rt5645: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:18:00 +0000 (10:18 +0900)]
ASoC: rockchip: rockchip_rt5645: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rockchip: rockchip_max98090: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:55 +0000 (10:17 +0900)]
ASoC: rockchip: rockchip_max98090: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rockchip: rk3288_hdmi_analog: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:51 +0000 (10:17 +0900)]
ASoC: rockchip: rk3288_hdmi_analog: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: qcom: storm: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:26 +0000 (10:17 +0900)]
ASoC: qcom: storm: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: qcom: apq8016_sbc: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:22 +0000 (10:17 +0900)]
ASoC: qcom: apq8016_sbc: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: mxs: mxs-sgtl5000: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:18 +0000 (10:17 +0900)]
ASoC: mxs: mxs-sgtl5000: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: kirkwood: armada-370-db: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:14 +0000 (10:17 +0900)]
ASoC: kirkwood: armada-370-db: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: fsl: imx-audmix: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:10 +0000 (10:17 +0900)]
ASoC: fsl: imx-audmix: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: fsl: imx-spdif: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:17:06 +0000 (10:17 +0900)]
ASoC: fsl: imx-spdif: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: fsl: imx-sgtl5000: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:16:57 +0000 (10:16 +0900)]
ASoC: fsl: imx-sgtl5000: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: fsl: imx-es8328: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:16:51 +0000 (10:16 +0900)]
ASoC: fsl: imx-es8328: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: fsl: fsl-asoc-card: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:16:47 +0000 (10:16 +0900)]
ASoC: fsl: fsl-asoc-card: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: fsl: eukrea-tlv320: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:16:42 +0000 (10:16 +0900)]
ASoC: fsl: eukrea-tlv320: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: tse850-pcm5142: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:16:35 +0000 (10:16 +0900)]
ASoC: atmel: tse850-pcm5142: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: sam9x5_wm8731: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:16:10 +0000 (10:16 +0900)]
ASoC: atmel: sam9x5_wm8731: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: sam9g20_wm8731: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:15:26 +0000 (10:15 +0900)]
ASoC: atmel: sam9g20_wm8731: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: mikroe-proto: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:15:05 +0000 (10:15 +0900)]
ASoC: atmel: mikroe-proto: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: atmel_wm8904: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:14:48 +0000 (10:14 +0900)]
ASoC: atmel: atmel_wm8904: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: atmel-pdmic: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:14:28 +0000 (10:14 +0900)]
ASoC: atmel: atmel-pdmic: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: atmel: atmel-classd: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:14:23 +0000 (10:14 +0900)]
ASoC: atmel: atmel-classd: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: vc4: vc4_hdmi: don't select unnecessary Platform
Kuninori Morimoto [Wed, 19 Jun 2019 01:14:12 +0000 (10:14 +0900)]
ASoC: vc4: vc4_hdmi: don't select unnecessary Platform

ALSA SoC is now supporting "no Platform". Sound card doesn't need to
select "CPU component" as "Platform" anymore if it doesn't need
special Platform.
This patch removes such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc-core: allow no Platform on dai_link
Kuninori Morimoto [Wed, 19 Jun 2019 01:14:07 +0000 (10:14 +0900)]
ASoC: soc-core: allow no Platform on dai_link

dai_link is used to selecting Component (= CPU/Codec/Platform) and
DAI (= CPU/Codec). And selected CPU/Codec/Platform components are
*listed* on Card.

Many drivers don't need special Platform component, but was
mandatory at legacy style ALSA SoC.
Thus, there is this kind of settings on many drivers.

dai_link->platform_of_node = dai_link->cpu_of_node;

In this case, soc_bind_dai_link() will pick-up "CPU component" as
"Platform component", and try to add it to snd_soc_pcm_runtime.
But it will be ignored, because it is already added when CPU bindings.

Historically, this kind of "CPU component" is used/selected as
"Platform" on many ALSA SoC drivers.
OTOH, Dummy Platform will be selected automatically by ALSA SoC if
driver doesn't have Platform settings.

These indicates that there are 2 type of Platforms exist at current
ALSA SoC if driver doesn't need special Platform.

1) use Dummy Platform as Platform component
2) use CPU component  as Platform component

ALSA SoC will call Dummy Platform callback function if it is using
Dummy Platform, but it is completely pointless. Because it is the
sound card which doesn't need special Platform.

Thus, the behavior we request to ALSA SoC is selecting 2) automatically
instead of 1) if sound card doesn't need special Platform.
And, 2) means "do nothing" as above explain.

These were needed at legacy style dai_link, but is no longer needed
at modern style dai_link anymore.

This patch allows "no Platform" settings on dai_link, and will do
nothing for it if there was no platform settings. This is same as 2).

By this patch, all drivers which is selecting "CPU component" as
"Platform" can remove such settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rt5677: handle concurrent interrupts
Ben Zhang [Tue, 18 Jun 2019 23:45:55 +0000 (17:45 -0600)]
ASoC: rt5677: handle concurrent interrupts

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>
5 years agoASoC: rt5677: clear interrupts by polarity flip
Ben Zhang [Tue, 18 Jun 2019 23:45:54 +0000 (17:45 -0600)]
ASoC: rt5677: clear interrupts by polarity flip

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>
5 years agoASoC: qcom: common: Fix NULL pointer in of parser
Bjorn Andersson [Tue, 18 Jun 2019 05:28:13 +0000 (22:28 -0700)]
ASoC: qcom: common: Fix NULL pointer in of parser

A snd_soc_dai_link_component is allocated and associated with the first
link, so when the code tries to assign the of_node of the second link's
"cpu" member it dereferences a NULL pointer.

Fix this by moving the allocation and assignement of
snd_soc_dai_link_components into the loop, giving us one pair per link.

Fixes: 1e36ea360ab9 ("ASoC: qcom: common: use modern dai_link style")
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: Intel: sof-rt5682: correct naming for dmic16k
Keyon Jie [Tue, 18 Jun 2019 18:15:39 +0000 (02:15 +0800)]
ASoC: Intel: sof-rt5682: correct naming for dmic16k

Change the link name to be "dmic16k", the cpu_dai_name to be "DMIC16k
Pin", to be aligned with other machine drivers.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Bard liao <yung-chuan.liao@linux.intel.com>
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: Intel: sof-rt5682: add MCLK support for BYT platform
Xun Zhang [Tue, 18 Jun 2019 18:15:38 +0000 (02:15 +0800)]
ASoC: Intel: sof-rt5682: add MCLK support for BYT platform

The sof-rt5682 machine driver currently uses BCLK on BYT/Minnowboard
platform. The MCLK signal is available since the Turbot revision, so
enable MCLK on BYT/Minnowboard Turbot platform.

Signed-off-by: Xun Zhang <xun2.zhang@intel.com>
Signed-off-by: Bard liao <yung-chuan.liao@linux.intel.com>
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: soc.h: fixup for_each_card_links() macro
Kuninori Morimoto [Wed, 19 Jun 2019 01:27:52 +0000 (10:27 +0900)]
ASoC: soc.h: fixup for_each_card_links() macro

Macro is using "link", not "dai_link"

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rsnd: fixup mod ID calculation in rsnd_ctu_probe_
Nilkanth Ahirrao [Tue, 18 Jun 2019 05:19:53 +0000 (14:19 +0900)]
ASoC: rsnd: fixup mod ID calculation in rsnd_ctu_probe_

commit c16015f36cc1 ("ASoC: rsnd: add .get_id/.get_id_sub")
introduces rsnd_ctu_id which calcualates and gives
the main Device id of the CTU by dividing the id by 4.
rsnd_mod_id uses this interface to get the CTU main
Device id. But this commit forgets to revert the main
Device id calcution previously done in rsnd_ctu_probe_
which also divides the id by 4. This path corrects the
same to get the correct main Device id.

The issue is observered when rsnd_ctu_probe_ is done for CTU1

Fixes: c16015f36cc1 ("ASoC: rsnd: add .get_id/.get_id_sub")
Signed-off-by: Nilkanth Ahirrao <anilkanth@jp.adit-jv.com>
Signed-off-by: Suresh Udipi <sudipi@jp.adit-jv.com>
Signed-off-by: Jiada Wang <jiada_wang@mentor.com>
Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: Add missing newline at end of file
Geert Uytterhoeven [Mon, 17 Jun 2019 14:40:48 +0000 (16:40 +0200)]
ASoC: Add missing newline at end of file

"git diff" says:

    \ No newline at end of file

after modifying the files.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: rt5677: move jack-detect init to i2c probe
Fletcher Woodruff [Fri, 14 Jun 2019 19:48:52 +0000 (13:48 -0600)]
ASoC: rt5677: move jack-detect init to i2c probe

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>
5 years agoASoC: rt5677: fall back to DT prop names on error
Fletcher Woodruff [Fri, 14 Jun 2019 19:48:51 +0000 (13:48 -0600)]
ASoC: rt5677: fall back to DT prop names on error

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>
5 years agoASoC: SOF: disallow building without CONFIG_PCI again
Arnd Bergmann [Mon, 17 Jun 2019 12:45:49 +0000 (14:45 +0200)]
ASoC: SOF: disallow building without CONFIG_PCI again

Compile-testing without PCI just causes warnings:

sound/soc/sof/sof-pci-dev.c:330:13: error: 'sof_pci_remove' defined but not used [-Werror=unused-function]
 static void sof_pci_remove(struct pci_dev *pci)
             ^~~~~~~~~~~~~~
sound/soc/sof/sof-pci-dev.c:230:12: error: 'sof_pci_probe' defined but not used [-Werror=unused-function]
 static int sof_pci_probe(struct pci_dev *pci,
            ^~~~~~~~~~~~~

I tried to fix this in a way that would still allow compile
tests, but it got too ugly, so this just reverts the patch
that allowed it in the first place.

Most architectures do allow enabling PCI, so the value of the
COMPILE_TEST alternative was not very high to start with.

Fixes: e13ef82a9ab8 ("ASoC: SOF: add COMPILE_TEST for PCI options")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: make sure RUN bit setting to 0 during clear stream status
Zhu Yingjiang [Wed, 12 Jun 2019 17:23:47 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: make sure RUN bit setting to 0 during clear stream status

Before clearing stream statuses, ensure RUN bit update has taken
effect by reading the value back.

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: make sure DMA is start/stop by read the RUN bit
Zhu Yingjiang [Wed, 12 Jun 2019 17:23:46 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: make sure DMA is start/stop by read the RUN bit

As per the HW recommendation, after setting the RUN bit
(start as 1, stop as 0), software must read the bit back
to make sure the bit is set right, before modifying related
control registers/re-starting the DMA engine.

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: clear stream status and wakests properly
Ranjani Sridharan [Wed, 12 Jun 2019 17:23:45 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: clear stream status and wakests properly

Stream status and WAKESTS registers need to be cleared by writing
to them with snd_sof_dsp_write(). snd_sof_dsp_update_bits() only
writes if the value is changed and will result in not clearing
the status.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: use the defined stop chip in suspend
Zhu Yingjiang [Wed, 12 Jun 2019 17:23:44 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: use the defined stop chip in suspend

Unify suspend code by using SOF common function
hda_dsp_ctrl_stop_chip() which can handle both HDA
and non-HDA cases.

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: add function for hda stop chip
Zhu Yingjiang [Wed, 12 Jun 2019 17:23:43 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: add function for hda stop chip

Add common hda_dsp_ctrl_stop_chip() function to stop controller with
the same function handling both HDA and non-HDA cases. This function
disables IRQs and clears status masks. When CONFIG_SND_SOC_SOF_HDA
is defined, also disables the CORB/RIRB, and stops i/o.

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: use the SOF defined ppcap functions
Zhu Yingjiang [Wed, 12 Jun 2019 17:23:42 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: use the SOF defined ppcap functions

Unify ppcap function setup by using SOF common functions
for both HDA and non-HDA cases.

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda-stream: fix a deadlock with bus->reg_lock
Keyon Jie [Wed, 12 Jun 2019 17:23:41 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda-stream: fix a deadlock with bus->reg_lock

We should use irq disabled mode when read/write hda registers from
thread context, as we need to hold the same bus->reg_lock in interrupt
context hda_dsp_stream_interrupt(), otherwise, when we are holding the
lock in hda_dsp_stream_hw_free() and the interrupt arrives, we will get
deadlock in the interrupt handler.

Error logs like this:

[    5.603606]        CPU0
[    5.603606]        ----
[    5.603607]   lock(&(&bus->reg_lock)->rlock);
[    5.603608]   <Interrupt>
[    5.603609]     lock(&(&bus->reg_lock)->rlock);
[    5.603610]
                *** DEADLOCK ***

[    5.603611] 2 locks held by pulseaudio/2329:
[    5.603612]  #0: 000000005fcf26c6 (&card->mutex/1){+.+.}, at: dpcm_fe_dai_hw_free+0x2b/0x110 [snd_soc_core]
[    5.603619]  #1: 00000000ef369faf (&rtd->pcm_mutex){+.+.}, at: soc_pcm_hw_free+0x2e/0x1c0 [snd_soc_core]

The fix is simple, let's switch to use spin_lock/unlock_irq().

Reported-by: Xun Zhang <xun2.zhang@intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: modify stream interrupt handler
Ranjani Sridharan [Wed, 12 Jun 2019 17:23:40 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: modify stream interrupt handler

Modify the stream interrupt handler to always wake up the
IRQ thread if the status register is valid. The IRQ thread
performs the check for stream interrupts and RIRB interrupts
in a loop to handle the case of missed interrupts when an
unsolicited response from the codec is received just before the
stream interrupt handler is completed.

Signed-off-by: Kai Vehmanen <kai.vehmanen@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>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: couple host and link DMA during FE hw_free
Ranjani Sridharan [Wed, 12 Jun 2019 17:23:39 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: couple host and link DMA during FE hw_free

Host and link DMA are decoupled during FE hw_params. So,
they must be coupled in hw_free if the link DMA channel
is idle.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: release link DMA for paused streams during suspend
Ranjani Sridharan [Wed, 12 Jun 2019 17:23:38 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: release link DMA for paused streams during suspend

Paused streams do not get suspended when the system enters S3.
So, clear and release link DMA channel for such streams in the
hda_dsp_set_hw_params_upon_resume() callback. Also, invalidate
the link DMA channel in the DAI config before restoring the
dai config upon resume. Also, modify the signature for the
set_hw_params_upon_resume() op to return an int.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: reserve host DMA channel for hostless streams
Ranjani Sridharan [Wed, 12 Jun 2019 17:23:37 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: reserve host DMA channel for hostless streams

Due to the HW programming sequence requirement that the host
and link DMA channels need to be coupled/decoupled during pcm
hw_params, the host DMA channel corresponding to the link
DMA channel in use for hostless streams needs to be reserved.
This is achieved by adding a host_reserved flag in the
sof_intel_hda_stream structure which is checked when assigning
a host DMA channel.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
5 years agoASoC: SOF: Intel: hda: assign link DMA channel at run-time
Ranjani Sridharan [Wed, 12 Jun 2019 17:23:36 +0000 (12:23 -0500)]
ASoC: SOF: Intel: hda: assign link DMA channel at run-time

The recommended HDA HW programming sequence for setting
the DMA format requires that the link DMA and host DMA
channels be coupled before setting the format. This
change means that host DMA or link DMA channels be
reserved even if only one is used.

Statically assigned link DMA channels would mean that
all the corresponding host DMA channels will need to be
reserved, leaving only a few channels available at run-time.
So, the suggestion here is to switch to dynamically assigning
both host DMA channels and link DMA channels are run-time.

The host DMA channel is assigned when the pcm
is opened as before. While choosing the link DMA channel,
if the host DMA channel corresponding to the link DMA channel
is already taken, the proposed method checks to make
sure that the BE is connected to the FE that has been assigned
this host DMA channel. Once the link DMA channel is assigned,
an IPC is sent to the DSP to set the link DMA channel.

The link DMA channel is freed during hw_free() and also in the
SUSPEND trigger callback. It will be re-assigned when hw_params
are set upon resume.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>