Commit Graph

12106 Commits

Author SHA1 Message Date
Dan Carpenter 931dfa6931 ASoC: wm8904: harmless underflow in wm8904_put_deemph()
We try to check that "deemph" is zero or one, but because of an
underflow bug, it can also be negative.  It's fine, negative values are
handled as non-zero.  But it's messy and static checkers complain so
let's fix it.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:54:13 +01:00
Jie Yang 6f0c42269f ASoC: compress: add config item for soc-compress to make it compiled only when needed
We don't always need soc-compress in soc, here add a config item
SND_SOC_COMPRESS, when nobody select it, the soc-compress will
not be compiled.

Here also change Kconfig to 'select SND_SOC_COMPRESS' for drivers
that needed soc-compress.

Signed-off-by: Jie Yang <yang.jie@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:52:16 +01:00
Lars-Peter Clausen 26d9ca3462 ASoC: Let snd_soc_limit_volume() take a snd_soc_card
snd_soc_limit_volume() operates on a card and the CODEC that is passed in
is only used to look up the card. Let it directly take the card instead.
This makes it possible to use it when no snd_soc_codec is available.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Tested-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:49:20 +01:00
Oder Chiou 16566e4709 ASoC: rt5640: Fill up the IN3's support
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:33:00 +01:00
Jiada Wang 4eb0f7abce ASoC: wm8962: mark cache_dirty flag after software reset in pm_resume
By doing software reset of wm8962 in pm_resume, all registers which
have already been set will be reset to default value without regmap
interface be involved, thus driver need to mark cache_dirty flag,
to let regcache can be updated by regcache_sync().

Signed-off-by: Jiada Wang <jiada_wang@mentor.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:51 +01:00
Kuninori Morimoto b415b4d312 ASoC: rsnd: remove duplicate parameter from rsnd_ssi_xxx()
rsnd_ssi_use_busif() and rsnd_ssi_is_pin_sharing() are the function
which returns current SSI status. But these requests duplicated parameter.
This patch removes duplicated parameter.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto 69819f527a ASoC: rsnd: remove unused rsnd_dma_to_ssi() macro
rsnd_dma_to_ssi() is no longer used, let's remove it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto c992934501 ASoC: rsnd: rename rsnd_mod_hw_start/stop to rsnd_mod_power_on/off
rsnd_mod_hw_start/stop were unclear naming.
It became rsnd_mod_power_on/off by this patch

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto 89e3e2c352 ASoC: rsnd: fixup rsnd_dai_call() behavior for .stop/.quit
Current rsnd_dai_call returns immediately if rsnd_mod_call return fail.
Thus, each callback-count can be unbalanced for example .init was OK,
start was OK, but, .stop was not OK. This case .quit should be called
but isn't called. And, rsnd_dai_stream_quit() also not be called.
rsnd_dai_call() should call all .stop/.quit eventhough it returns error.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto 32a96d558d ASoC: rsnd: fixup rsnd_dai_call() behavior for unimplemented method
Current rsnd_dai_call didn't count callback-count if callback
wasn't implemented. Thus, it counts can be unbalance.
ex) .start : implemented
    .stop  : not implemented
This patch solve this issue

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto 1355720a3b ASoC: rsnd: fixup rsnd_mod_call() behavior for debug
Indicating each module method as debug message before executing is
readable/understandable.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto b05ce4c091 ASoC: rsnd: fixup devm_request_irq() option on ssi.c
bfc0cfe("ASoC: rsnd: don't use rsnd_mod_to_io() on rsnd_ssi_xxx()")
tidyuped devm_request_irq() option from ssi to mod, but devm_free_irq()
on rsnd_ssi_dma_remove() didn't modified. This patch fixups this issue.
Otherwise kernel will output WARNING message.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto 9993c16d46 ASoC: rsnd: fixup struct rsnd_gen::res array size
struct rsnd_gen :: res array size should be RSND_BASE_MAX,
not RSND_REG_MAX. This patch fixup it, and indicates whether
each data array size is based on what

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Kuninori Morimoto c9b9638f61 ASoC: rsnd: fixup print debug message after read
debug meesage for rsnd_mod_read() should be prints after read

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-22 13:30:01 +01:00
Scott Wood 9484865447 powerpc/fsl: Move fsl_guts.h out of arch/powerpc
Freescale's Layerscape ARM chips use the same structure.

Signed-off-by: Scott Wood <scottwood@freescale.com>
2015-10-21 18:05:50 -05:00
Axel Lin c5cff89b5f ASoC: da7219: Fix da7219->alc_en state when enabling ALC
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Tested-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-10-21 13:30:23 +01:00
Lars-Peter Clausen a5be88f63e ASoC: cht_bsw_rt5672: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function rather than
installing a list constraint with a single value. Since
snd_pcm_hw_constraint_single() sets a static constraint while
snd_pcm_hw_constraint_list() sets a dynamic constraint the former is
slightly more efficient and it also needs less code.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:26:23 +02:00
Lars-Peter Clausen 3d6a76c48e ASoC: cht_bsw_rt5645: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function rather than
installing a list constraint with a single value. Since
snd_pcm_hw_constraint_single() sets a static constraint while
snd_pcm_hw_constraint_list() sets a dynamic constraint the former is
slightly more efficient and it also needs less code.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:26:11 +02:00
Lars-Peter Clausen a6553a24d4 ASoC: cht_bsw_max98090: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function rather than
installing a list constraint with a single value. Since
snd_pcm_hw_constraint_single() sets a static constraint while
snd_pcm_hw_constraint_list() sets a dynamic constraint the former is
slightly more efficient and it also needs less code.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:26:04 +02:00
Lars-Peter Clausen d0a1b66074 ASoC: bytcr_rt5640: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function rather than
installing a list constraint with a single value. Since
snd_pcm_hw_constraint_single() sets a static constraint while
snd_pcm_hw_constraint_list() sets a dynamic constraint the former is
slightly more efficient and it also needs less code.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:25:58 +02:00
Lars-Peter Clausen 1bf2d35b87 ASoC: ux500: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:25:51 +02:00
Lars-Peter Clausen 4dcdd43b46 ASoC: pcm: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer and is slightly shorter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:25:42 +02:00
Lars-Peter Clausen be448b4fa4 ASoC: rx51: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer and is slightly shorter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Tested-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:25:35 +02:00
Lars-Peter Clausen 8dfabe7ab1 ASoC: n810: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer and is slightly shorter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:25:28 +02:00
Lars-Peter Clausen 95c68b86be ASoC: wl1273: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:25:21 +02:00
Lars-Peter Clausen 0de8ab983f ASoC: uda134x: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer and is slightly shorter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:24:52 +02:00
Lars-Peter Clausen e795d83155 ASoC: twl4030: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer and is slightly shorter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:24:44 +02:00
Lars-Peter Clausen 153e2f5ca1 ASoC: adav80x: Use snd_pcm_hw_constraint_single()
Use the new snd_pcm_hw_constraint_single() helper function instead of
calling snd_pcm_hw_constraint_minmax() with the same value for min and max
to install a constraint that limits the possible configuration values to a
single value. Using snd_pcm_hw_constraint_single() makes the indented
result clearer.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-21 14:24:34 +02:00
Bard Liao f8f2dc4a71 ASoC: rt298: fix wrong setting of gpio2_en
The register value to enable gpio2 was incorrect. So fix it.

Signed-off-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-21 13:23:43 +01:00
Axel Lin ce7b8dbdde ASoC: ssm2518: Drop .volatile_reg implementation
The implementation of ssm2518_register_volatile always returns false,
this behavior is the same as no .volatile_reg callback implementation
when cache_type != REGCACHE_NONE.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-20 17:00:29 +01:00
Axel Lin 92b822a499 ASoC: ad193x: Drop .volatile_reg implementation
adau193x_reg_volatile() always return false.
This seems pointless because current code uses REGCACHE_NONE cache_type
which is supposed to be volatile.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-20 16:59:29 +01:00
Axel Lin 355b27e181 ASoC: ad193x-spi: Add adau1328 to ad193x_spi_id table
This driver also supports adau1328, thus add adau1328 to ad193x_spi_id.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-19 20:33:33 +01:00
Omair M Abdullah 624729fd51 ASoC: Intel: Skylake - Add Skylake RT286 I2S machine driver
Add the SKL I2S machine driver using Realtek ALC286S codec
in I2S mode.

Signed-off-by: Omair M Abdullah <omair.m.abdullah@intel.com>
Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-19 20:28:48 +01:00
Axel Lin 2057020db3 ASoC: rockchip: spdif: Convert to use devm_snd_dmaengine_pcm_register
Use resource managed API then we can remove snd_dmaengine_pcm_unregister()
and snd_soc_unregister_component() calls in .probe error path and .remove.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-19 20:15:16 +01:00
Oder Chiou c962d03be3 ASoC: rt5645: Recheck the jack detect status after resuming from S3
The patch rechecks the jack detect status after resuming from S3.

Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-16 19:04:57 +01:00
Mark Brown 3db7cb9518 Merge branch 'fix/rt298' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-rt298 2015-10-16 18:17:31 +01:00
Axel Lin 3943b9efb3 ASoC: rt298: Make rt298_index_def const
The index_cache is per instance run time state but rt298_index_def is not.
Make rt298_index_def const and make a copy of memory for index_cache rather
than directly use the rt298_index_def.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-16 18:13:35 +01:00
Charles Keepax 34198710f5 ASoC: Add info callback for SX_TLV controls
SX_TLV controls are intended for situations where the register behind
the control has some non-zero value indicating the minimum gain
and then gains increasing from there and eventually overflowing through
zero.

Currently every CODEC implementing these controls specifies the minimum
as the non-zero value for the minimum and the maximum as the number of
gain settings available.

This means when the info callback subtracts the minimum value from the
maximum value to calculate the number of gain levels available it is
actually under reporting the available levels. This patch fixes this
issue by adding a new snd_soc_info_volsw_sx callback that does not
subtract the minimum value.

Fixes: 1d99f2436d ("ASoC: core: Rework SOC_DOUBLE_R_SX_TLV add SOC_SINGLE_SX_TLV")
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Acked-by: Brian Austin <brian.austin@cirrus.com>
Tested-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-10-16 16:17:25 +01:00
Kuninori Morimoto 8a98b4223d ASoC: rsnd: Gen1 probe is not error
Probing from Gen1 is not error. This patch fixup it

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-16 15:21:35 +01:00
Bard Liao 7ba6e4ef76 ASoC: rt298: correct index default value
Some of the default value on rt298_index_def are incorrect. Change
them to the correct value.

Signed-off-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-16 15:21:13 +01:00
Kuninori Morimoto 4362495734 ASoC: rsnd: Announce for removing Gen1 SRU support
Gen1 SRU support was created for preparation of Gen2 SRC support,
but no-one is using this feature (sampling rate convert) on Gen1.
BockW had used SRU before, but it was pass through mode.
This means it is same as SSI. And BockW "platform base" code was
removed from upstream code. It is now supported via DT, but it doesn't
use SRU. More detail, r8a7778.dtsi has "rcar_sound,src" entry, but
no-one is using this feature today. SRU probing has no relation to this
removing. This means there is no effect for DT compatibility, no issues
on upstream kernel.

Gen2 SRC was created from Gen1 SRU, these are similar but not same IP.
Keeping Gen1 SRU in current driver is a little bit difficult,
and no-one is using it today. Gen1 sound is still supported via SSI.
Gen1 SRU support will be removed in the next kernel version.
This patch announces it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-14 10:11:10 +01:00
Takashi Iwai 3c69ea4440 Merge branch 'for-linus' into for-next 2015-10-13 11:37:06 +02:00
Bard Liao a5fe58fd28 ASoC: rt298: set register non-volatile by default
It is not necessary to set registers volatile. So, return false
for default case of rt298_volatile_register.

Signed-off-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-12 18:02:03 +01:00
Masanari Iida 4272975a34 ASoC: sh: Fit typo in Kconfig
s/SUR/SRU/g

Signed-off-by: Masanari Iida <standby24x7@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-12 16:58:31 +01:00
Jeeja KP 01bb84b500 ASoC: Intel: Skylake: power down all link in suspend
This ensures that the link is not requesting any clock and the
PLL can turn off. The link is powered when controller is brought
out of reset.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-09 11:19:01 +01:00
Jeeja KP 84c9e2836a ASoC: Intel: Skylake: Correct the runtime handler behaviour
On runtime pm resume, we need to download the firmware, also on
suspend we need to ensure all the interrupts from controller and
DSP are disabled.

Also since we download the firmware on resume, we don't need to do
so on init, so remove that bit

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-09 11:19:00 +01:00
Jeeja KP def656fe22 ASoC: Intel: Skylake: Verify the status bit before handling interrupt
Like we have in legacy mode HDA driver, we need to check the
status bit and handle interrupt only when it is not zero or all
bits set.  We typically see the status as all 1's when controller
resumes from suspend, So add the check here as well and don't
handle for these cases.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-09 11:18:59 +01:00
Jeeja KP 6ea8ba33e6 ASoC: Intel: Skylake: Check CPA bit in DSP core power down
Skylake driver will set the SPA bit to 0 to turn off the DSP core.
Driver will poll the Current Power Active (CPA) bit to match the
Set Power Active (SPA) bit value. When CPA bit matches the value
of SPA bit, the achieved power state has reached.

In case of DSP power down, register that was polled is SPA
instead of CPA. This patch corrects the register to be polled
in case of DSP power down.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-09 11:18:58 +01:00
Sudip Mukherjee dc542fb417 ASoC: rt5645: fix build warning
We were getting build warning about "Section mismatch".
dmi_platform_intel_broadwell is being referenced from the probe function
rt5645_i2c_probe(), but dmi_platform_intel_broadwell was marked with
__initdata.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Reviewed-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-08 16:15:00 +01:00
Sjoerd Simons f874b80e15 ASoC: rockchip: Add rockchip SPDIF transceiver driver
Add a driver for the SPDIF transceiver available on RK3066, RK3188 and
RK3288. Heavily based on the rockchip i2s driver.

Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-08 16:12:01 +01:00
Fang, Yang A b3681308cc ASoC: nau8825: add acpi match ID
This patch adds the acpi match ID for nau8825 codec

Signed-off-by: Fang, Yang A <yang.a.fang@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-08 14:38:42 +01:00
Vinod Koul 3373f71683 ASoC: Intel: Skylake: Modify the log level
dev_info is too noisy for tplg wiget loading, so move it to
debug level

Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-08 09:46:22 +01:00
Mark Brown e4fc141d2a Merge remote-tracking branches 'asoc/fix/tlv320aic3x' and 'asoc/fix/wm8962' into asoc-linus 2015-10-07 16:07:50 +01:00
Mark Brown 1e2fa4cfdb Merge remote-tracking branches 'asoc/fix/db1200', 'asoc/fix/dwc', 'asoc/fix/imx-ssi', 'asoc/fix/maintainers', 'asoc/fix/rt5645', 'asoc/fix/sgtl5000' and 'asoc/fix/tas2552' into asoc-linus 2015-10-07 16:07:16 +01:00
Jeeja KP 87b2bdf022 ASoC: Intel: Skylake: Initialize NHLT table
Load and Initialize Non HDA Link Table in Skylake driver
to get platform configuration.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 16:04:17 +01:00
Jeeja KP 2a29b200c6 ASoC: Intel: Skylake: Add DSP support and enable it
If processing pipe capability is supported, add DSP support.
Adds initialization/free/suspend/resume DSP functionality.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 16:04:16 +01:00
Jeeja KP b663a8c5c9 ASoC: Intel: Skylake: Initialize and load DSP controls
Initialize and creates DSP controls if processing pipe capability
is supported by HW. Updates the dma_id, hw_params to module param
to be used when DSP module has to be configured.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 16:04:15 +01:00
Vinod Koul 3af36706ff ASoC: Intel: Skylake: Add topology core init and handlers
The SKL driver does not code DSP topology in driver. It uses the
newly added ASoC topology core to parse the topology information
(controls, widgets and map) from topology binary.
Each topology element passed private data which contains
information that driver used to identify the module instance
within firmware and send IPCs for that module to DSP firmware
along with parameters.
This patch adds init routine to invoke topology load and callback
for topology creation.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 16:04:14 +01:00
Vinod Koul cfb0a87383 ASoC: Intel: Skylake: Add FE and BE hw_params handling
For FE and BE, the PCM parameters come from FE and BE hw_params
values passed. For a FE we convert the FE params to DSP expected
module format and pass to DSP. For a BE we need to find the
gateway settings (i2s/PDM) to be applied. These are queried from
NHLT table and applied.

Further for BE based on direction the settings are applied as
either source or destination parameters.

These helpers here allow the format to be calculated and queried
as per firmware format.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 15:30:16 +01:00
Vinod Koul d93f8e550f ASoC: Intel: Skylake: add DSP platform widget event handlers
The Skylake driver topology model tries to model the firmware
rule for pipeline and module creation.
The creation rule is:
 - Create Pipe
 - Add modules to Pipe
 - Connect the modules (bind)
 - Start the pipes

Similarly destroy rule is:
 - Stop the pipe
 - Disconnect it (unbind)
 - Delete the pipe

In driver we use Mixer, as there will always be ONE mixer in a
pipeline to model a pipe. The modules in pipe are modelled as PGA
widgets.  The DAPM sequencing rules (mixer and then PGA) are used
to create the sequence DSP expects as depicted above, and then
widget handlers for PMU and PMD events help in that.

This patch adds widget event handlers for PRE/POST PMU and
PRE/POST PMD event for mixer and pga modules.  These event
handlers invoke pipeline creation, destroy, module creation,
module bind, unbind and pipeline bind unbind

Event handler sequencing is implement to target the DSP FW
sequence expectations to enable path from source to sink pipe for
Playback/Capture.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Hardik T Shah <hardik.t.shah@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 15:30:15 +01:00
Jeeja KP f7590d4f15 ASoC: Intel: Skylake: Add module configuration helpers
To configure a module, driver needs to send input and output PCM
params for a module in DSP. The FE PCM params come from hw_params
ie from user, for a BE they also come from hw_params but from
BE-link fixups.
So based on PCM params required driver has to find a converter
module (src/updown/format) and then do the conversion and
calculate PCM params in these pipelines In this patch we add the
helper modules which allow driver to do these calculations.

Signed-off-by: Hardik T Shah <hardik.t.shah@intel.com>
Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 15:30:15 +01:00
Jeeja KP e4e2d2f452 ASoC: Intel: Skylake: Add pipe and modules handlers
SKL driver needs to instantiate pipelines and modules in the DSP.
The topology in the DSP is modelled as DAPM graph with a PGA
representing a module instance and mixer representing a pipeline
for a group of modules along with the mixer itself.

Here we start adding building block for handling these. We add
resource checks (memory/compute) for pipelines, find the modules
in a pipeline, init modules in a pipe and lastly bind/unbind
modules in a pipe These will be used by pipe event handlers in
subsequent patches

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 15:30:15 +01:00
Adam Thomson 6e7c444318 ASoC: da7213: Add support to handle mclk data provided to driver
Driver now can make use of mclk data, if provided, to set, enable
and disable the clock source. As part of this, the choice to
enable clock squaring is dealt with as part of dai_sysclk() call
rather than as platform data.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 15:11:34 +01:00
Adam Thomson e90996a3ea ASoC: da7213: Add DT support to codec driver
This patch adds support for DT bindings in the codec driver.
As part of this support, the mclk data can now be provided and
used to control the mclk during codec operation.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 15:11:34 +01:00
Geert Uytterhoeven dcc448e619 ASoC: rsnd: Remove obsolete platform data support
Since commit 3d7608e4c1 ("ARM: shmobile: bockw: remove legacy
board file and config"), Renesas R-Car SoCs are only supported in
generic DT-only ARM multi-platform builds.  The driver doesn't need to
use platform data anymore, hence remove platform data configuration.

Move <sound/rcar_snd.h> to sound/soc/sh/rcar/, as it's no longer needed
by platform code.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 12:19:51 +01:00
Adam Thomson ba856fbd60 ASoC: da7219: Improve error checking of mclk enable/disable
Should only try to enable/disable the provided mclk, during bias
level changes, if it's not NULL. Also return value of
clk_prepare_enable() should be checked and dealt with accordingly.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 12:15:22 +01:00
Adam Thomson b7ebd78d1d ASoC: da7219: Use of_match_ptr() when assigning match table
Use of_match_ptr() to handle non-DT kernel scenario where match
table should be NULL.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 12:15:22 +01:00
Maxime Ripard c570b82c5e ASoC: sun4i-codec: Remove the routing property
Most of the boards have their headphone jack directly connected to the
matching pins of the SoCs. Since most of the time we will have the same
routing path, it makes no sense to put that in the DTS, since it will only
be some useless duplication there.

It also fixes the following warning messages that were seen so far, on
boards where we were using the bindings in the documentation example.

sun4i-codec 1c22c00.codec: ASoC: no sink widget found for Headphone Jack
sun4i-codec 1c22c00.codec: ASoC: Failed to add route HP Left -> direct -> Headphone Jack
sun4i-codec 1c22c00.codec: ASoC: no sink widget found for Headphone Jack
sun4i-codec 1c22c00.codec: ASoC: Failed to add route HP Right -> direct -> Headphone Jack

Reported-by: Priit Laes <plaes@plaes.org>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 12:13:42 +01:00
kbuild test robot cc91ef0fd4 ASoC: nau8825: fix platform_no_drv_owner.cocci warnings
sound/soc/codecs/nau8825.c:1096:3-8: No need to set .owner here. The core will do it.

 Remove .owner field if calls are used which set it automatically

Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci

CC: Anatol Pomozov <anatol.pomozov@gmail.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 11:36:39 +01:00
Anatol Pomozov 34ca27f34f ASoC: nau8825: Add driver for headset chip Nuvoton 8825
Sponsored-by: Google Chromium project
Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 11:36:38 +01:00
Andy Shevchenko b5e5a4549c ASoC: Intel: use dw_dmac autoconfiguration
Instead of hardconding a platform data for dw_dmac let's use it's own
autoconfiguration feature. Thus, remove hardcoded values.

Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Cc: Mark Brown <broonie@kernel.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 11:24:49 +01:00
Axel Lin dc6d84c69c ASoC: rt286: Fix run time error while modifying const data
Make a copy of memory for index_cache rather than directly use the
rt286_index_def to avoid run time error.

Fixes: c418a84a8c ("ASoC: Constify reg_default tables")
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 10:46:49 +01:00
Axel Lin d46183efe3 ASoC: ad193x-spi: Fixup ad193x_spi_id table
AD1939 is missed from the table, so add it.
AD1936 and AD1937 are controlled by I2C interface, so remove them.

Fixes: e5224f58e3 ("ASoC: ad193x: add support to ad1934")
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-07 10:42:54 +01:00
Andreas Dannenberg e2600460bc ASoC: tas2552: fix dBscale-min declaration
The minimum volume level for the TAS2552 (control register value 0x00)
is -7dB however the driver declares it as -0.07dB.

Running amixer before the patch reports:
dBscale-min=-0.07dB,step=1.00dB,mute=0

Running amixer with the patch applied reports:
dBscale-min=-7.00dB,step=1.00dB,mute=0

Signed-off-by: Andreas Dannenberg <dannenberg@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-10-06 11:53:46 +01:00
Sjoerd Simons 698d0b59f3 ASoC: rockchip: namespace rockchip i2s module name
Change the rockchip i2s object name (and thus module name) from the
rather generic snd-soc-i2s to the more specific snd-soc-rockchip-i2s

Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-06 11:52:47 +01:00
Cyrille Pitchen e5224f58e3 ASoC: ad193x: add support to ad1934
The AD1934 codec has no ADC feature. Hence it register mapping is slightly
different from the register mapping of other members of the AD193x family.

Some ASoC controls and widgets are related to the DAC feature so are not
relevant in the case of an AD1934 codec.

Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 17:42:49 +01:00
Zidan Wang c64c60763b ASoC: fsl_esai: Add driver suspend and resume to support MEGA Fast
For i.MX6 SoloX, there is a mode of the SoC to shutdown all power source of
modules during system suspend and resume procedure. Thus, ESAI needs to save
all the values of registers before the system suspend and restore them after
the system resume.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 17:26:19 +01:00
Zidan Wang 05cf237972 ASoC: fsl_ssi: Add driver suspend and resume to support MEGA Fast
For i.MX6 SoloX, there is a mode of the SoC to shutdown all power
source of modules during system suspend and resume procedure. Thus,
SSI needs to save all the values of registers before the system
suspend and restore them after the system resume.

The register SFCSR is volatile, but some bits in it need to be
recovered after suspend/resume.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 17:26:18 +01:00
Zidan Wang f9f4fa61aa ASoC: fsl_spdif: Add driver suspend and resume to support MEGA Fast
For i.MX6 SoloX, there is a mode of the SoC to shutdown all power source of
modules during system suspend and resume procedure. Thus, SPDIF needs to save
all the values of registers before the system suspend and restore them after
the system resume.

The SRPC register should be volatile, LOCK bit is set by the hardware.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 17:26:17 +01:00
Zidan Wang 1fde5e83a1 ASoC: fsl_sai: Add driver suspend and resume to support MEGA Fast
For i.MX6 SoloX, there is a mode of the SoC to shutdown all power source of
modules during system suspend and resume procedure. Thus, SAI needs to save
all the values of registers before the system suspend and restore them after
the system resume.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 17:26:16 +01:00
Zidan Wang 43ac946922 ASoC: imx-spdif: add snd_soc_pm_ops for spdif machine driver
Add snd_soc_pm_ops in machine driver to make the trigger suspend/resume
be called in suspend/resume.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 17:25:45 +01:00
Maruthi Srinivas Bayyavarapu 1d957d862a ASoC: dwc: support dw i2s in slave mode
dw i2s controller can work in slave mode, codec being master.
dw i2s is made to support master/slave operation, by reading dwc
register.

Signed-off-by: Maruthi Bayyavarapu <maruthi.bayyavarapu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 16:31:43 +01:00
Adam Thomson 4e929134eb ASoC: da7219: Improve error handling for regulator supplies
Currently if bulk_enable() of supplies fails, the code still goes on
to try and put the device into active state, and set expected IO
voltage of the device. This doesn't really make sense so code now
returns on bulk_enable() failure, with an error message. Also,
to help with debug, failure to get supplies also provides an error
message.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 15:59:16 +01:00
Oder Chiou a2c026cfec ASoC: rt5645: Prevent the weird sound of the headphone while rebooting
The patch adds the codec reset setting in the shutdown function to prevent
the weird sound of the headphone happened by rebooting.

Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-05 15:27:16 +01:00
Viresh Kumar 621a5f7ad9 debugfs: Pass bool pointer to debugfs_create_bool()
Its a bit odd that debugfs_create_bool() takes 'u32 *' as an argument,
when all it needs is a boolean pointer.

It would be better to update this API to make it accept 'bool *'
instead, as that will make it more consistent and often more convenient.
Over that bool takes just a byte.

That required updates to all user sites as well, in the same commit
updating the API. regmap core was also using
debugfs_{read|write}_file_bool(), directly and variable types were
updated for that to be bool as well.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Acked-by: Mark Brown <broonie@kernel.org>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 11:36:07 +01:00
Ben Zhang fbe039bb08 ASoC: rt5645: Allow 4 channel recording on AIF1
The codec supports 4 channel recording with TDM on AIF1.
This patch modifies the DAI capability to allow it.

Signed-off-by: Ben Zhang <benzh@chromium.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-02 18:13:06 +01:00
Adam Thomson 6d817c0e9f ASoC: codecs: Add da7219 codec driver
This adds support for the DA7219 audio codec with built-in advanced
accessory detect features.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-02 18:11:27 +01:00
yitian 924eb47512 ASoC: dwc: fix dma stop transferring issue
Designware I2S uses tx empty and rx available signals as the DMA
handshaking signals. during music playing, if XRUN occurs,
i2s_stop() function will be executed and both tx and rx irq are
masked, when music continues to be played, i2s_start() is executed
but both tx and rx irq are not unmasked which cause I2S stop
sending DMA handshaking signal to DMA controller, and it finally
causes music playing will be stopped once XRUN occurs for the first
time.

[On list discussion suggests this may be partly a race condition on slow
systems -- broonie]

Signed-off-by: Yitian Bu <yitian.bu@tangramtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-02 18:05:51 +01:00
Vedang Patel 5b2688a59a ASoC: topology: ABI - Add PCM Support and bump ABI version to 4
The struct snd_soc_tplg_pcm_dai is renamed to snd_soc_tplg_pcm.
This struct will now be used to handle data related to PCMs
(FE DAI & DAI links). It's not for BE, because BE DAI mappings will be
provided by ACPI/FDT data.

Remove the unused struct snd_soc_tplg_pcm_cfg_caps. We are using
snd_soc_tplg_stream and snd_soc_stream_caps instead.

Bump ABI version to 4.

Signed-off-by: Vedang Patel <vedang.patel@intel.com>
Signed-off-by: Mengdong Lin <mengdong.lin@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-02 17:59:48 +01:00
Richard Fitzgerald 6ebbce0a6e ASoC: wm8998: Initial WM8998 codec driver
Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-02 17:51:34 +01:00
Richard Fitzgerald 50e6168f27 ASoC: arizona: add defines for single-input gain control
Adds convenience defines for declaring a gain control that
has an input mux. These blocks are functionally equivalent to
the existing mixer blocks but can only have a single input
active at once.

Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
Acked-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-02 17:51:33 +01:00
Yitian Bu 4873867e5f ASoC: dwc: correct irq clear method
from Designware I2S datasheet, tx/rx XRUN irq is cleared by
reading register TOR/ROR, rather than by writing into them.

Signed-off-by: Yitian Bu <yitian.bu@tangramtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-10-02 11:44:04 +01:00
Rick Mann 2d1180e369 ASoC: tlv320aic3x: Prevent writing reserved registers on tlv320aic3104 CODECs
The current code writes a set of registers that are reserved on the
tlc320aic3104. The change skips those registers for that IC.

Signed-off-by: Rick Mann <rmann@latencyzero.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-01 11:15:45 +01:00
Oder Chiou 8c1a9d6323 ASoC: rt5645: Correct the naming and setting of ADC Boost Volume Control
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-01 11:13:04 +01:00
Oder Chiou e29fd55d8d ASoC: rt5645: Add the control of ClassD modulator Speaker Gain Ratio
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-10-01 11:12:45 +01:00
Daniel Mack 58ceb57ec1 ASoC: pxa: pxa-pcm-lib: switch over to snd-soc-dmaengine-pcm
This patch removes the old PXA DMA API usage and switches over to
generic functions provided by snd-soc-dmaengine-pcm.

More cleanups may be done on top of this, and some function stubs can
now be removed completetly. However, the intention here was to keep
the transition as small as possible.

This was tested on the mioa701 pxa27x board.

Signed-off-by: Daniel Mack <zonque@gmail.com>
[trivial change from mmp-dma to pxa-dma]
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-30 23:21:16 +01:00
Mark Brown 5c0e869357 ASoC: Fixes for v4.3
A disappointingly large set of fixes, though none of them very big and
 very widely spread over many different drivers.  Nothing especially
 stands out, it's mostly all device specific and relatively minor.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQEcBAABAgAGBQJWBEMrAAoJECTWi3JdVIfQOqIH/jsO0wdDz683ZpUd0K3OQlss
 gia5/e0pS4IOaQY4ECZSydC/wf+fGs0ZHlLWXqSzJ33abCUUZlfL4f/3kQwhIrgD
 Tb4aFLQoTRglZIqsgEm91Mqpk9gFUxhhqRBhI77iw11SOG1uWdokkYISG0ljnR5p
 HFVxmqiSubvKdtydTOWR446Gxrk97c8HjzoBOXvQ87hKKyos7oJi4OcYD6HDVNr9
 hrPkHS/05anaLbehZr82jmL+yMDsQl7QMjk1ljRkuufDUB07HogM1FHb5zkecC9u
 eqDy5SOSJY4XFINDpxqt/5nqDaKgPcbEpfCH+ajfeY0e3d8rVVnPurrz/H4ElUM=
 =KbEn
 -----END PGP SIGNATURE-----

Merge tag 'asoc-fix-v4.3-rc2' into asoc-pxa

ASoC: Fixes for v4.3

A disappointingly large set of fixes, though none of them very big and
very widely spread over many different drivers.  Nothing especially
stands out, it's mostly all device specific and relatively minor.
2015-09-30 23:21:11 +01:00
Gianluca Renzi e256da84a0 ASoC: sgtl5000: fix wrong register MIC_BIAS_VOLTAGE setup on probe
Signed-off-by: Gianluca Renzi <gianlucarenzi@eurekelettronica.it>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-09-30 19:44:03 +01:00
Maxime Ripard debb972487 ASoC: sun4i-codec: Remove redundant SND_PCM_RATE_KNOT
The SND_PCM_RATE_KNOT covers all the rate settings, even though some that
we don't support, while we also list all the rate we support. Simply remove
it.

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-30 19:41:14 +01:00
Maxime Ripard 98a4b665bc ASoC: sun4i-codec: pass through clk_set_rate error
The current code, disregarding the clk_set_rate error code, was always
returning -EINVAL. Fix that and return the code in order to have more clue
about what's going on.

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-30 19:41:14 +01:00
Jiada Wang 57622aef86 ASoC: wm8962: balance pm_runtime_enable
pm_runtime_enable is called in probe to enable runtime PM
for wm8962 codec, but pm_runtime_disable isn't called in remove
callback, nor is called in error path if probe fails after runtime
PM is enabled, this causes unbalanced pm_runtime_enable.

This patch Adds pm_runtime_disable in remove callback and error path,
to balance pm_runtime_enable.

Signed-off-by: Jiada Wang <jiada_wang@mentor.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-30 19:10:58 +01:00
Benoît Thébaudeau b7b01d345b ASoC: imx-ssi: Fix DAI hardware signal inversions
SND_SOC_DAIFMT_{IB|NB}_{IF|NF} are defined as inverting or not BCLK or
FRM relatively to what is standard for the specified DAI hardware audio
format. Consequently, the absolute polarities of these signals cannot be
derived only from these settings as this driver did. The format has to
be taken into account too.

This fixes inverted left/right channels in I²S mode.

Signed-off-by: Benoît Thébaudeau <benoit@wsystem.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-29 17:28:33 +01:00
Gianluca Renzi fb97d75b03 ASoC: sgtl5000: fix error message output for MicBias voltage
Cc: Liam Girdwood <lgirdwood@gmail.com>
Cc: Takashi Iwai <tiwai@suse.com>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: alsa-devel@alsa-project.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Gianluca Renzi <gianlucarenzi@eurekelettronica.it>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-29 17:06:22 +01:00
Lars-Peter Clausen e74679b38c ASoC: db1200: Fix DAI link format for db1300 and db1550
Commit b4508d0f95 ("ASoC: db1200: Use static DAI format setup") switched
the db1200 driver over to using static DAI format setup instead of a
callback function. But the commit only added the dai_fmt field to one of
the three DAI links in the driver. This breaks audio on db1300 and db1550.

Add the two missing dai_fmt settings to fix the issue.

Fixes: b4508d0f95 ("ASoC: db1200: Use static DAI format setup")
Reported-by: Manuel Lauss <manuel.lauss@gmail.com>
Tested-by: Manuel Lauss <manuel.lauss@gmail.com>
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-09-25 09:31:09 -07:00
Axel Lin 0f7e177406 ASoC: rl6347a: Clean up unneeded inclusion of header files
Also move the include of sound/hda_verbs.h to rl6347a.h because it is used
in rl6347a.h.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-24 10:30:47 -07:00
Mark Brown 4922e7a1b7 Merge remote-tracking branch 'asoc/topic/ux500' into asoc-next 2015-09-23 11:01:30 -07:00
Mark Brown 727e53a12f Merge remote-tracking branches 'asoc/topic/sh', 'asoc/topic/simple', 'asoc/topic/spear', 'asoc/topic/sunxi' and 'asoc/topic/tlv320aic3x' into asoc-next 2015-09-23 11:01:27 -07:00
Mark Brown e32efed3ea Merge remote-tracking branches 'asoc/topic/pxa', 'asoc/topic/qcom', 'asoc/topic/rcar' and 'asoc/topic/rockchip' into asoc-next 2015-09-23 11:01:25 -07:00
Mark Brown 9abbe73e7d Merge remote-tracking branches 'asoc/topic/jz4740', 'asoc/topic/kirkwood', 'asoc/topic/mtk', 'asoc/topic/multi' and 'asoc/topic/mxs' into asoc-next 2015-09-23 11:01:22 -07:00
Mark Brown f7b93159ab Merge remote-tracking branches 'asoc/topic/blackfin', 'asoc/topic/davinci', 'asoc/topic/fsl', 'asoc/topic/hdmi' and 'asoc/topic/intel' into asoc-next 2015-09-23 11:01:19 -07:00
Mark Brown 97e15d9a8b Merge remote-tracking branches 'asoc/topic/ak4613', 'asoc/topic/ak4642', 'asoc/topic/arizona', 'asoc/topic/atmel' and 'asoc/topic/au1x' into asoc-next 2015-09-23 11:01:16 -07:00
Mark Brown f950aa96d1 Merge remote-tracking branch 'asoc/topic/rt5645' into asoc-next 2015-09-23 11:01:15 -07:00
Mark Brown ed14ee0eea Merge remote-tracking branches 'asoc/fix/wm8960' and 'asoc/fix/wm8962' into asoc-linus 2015-09-23 11:01:12 -07:00
Mark Brown d86a2fe4dc Merge remote-tracking branches 'asoc/fix/mtk', 'asoc/fix/psc', 'asoc/fix/pxa', 'asoc/fix/spear', 'asoc/fix/sti' and 'asoc/fix/wm0010' into asoc-linus 2015-09-23 11:01:08 -07:00
Mark Brown 312e0bce7f Merge remote-tracking branches 'asoc/fix/davinci', 'asoc/fix/doc', 'asoc/fix/fsl-card', 'asoc/fix/fsl-ssi', 'asoc/fix/intel' and 'asoc/fix/maintainers' into asoc-linus 2015-09-23 11:01:03 -07:00
Mark Brown fcffa0dbb6 Merge remote-tracking branch 'asoc/fix/rt5645' into asoc-linus 2015-09-23 11:01:02 -07:00
Mark Brown 5ee84ba8c7 Merge remote-tracking branch 'asoc/fix/dapm' into asoc-linus 2015-09-23 11:01:00 -07:00
Oder Chiou fce97b4d70 ASoC: rt5645: Prevent the pop sound in case of playback and the jack is plugging
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-23 10:59:13 -07:00
Oder Chiou 4f4794124e ASoC: rt5645: Increase the delay time to remove the pop sound
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-23 10:59:10 -07:00
Oder Chiou 21cb13e72b ASoC: rt5645: Use the type SOC_DAPM_SINGLE_AUTODISABLE to prevent the weird sound in runtime of power up
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-23 10:59:07 -07:00
Oder Chiou de3f8fdf73 ASoC: rt5645: Remove the repeated definitions
Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-23 10:57:52 -07:00
Robert Jarzmik 8811191fdf ASoC: pxa: pxa2xx-ac97: fix dma requestor lines
PCM receive and transmit DMA requestor lines were reverted, breaking the
PCM playback interface for PXA platforms using the sound/soc/ variant
instead of the sound/arm variant.

The commit below shows the inversion in the requestor lines.

Fixes: d65a14587a ("ASoC: pxa: use snd_dmaengine_dai_dma_data")
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
2015-09-22 14:12:46 -07:00
John Lin 917536aeb8 ASoC: rt5645: Add jd_invert for Broadwell
Broadwell can not triger the IRQ falling and rising simultaneously,
so it can not detect jack-in and jack-out simultaneously.
We add a flag "jd_invert" to platform data. If this flag is set,
codec IRQ will be set to invert that forces IRQ as pulse when jack-in
and jack-out.

Signed-off-by: John Lin <john.lin@realtek.com>
Signed-off-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-22 09:46:33 -07:00
John Lin e9159e7577 ASoC: rt5645: Add dmi for Broadwell
Add DMI data for Buddy project.

Signed-off-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: John Lin <john.lin@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-22 09:46:32 -07:00
Mark Brown c44506997c Merge branch 'fix/rt5645' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-rt5645 2015-09-22 09:45:46 -07:00
Adam Thomson 5b64c173cd ASoC: fsl_ssi: Fix checking of dai format for AC97 mode
Current code incorrectly treats dai format for AC97 as bit mask
whereas it's actually an integer value. This causes DAI formats
other than AC97 (e.g. DSP_B) to trigger AC97 related code,
which is incorrect and breaks functionality. This patch fixes
the code to correctly compare values to determine AC97 or not.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Acked-by: Timur Tabi <timur@tabi.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 11:07:42 -07:00
Ricard Wanderlof cde79035c6 ASoC: Handle multiple codecs with split playback / capture
Add the capability to use multiple codecs on the same DAI linke where
one codec is used for playback and another one is used for capture.

Tested on a setup using an SSM2518 for playback and an ICS43432 I2S MEMS
microphone for capture.

No verification is made that the playback and capture codec setups are
compatible in terms of number of TDM slots (where applicable).

Signed-off-by: Ricard Wanderlof <ricardw@axis.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 10:58:04 -07:00
Jyri Sarha 9529138276 ASoC: hdmi: Remove obsolete dummy HDMI codec
The hdmi stub codec has not been used since refactoring of OMAP HDMI
audio support.

Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 10:44:39 -07:00
Jeeja KP 5b97c0f18a ASoC: Intel: Skylake: Remove unused CPU dais
We need to create CPU DAI for each endpoint instance. For this we
should have one DMIC DAI, one HDA DAI and SSP DAI.  Thus, DMIC23,
HDA-SPK/AMIC was not required so this patch removes them

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 09:27:52 -07:00
Sudip Mukherjee f072f91aa7 ASoC: wm0010: fix error path
Fix the error path so that we can free the allocated memory on the error
path instead of releasing them individually on each error.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 08:40:55 -07:00
Sudip Mukherjee 2ace47be5a ASoC: wm0010: fix memory leak
We have requested for the firmware but we have missed releasing it both
on success and on error path.
While checking the code it turned out that the requested firmware is not
even used. More over the same firmware is being loaded by
wm0010_stage2_load().

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 08:40:50 -07:00
Zidan Wang 8524bb0c7a ASoC: wm8960: correct the max register value of mic boost pga
the max register value of mic boost pga should be 3.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 07:51:09 -07:00
Zidan Wang ee92cfb030 ASoC: wm8962: remove 64k sample rate support
wm8962 can't support 64k sample rate. When playing a 64KHz wave file,
'Unsupported rate 64000Hz' will be prompted.

Signed-off-by: Zidan Wang <zidan.wang@freescale.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 07:50:23 -07:00
Axel Lin 9d70594760 ASoC: rockchip: Fix missing CLKDEV_LOOKUP dependency
Make SND_SOC_ROCKCHIP_MAX98090 and SND_SOC_ROCKCHIP_RT5645 depend on
CLKDEV_LOOKUP to fix below build warning:

warning: (SND_SOC_ROCKCHIP_MAX98090 && SND_SOC_ROCKCHIP_RT5645) selects
SND_SOC_ROCKCHIP_I2S which has unmet direct dependencies (SOUND && !M68K &&
!UML && SND && SND_SOC && CLKDEV_LOOKUP && SND_SOC_ROCKCHIP)

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 07:47:57 -07:00
Kuninori Morimoto e3a4d958d7 ASoC: ak4613: add Digital Playback Volume support
For L/ROUT1 to L/ROUT6

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-19 07:41:15 -07:00
Peter Ujfalusi ab1fffe3a7 ASoC: davinci-mcasp: Fix devm_kasprintf format string
The '\n' at the end of the format string is not needed. It adds an extra
line break when doing
cat /proc/interrupts

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-18 16:22:07 +01:00
Kuninori Morimoto b075706284 ASoC: add ak4613 support
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-17 12:33:08 +01:00
kbuild test robot 31f4f0c640 ASoC: sunxi: fix platform_no_drv_owner.cocci warnings
sound/soc/sunxi/sun4i-codec.c:708:3-8: No need to set .owner here. The core will do it.

 Remove .owner field if calls are used which set it automatically

Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci

CC: Emilio López <emilio@elopez.com.ar>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-17 11:38:03 +01:00
Jyri Sarha 14a998be08 ASoC: davinci-mcasp: Get rid of bclk_lrclk_ratio in private data
The slot_width is for essentially same thing. Instead of storing
bclk_lrclk_ratio, just store the slot_width. Comments has been updated
accordingly and some variable names changed to more descriptive.

Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-17 11:37:27 +01:00
Julia Lawall 8985729578 ASoC: qcom: change PTR_ERR argument
Apply PTR_ERR to the value that was recently assigned.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression x,y;
@@

if (IS_ERR(x) || ...) {
  ... when any
      when != IS_ERR(...)
(
   PTR_ERR(x)
|
*  PTR_ERR(y)
)
  ... when any
}
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-17 11:36:19 +01:00
Jyri Sarha 6c84e5917f ASoC: soc-core: Fix sparse warning in be32_to_cpup() call
Store return value of of_get_property() to a pointer of __be32 type as
device tree has big endian type. This fixes a sparse warning couple of
lines later when be32_to_cpup() is used to convert from big endian to
cpu endian.

The whole conversion is not really necessary, as we are only checking
if the value is zero or not, but I wanted to add it to remind in the
future that the data has to be converted before use. Compiler should
optimize the unnecessary operations away.

Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-17 11:36:05 +01:00
Charles Keepax ccaadda319 ASoC: wm5110: Add additional analogue input enable for early revs
Earlier revisions of the wm5110/8280 silicon require a slightly more
complex procedure to enable analogue inputs. This patch adds this into
the driver.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-17 11:35:02 +01:00
Charles Keepax 002b083b8d ASoC: arizona: Add utility function to check if an input is analog
We will occasionally require to take different action based on if an
input is analog or digital so add a helper function to return if an
input is analog.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 21:00:03 +01:00
Charles Keepax bee261b896 ASoC: arizona: Add default cases for event switches
Since the addition of the WILL_PMU / WILL_PMD several of the switches in
arizona.c no longer cover all cases or have a default case. Whilst this
isn't causing any problems in the interests of robustness add default
cases.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 21:00:03 +01:00
Robert Jarzmik 3c8f7710c1 ASoC: fix broken pxa SoC support
The previous fix of pxa library support, which was introduced to fix the
library dependency, broke the previous SoC behavior, where a machine
code binding pxa2xx-ac97 with a coded relied on :
 - sound/soc/pxa/pxa2xx-ac97.c
 - sound/soc/codecs/XXX.c

For example, the mioa701_wm9713.c machine code is currently broken. The
"select ARM" statement wrongly selects the soc/arm/pxa2xx-ac97 for
compilation, as per an unfortunate fate SND_PXA2XX_AC97 is both declared
in sound/arm/Kconfig and sound/soc/pxa/Kconfig.

Fix this by ensuring that SND_PXA2XX_SOC correctly triggers the correct
pxa2xx-ac97 compilation.

Fixes: 846172dfe3 ("ASoC: fix SND_PXA2XX_LIB Kconfig warning")
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 20:58:27 +01:00
Kuninori Morimoto 462c30bc8b ASoC: rsnd: fixup clkout_name[] index error for single AUDIO_CLKOUT SoC
2a46db4a3("ASoC: rsnd: add AUDIO_CLKOUT support") added AUDIO_CLKOUT
support for ADG. But single AUDIO_CLKOUT needs clkout_name[CLKOUT],
not clkout_name[i]. Kernel will have NULL pointer access without this
patch.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 20:40:39 +01:00
Kuninori Morimoto 544637bf3f ASoC: ak4642: exchange macro name to avoid redefinition
71a0138ab("ASoC: ak4642: enable to use MCKO as fixed rate output
pin on DT") added new FS() macro, but x86 already has it in
arch/x86/include/uapi/asm/ptrace-abi.h
This patch exchange FS() to FSs() to avoid redefinition warning

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 20:40:27 +01:00
Kuninori Morimoto e2f8445176 ASoC: rsnd: SND_SOC_RCAR depends on COMMON_CLK
2a46db4a3("ASoC: rsnd: add AUDIO_CLKOUT support") uses
of_clk_add_provider() which is requesting struct clk_onecell_data.
But it is COMMON_CLK feature. SND_SOC_RCAR depends on COMMON_CLK

This patch also solved compile error of 7486d80f7("ASoC: rsnd: remove
unneeded sh_clk header")

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 20:40:02 +01:00
Emilio López 45fb6b6f2a ASoC: sunxi: add support for the on-chip codec on early Allwinner SoCs
The sun4i, sun5i and sun7i SoC families have a built-in codec, capable
of both audio capture and playback.

While this is called a codec by Allwinner, it really is an in-SoC
combination of a codec and a DAI, with its own DAC/ADC and amplifiers
in a single memory-mapped controller.

The capture part has been left out for now, and will be added eventually.

Signed-off-by: Emilio López <emilio@elopez.com.ar>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 20:18:45 +01:00
Sudip Mukherjee 2fc171e69e ASoC: Intel: remove unused function
The function get_current_pipe_id() was not being used.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
2015-09-16 18:30:47 +01:00