Commit graph

2140 commits

Author SHA1 Message Date
Leon Romanovsky
9215aa4d96 ASoC: Rename ALC5632 MICBIAS to common name convention.
Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-13 14:27:19 +08:00
Mark Brown
cae59c7b21 ASoC: Remove WM8994 register cache
Now that the mfd is using the register map cache there's no need for the
CODEC driver to do any register cache management or any funny dances to
interact with the other drivers using the device so just remove the cache
initialisation and volatility information.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-13 00:20:11 +08:00
Mark Brown
d9a7666ff3 ASoC: Remove ASoC-specific WM8994 I/O code
Just go directly to the regmap API, saving code and making integration
that bit more direct.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-13 00:20:06 +08:00
Mark Brown
68556ca1e0 Merge branch 'mfd/wm8994' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/misc into for-3.3 2011-12-13 00:19:20 +08:00
Mark Brown
4de45284d3 mfd: Define some additional wm8994 registers
Add a bunch of definitions for wm8994 registers that are not currently
used by software.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
2011-12-13 00:10:06 +08:00
Mark Brown
0a105ddb35 Merge branch 'for-3.2' into for-3.3 2011-12-12 12:59:06 +08:00
Jonathan Neuschäfer
62e4a13e60 ASoC: WM8958: correctly show firmware magic on mismatch
Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-12 12:44:02 +08:00
Mark Brown
f04b8d6ece Merge branch 'for-3.2' into for-3.3 2011-12-11 03:01:33 +08:00
Mark Brown
37d5993c5c ASoC: Fix WM8996 24.576MHz clock operation
Record the clock after the divider as that is what all SYSCLK users see.
Without this the other clock configuration in the device comes out at
half rate.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2011-12-11 03:01:09 +08:00
Mark Brown
3025ae45d6 ASoC: Convert wm8770 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-09 20:36:59 +08:00
Axel Lin
7fcadfd176 ASoC: Fix comments for disabling amplifier and PGA
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-09 20:28:28 +08:00
Mark Brown
46ce904f7d ASoC: Convert WM8900 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-09 20:28:18 +08:00
Mark Brown
5a37452421 ASoC: Convert WM8804 to table based control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-09 20:28:17 +08:00
Mark Brown
bc9c040d36 ASoC: Make WM8770 SPI usage unconditional
The device only supports SPI.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-09 20:28:16 +08:00
Mark Brown
bf97ca9a0d ASoC: Convert WM8776 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-09 20:28:15 +08:00
Axel Lin
16b24881a0 ASoC: wm8960: Use snd_soc_update_bits for read-modify-write
Use snd_soc_update_bits for read-modify-write register access instead of
open-coding it using snd_soc_read and snd_soc_write

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-08 11:37:31 +08:00
Mark Brown
4105ab846c ASoC: Rely on core enabling the wm8994 with runtime PM
No need to do this in the driver now.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-08 09:22:48 +08:00
Stephen Warren
f18b4e2ee9 ASoC: WM8903: Add of_match_table
This allows the device to be matched against the device tree using the
compatible flag directly, as is standard, rather than falling back to
matching .id_table against the non-vendor portion of the first compatible
property value.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-07 21:51:04 +08:00
Mark Brown
21abbb024f Merge branch 'for-3.2' into for-3.3 2011-12-06 11:01:38 +00:00
Axel Lin
f8f626f537 ASoC: Fix build dependency for SND_SOC_JZ4740_CODEC
Currently SND_SOC_JZ4740_CODEC depends on SOC_JZ4740 but SOC_JZ4740 is not
defined in any Kconfig. Thus the codec driver will not be built when select
"Build all ASoC CODEC drivers".
(Unless it is selected by SND_JZ4740_SOC_QI_LB60).
Remove the dependency with SOC_JZ4740, then this code driver can be built when
select "Build all ASoC CODEC drivers".

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 11:01:20 +00:00
Axel Lin
68bfcafaae ASoC: Include linux/io.h for jz4740 codec
Include linux/io.h to fix below build errors:

  CC      sound/soc/codecs/jz4740.o
sound/soc/codecs/jz4740.c: In function 'jz4740_codec_read':
sound/soc/codecs/jz4740.c:82: error: implicit declaration of function 'readl'
sound/soc/codecs/jz4740.c: In function 'jz4740_codec_write':
sound/soc/codecs/jz4740.c:92: error: implicit declaration of function 'writel'
sound/soc/codecs/jz4740.c: In function 'jz4740_codec_probe':
sound/soc/codecs/jz4740.c:373: error: implicit declaration of function 'ioremap'
sound/soc/codecs/jz4740.c:373: warning: assignment makes pointer from integer without a cast
sound/soc/codecs/jz4740.c:393: error: implicit declaration of function 'iounmap'
make[3]: *** [sound/soc/codecs/jz4740.o] Error 1
make[2]: *** [sound/soc/codecs] Error 2
make[1]: *** [sound/soc] Error 2
make: *** [sound] Error 2

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 11:01:10 +00:00
Mark Brown
6664ee115b ASoC: Don't fail if we can't read the IRQ type in WM8903
If we fail to read the IRQ type from the interrupt controller don't
fail, just assume a value and solider on - we may fail later when we try
to request the IRQ but it's possible we'll succeed.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 10:30:24 +00:00
Stephen Warren
5d680b3a84 ASoC: WM8903: Add device tree binding
Document the device tree binding for the WM8903 codec, and modify the
driver to extract platform data from the device tree, if present.

Based on work by John Bonesio, but significantly reworked since then.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 10:29:22 +00:00
Stephen Warren
9d35f3e100 ASoC: WM8903: Get default irq_active_low from IRQ controller
If the WM8903 is hooked up to an interrupt, set the irq_active_low flag
in the default platform data based on the IRQ's IRQ_TYPE. Map IRQ_TYPE_NONE
(a lack of explicit configuration/restriction) to irq_active_low = false;
the previous default.

This code is mainly added to support device tree interrupt bindings,
although will work perfectly well in a non device tree system too.

Any interrupt controller that supports only a single IRQ_TYPE could
set each IRQ's type based on that restriction. This applies equally
with and without device tree. To cater for interrupt controllers
that don't do this, for which irqd_get_trigger_type() will return
IRQ_TYPE_NONE, the platform data irq_active_low field may be used
in systems that don't use device tree.

With device tree, every IRQ must have some IRQ_TYPE set.

Controllers that support DT and multiple IRQ_TYPEs must define the
interrupts property (as used in interrupt source nodes) such that it
defines the IRQ_TYPE to use. When the core DT setup code initializes
wm8903->irq, the interrupts property will be parsed, and as a side-
effect, set the IRQ's IRQ_TYPE for the WM8903 probe() function to read.

Controllers that support DT and a single IRQ_TYPE could arrange to
set the IRQ_TYPE somehow during their initialization, or hard-code
it during the processing of the child interrupts property.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 10:29:22 +00:00
Stephen Warren
db81778409 ASoC: WM8903: Remove conditionals checking pdata != NULL
The pdata pointer is now always valid. Remove any conditions that check
its validity.

This patch is mostly just removing an indentation level. One variable had
to be moved due to the removal of a scope, and one comment was split into
two. Viewing the patch with git show/diff -b will show that it's actually
very small.

Note that WM8903_MIC_BIAS_CONTROL_0 is now written unconditionally,
whereas it used to be written only if pdata was supplied. Since
defpdata.micdet_cfg = 0, this unconditional write simply echos the HW
defaults in the case where pdata is not supplied.

Based on work by John Bonesio, but significantly reworked since then.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 10:29:22 +00:00
Stephen Warren
a0f203d384 ASoC: WM8903: Fix platform data gpio_cfg confusion
wm8903_platform_data.gpio_cfg[] was intended to be interpreted as follows:
0:       Don't touch this GPIO's configuration register
1..7fff: Write that value to the GPIO's configuration register
8000:    Write zero to the GPIO's configuration register
other:   Undefined (invalid)

The rationale is that platform data is usually global data, and a value of
zero means that the field wasn't explicitly set to anything (e.g. because
the field was new to the pdata type, and existing users weren't update to
initialize it) and hence the value zero should be ignored. 0x8000 is an
explicit way to get 0 in the register.

The code worked this way until commit 7cfe561 "ASoC: wm8903: Expose GPIOs
through gpiolib", where the behaviour was changed due to my lack of
awareness of the above rationale.

This patch reverts to the intended behaviour, and updates all in-tree users
to use the correct scheme. This also makes WM8903 consistent with other
devices that use a similar scheme.

WM8903_GPIO_NO_CONFIG is also renamed to WM8903_GPIO_CONFIG_ZERO so that
its name accurately reflects its purpose.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Cc: Olof Johansson <olof@lixom.net>
Cc: Colin Cross <ccross@android.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-06 10:29:22 +00:00
Axel Lin
f031efe940 ASoC: Fix reg_cache_size for stac9766
reg_cache_size is supposed to be the number of elements in the register cache,
not the size in bytes.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-05 13:30:39 +00:00
Axel Lin
68020db8ac ASoC: uda1380: Convert to gpio_request_one()
Using gpio_request_one can make the error handling simpler.

Also remove a redundant "Failed to issue reset" error message.
We already show the error message in uda1380_reset() error path.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-05 13:24:49 +00:00
Mark Brown
b71951d63d Merge branch 'for-3.2' into for-3.3 2011-12-04 23:47:39 +00:00
Axel Lin
ef1497707c ASoC: uda1380: Return proper error in uda1380_modinit failure path
Return proper error for uda1380_modinit if i2c_add_driver() fails.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-04 23:47:15 +00:00
Mark Brown
59792aa91f ASoC: Sort WM9090 in with the CODEC drivers
The driver itself has been a regular CODEC driver for a while now.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:22 +00:00
Mark Brown
4911ccdb9d ASoC: Convert WM2000 into a standard CODEC driver
We've been able to handle external amps for a while now.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:21 +00:00
Mark Brown
8aa1fe81c5 ASoC: Convert wm2000 to use regmap API
The driver wasn't even using the ASoC common code.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:20 +00:00
Mark Brown
012d12db0c ASoC: Remove unused struct wm2000_setup_data
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:19 +00:00
Mark Brown
e41d5a3b7a ASoC: Convert WM8728 to table based control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:18 +00:00
Mark Brown
2f5374d8cf ASoC: Convert WM8711 to table based control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:17 +00:00
Mark Brown
0f185e3f8b ASoC: Convert WM8750 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:16 +00:00
Mark Brown
0e62780f5f ASoC: Convert WM8741 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:14 +00:00
Mark Brown
f235c649c1 ASoC: Convert WM8580 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:13 +00:00
Mark Brown
b6709f3bbd ASoC: Convert WM8510 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:12 +00:00
Mark Brown
b4505ab141 ASoC: Convert WM8400 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:11 +00:00
Mark Brown
e6c94e9f6d ASoC: Convert WM8350 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:10 +00:00
Mark Brown
455b91bfe8 ASoC: Convert WM9090 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:09 +00:00
Mark Brown
2edaed82b7 ASoC: Convert WM8750 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:08 +00:00
Mark Brown
5aefb306e3 ASoC: Convert WM8741 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:07 +00:00
Mark Brown
b903c0ed2e ASoC: Convert WM8400 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:06 +00:00
Mark Brown
0d1fe0d452 ASoC: Convert WM8350 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:05 +00:00
Mark Brown
b03e96e4d6 ASoC: Convert WM2000 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:04 +00:00
Mark Brown
6cd4eb9592 ASoC: Remove unused AUDIO_NAME define from WM8960
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:03 +00:00
Mark Brown
3a0d077f3d ASoC: Remove I2C ifdefs from WM8960
The driver only supports I2C as the control interface.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:02 +00:00
Mark Brown
091edccf7f ASoC: Remove unused -codec from Wolfson device driver names
Devices that aren't MFDs don't need to distinguish this.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 21:35:01 +00:00
Stephen Warren
c0eb27cf84 ASoC: WM8903: Create default platform data structure
When no platform data is supplied, point pdata at a default platform
structure. This enables two future changes:

a) Defines the default platform data values in a single place.
b) There is always a valid pdata pointer, so some conditional code can
   be simplified by a later patch.

Based on work by John Bonesio, but significantly reworked since then.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-03 11:19:08 +00:00
Mark Brown
7d46a528c6 ASoC: Move initial WM8903 identification and reset to I2C probe
Get control of the device earlier and avoid trying to do an ASoC probe
on a card that won't work.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 11:00:10 +00:00
Mark Brown
ee244ce4ea ASoC: Convert WM8903 to direct regmap API usage
Converting to an rbtree cache as regcache doesn't have a flat cache.
Since the top of the register map is fairly sparse this should be an
overall win.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 11:00:07 +00:00
Mark Brown
82ae55dbcc ASoC: Don't resync WM8903 register cache on reset
We only do this on initial power on so it's at best a waste of time as
the core will have already defaulted to the same values.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 10:59:45 +00:00
Mark Brown
45e967553f ASoC: Use a normal cache sync for WM8903
The driver used to use a complicated method to sync the register cache
after having brought the bias level up to standby in resume due to the
use of the write sequencer to manage the initial power up. Now that we
don't use the write sequencer there is no need for this and we can just
use snd_soc_cache_sync() directly.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 10:59:45 +00:00
Mark Brown
88a1b12b9c ASoC: WM8903 only supports I2C so don't ifdef it
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 10:59:44 +00:00
Mark Brown
f4a10837c9 ASoC: Use table based control init for WM8903
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 10:59:43 +00:00
Mark Brown
2950cd2208 ASoC: Convert WM8903 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2011-12-03 10:59:32 +00:00
Mark Brown
33e57f221a Merge branch 'for-3.2' into for-3.3 2011-12-02 17:44:55 +00:00
Mark Brown
87b86ade8b ASoC: Mark WM8994 ADC muxes as virtual
Since they don't actually have power bits but do have events associated
with them it's important that we bootstrap their state properly which
making them virtual does.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-02 17:44:37 +00:00
Mark Brown
91e20854e5 ASoC: Convert WM8994 MICBIASes to supply widgets
There are some in tree systems using the driver but none use the MICBIAS
widgets.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-02 17:37:49 +00:00
Mark Brown
3631e8d43e ASoC: Add missing err label
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-02 10:55:12 +00:00
Stephen Warren
6f526f0a86 ASoC: WM8903: Disallow all invalid gpio_cfg pdata values
The GPIO registers are 15 bits wide. Hence values, higher than 0x7fff are
not legal GPIO register values. Modify the pdata.gpio_cfg handling code
to reject all illegal values, not just WM8903_GPIO_NO_CONFIG (0x8000). This
will allow the later use of 0xffffffff as an invalid value in future device
tree bindings, meaning "don't touch this GPIO's configuration".

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-02 10:35:25 +00:00
Lars-Peter Clausen
84b315ee89 ASoC: Drop unused state parameter from CODEC suspend callback
The existence of this parameter is purely historical. None of the CODEC drivers
uses it and we always pass in the same value anyway, so it should be safe to
remove it.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-02 10:32:03 +00:00
Mark Brown
36c6b54cb0 ASoC: Make WM8962 beep a signal generator
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
2011-12-02 10:27:01 +00:00
Mark Brown
dea8e23741 ASoC: Make WM5100 tone generator widgets signal generators
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
2011-12-02 10:26:22 +00:00
Mark Brown
7270cebef2 ASoC: Convert WM8994 to devm_kzalloc()
Still have a manual free in there for some realloc()ed memory as there's
no devm version of that.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:22:03 +00:00
Mark Brown
cd1707a99a ASoC: Add platform data for WM8958/WM1811 microphone detection rates
Allow systems to override the default microphone detection rates using
platform data in case the settings are not suitable (eg, due to an
unusually noisy jack).

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:22:01 +00:00
Mark Brown
52ac7ab247 ASoC: Ensure we reconfigure WM8958 microphone detection on rate changes
We don't need to rerun DAPM if the clock source is the same but we do
need to adjust the microphone detection rate in case we are moving from
an audio to a non-audio rate.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:21:58 +00:00
Mark Brown
af6b6fe41c ASoC: Implement support for WM1811A jack detection
The WM1811A features an advanced low power accessory detection subsystem
which allows the device to be maintained in a very low power state while
the system is idle without sacrificing any accessory detection features.

Implement software support for this, automatically managing the power
configuration of the device depending on the detected accessory.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:21:55 +00:00
Mark Brown
157a75e664 ASoC: Rename WM8994 detecting flag to mic_detecting
More specific and avoids confusion with a following change.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:21:53 +00:00
Mark Brown
4585790d1c ASoC: Allow more WM8958/WM1811 button levels with default handler
The WM8958 and WM1811 support detecting a range of buttons. Allow the
user to provide platform data enabling more of these levels without
having to write a custom detection handler.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:21:51 +00:00
Mark Brown
604533de0f ASoC: Tune down active mode detection rate for WM8958 mic detection
Saves a little power.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:21:48 +00:00
Mark Brown
2a8a856d42 ASoC: Don't use control_data to get struct wm8994
This will support refactoring to make use of the regmap API more directly
in the core.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-12-01 14:21:41 +00:00
Mark Brown
a1691343a3 ASoC: Provide debug log of accessory status on WM8958
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-30 20:50:28 +00:00
Mark Brown
b00adf76a6 ASoC: Enhance default WM8958 microphone detection
Actively manage the detection rate for microphones with WM8958, providing
improved power consumption and maximising the benefit from the hardware
debounce.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 20:22:00 +00:00
Mark Brown
500fa30ed5 ASoC: Put WM8958 and WM1811 MICBIAS into bypass mode when no audio
When we don't have any active audio we can put the microphone biases into
bypass mode to save power at the expense of performance.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 19:59:18 +00:00
Mark Brown
4cdf5e49ce ASoC: Ensure SYSCLK is enabled for WM8958 accessory detection
Ensure SYSCLK is enabled while running accessory detection on WM8958.
It is always required so there is no sense in requiring machine drivers
to individually do this.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 17:23:29 +00:00
Lars-Peter Clausen
38fd54ee38 ASoC: SigmaDSP: Add regmap support
Add support for loading the SigmaDSP firmware using regmap. This allows us
to transparently use SPI or I2C as the transport protocol on devices which
support them.

For now we keep the old I2C support since we have one user of this which is not
straight forward to convert to regmap, due to variable length registers.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 12:01:23 +00:00
Lars-Peter Clausen
a4c1d7e667 ASoC: SigmaDSP: Move private structs and functions to C file
Move the structs and functions only used by SigmaDSP firmware loader itself
from the header to the C file.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 12:01:20 +00:00
Lars-Peter Clausen
48afc5272e ASoC: SigmaDSP: Provide diagnostic error messages
Provide some error messages when loading the firmware fails, so it is possible
to diagnose the reason for the failure.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 12:01:14 +00:00
Lars-Peter Clausen
40216ce7aa ASoC: Move SigmaDSP firmware loader to ASoC
It has been pointed out previously, that the firmware subsystem is not the right
place for the SigmaDSP firmware loader. Furthermore the SigmaDSP is currently
only used in audio products and we are aiming for better integration into the
ASoC framework in the future, with support for ALSA controls for firmware
parameters and support dynamic power management as well. So the natural choice
for the SigmaDSP firmware loader is the ASoC subsystem.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 12:01:10 +00:00
Axel Lin
7b282cbbf3 ASoC: cs42l73: Fix clear wrong bits in cs42l73_set_dai_fmt
What we want is to clear BIT[5:4](PCM_MODE_MASK) and BIT[3](PCM_BIT_ORDER) bits,
but current code clears BIT[2:0].

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-29 11:50:50 +00:00
Mark Brown
fd8f2e496f Merge branch 'for-3.2' into for-3.3 2011-11-28 23:18:39 +00:00
Mark Brown
fc8e6e8668 ASoC: Supply dcs_codes for newer WM1811 revisions
Based on initial data.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 23:18:38 +00:00
Mark Brown
49b72776f3 Merge branch 'for-3.2' into for-3.3 2011-11-28 22:13:14 +00:00
Brian Austin
cc0b401ad8 ASoC: Convert CS42L73 to devm_kzalloc()
Signed-off-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 22:12:25 +00:00
Mark Brown
fc07ecd851 ASoC: Error out if we can't generate a LRCLK at all for WM8994
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 22:10:05 +00:00
Lars-Peter Clausen
34cbe16833 ASoC: ad193x: Convert to direct regmap API usage
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:52 +00:00
Lars-Peter Clausen
b82ca578fd ASoC: ad193x: Use snd_soc_update_bits where appropriate
We can reduce the code size here a bit by using snd_soc_update_bits instead of
open-coding the read-modify-write cycle. The conversion done in this patch is
not completely straightforward and some minor code restructuring has been
incorporated to further reduce the code size.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:52 +00:00
Lars-Peter Clausen
0718fd2777 ASoC: ad193x: Add sysclk DAPM supply
Add a DAPM supply widget for the internal sysclk, so it can be disabled
automatically when not needed.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:51 +00:00
Lars-Peter Clausen
b21990b47d ASoC: ad193x: Remove non-functional DAPM route controls
DAPM route controls only take effect on paths where the sink is a mixer or a
mux, furthermore the control must be a control assigned to the mixer or mux.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:47 +00:00
Lars-Peter Clausen
c4e7a4a276 ASoC: ad193x: Make enum items const char * const
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:46 +00:00
Lars-Peter Clausen
591c034a32 ASoC: ad193x: Provide dB ranges for the volume controls
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:41 +00:00
Lars-Peter Clausen
b90d4183f7 ASoC: ad193x: Use table based DAPM and controls setup
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 18:57:37 +00:00
Mark Brown
5032dc3429 ASoC: Convert WM8903 MICBIAS to a supply widget
Also rename it to MICBIAS to reflect the pin name and help any out of tree
users notice the change.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
2011-11-28 17:02:07 +00:00
Mark Brown
5bbcc3c0d0 ASoC: Convert CODEC drivers to module_platform_driver
Factors out a bit of boilerplate.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-28 11:33:29 +00:00
Mark Brown
be086aa8ca ASoC: Convert WM8962 to devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-27 22:02:44 +00:00
Mark Brown
a290986b2a ASoC: Convert wm8996 to use devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-27 16:04:08 +00:00
Mark Brown
897f7847e6 ASoC: Convert wm9081 driver to use devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-27 16:04:02 +00:00
Mark Brown
5fe803f56a ASoC: Convert wm1250-ev1 driver to use devm_kzalloc()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-27 16:03:59 +00:00
Mark Brown
997c2ea916 ASoC: Remove unneeded platform_device.h inclusions from CODECs
They've not been needed for a long time if they were ever required.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-27 12:24:48 +00:00
Mark Brown
679acec1f2 ASoC: Remove driver versioning from ak4642
It's never been updated so it can't be that useful and it makes the
driver needlessly chatty.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-27 12:23:46 +00:00
Mark Brown
a81b82c09e ASoC: Use devm_kzalloc() in wm5100
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-25 13:03:25 +00:00
Mark Brown
878042d19c ASoC: Staticise non-exported symbols in sta32x
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Johannes Stezenbach <js@sig21.net>
2011-11-25 13:03:24 +00:00
Rajendra Nayak
2c043bcbf2 regulator: pass additional of_node to regulator_register()
With device tree support for regulators, its needed that the
regulator_dev->dev device has the right of_node attached.
To be able to do this add an additional parameter to the
regulator_register() api, wherein the dt-adapted driver can
then pass this additional info onto the regulator core.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 18:47:04 +00:00
Mark Brown
16c88583dc ASoC: Remove unused variable in wm8776 driver
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 15:33:55 +00:00
Mark Brown
193b2f3f53 Merge branch 'for-3.2' into for-3.3 2011-11-23 13:12:38 +00:00
Lars-Peter Clausen
890754a878 ASoC: Cleanup duplicated const
Commit 85e7652("ASoC: Constify snd_soc_dai_ops structs") accidentally
introduced a few duplicated consts. This patch cleans it up.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 13:11:50 +00:00
Axel Lin
b284362b6b ASoC: cs42l51: Fix off-by-one for reg_cache_size
Just checking the code in cs42l51_fill_cache():
The cache pointer points to codec->reg_cache + 1.
I think it is because CS42L51_FIRSTREG is 0x01,
so codec->reg_cache[0] is not used here.

Then we read CS42L51_NUMREGS bytes to cache.
So we need reg_cache_size to be CS42L51_NUMREGS + 1.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 11:34:21 +00:00
Lars-Peter Clausen
85e7652d89 ASoC: Constify snd_soc_dai_ops structs
Commit 1ee46ebd("ASoC: Make the DAI ops constant in the DAI structure")
introduced the possibility to have constant DAI ops structures, yet this is
barley used in both existing drivers and also new drivers being submitted,
although none of them modifies its DAI ops structure. The later is not
surprising since existing drivers are often used as templates for new drivers.
So this patch just constifies all existing snd_soc_dai_ops structs to eliminate
the issue altogether.

The patch was generated with the following coccinelle semantic patch:
// <smpl>
@@
identifier ops;
@@
-struct snd_soc_dai_ops ops =
+const struct snd_soc_dai_ops ops =
{ ... };
// </smpl>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 10:40:46 +00:00
Mark Brown
1db3c98e18 ASoC: Convert wm8776 to table based control and DAPM init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 10:00:34 +00:00
Mark Brown
404417e6b4 ASoC: Staticise and constify cs42l73_reg_defaults
It's not exported and doesn't need to change.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-23 09:52:56 +00:00
Mark Brown
34c3a64a45 Merge branch 'for-3.2' into for-3.3 2011-11-22 23:07:23 +00:00
Daniel Mack
d66b8537b3 ASoC: cs4720: use snd_soc_cache_sync()
Replace the manual register restore mechanism in cs4270.c and call the
generic snd_soc_cache_sync() handler instead.

This factors code out in favour of core facilities and also fixes a
bus confusion that is most probably caused by intermixing i2c-regmap
functions and i2c_smbus_* accessors.

Signed-off-by: Daniel Mack <zonque@gmail.com>
Reported-and-tested-by: Sven Neumann <s.neumann@raumfeld.com>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-22 23:06:07 +00:00
Mark Brown
e3470da9e6 Merge branch 'for-3.2' into for-3.3 2011-11-22 13:09:03 +00:00
Axel Lin
5c4b2aa3fd ASoC: max9877: Update register if either val or val2 is changed
In the case of ((max9877_regs[reg] >> shift) & mask) != val
but ((max9877_regs[reg2] >> shift) & mask) == val2,
current code does not update the registers.

Fix the logic to update registers if either val or val2 is changed.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-22 13:06:21 +00:00
Axel Lin
72531c9434 ASoC: Fix wrong define for AD1836_ADC_WORD_OFFSET
According to the datasheet:
The BIT[5:4] of ADC Control Register 2 is to control the word width.
        00 = 25 Bits
        01 = 20 Bits
        10 = 16 Bits
        11 = Invalid

Thus, the AD1836_ADC_WORD_OFFSET should be defined as 4.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2011-11-22 13:06:14 +00:00
Axel Lin
dbb1f51637 ASoC: cs42l73: Make inv and format to be unsigned int
Fix below smatch warning:

sound/soc/codecs/cs42l73.c +1030 cs42l73_set_dai_fmt(53) error: inv is never equal to 1024 (wrong type 0 - 255).
sound/soc/codecs/cs42l73.c +1032 cs42l73_set_dai_fmt(55) error: inv is never equal to 768 (wrong type 0 - 255).
sound/soc/codecs/cs42l73.c +1036 cs42l73_set_dai_fmt(59) error: inv is never equal to 1024 (wrong type 0 - 255).

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-22 13:02:17 +00:00
Axel Lin
717b8fae38 ASoC: cs42l73: Unify the way to define bits of register
Current code defines some bits with left shift to the proper bit defined in
datasheet, but some don't.
Unify the definition with proper left shift and adjust the code accordingly.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-22 13:02:09 +00:00
Mark Brown
12a7a709a0 ASoC: Remove conditional I2C usage from tlv320aic3x driver
The driver only supports I2C so doesn't need to do things conditionally.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Jarkko Nikula <jhnikula@gmail.com>
2011-11-22 11:59:50 +00:00
Mark Brown
f733547aa3 ASoC: Remove WM5100 DSP memory windows from register default data
They're all volatile so shouldn't have defaults and as we've got pages
into the DSP memory the registers themselves aren't that useful - a
further patch adding support for the DSPs will provide direct diagnostic
access to the DSP memories.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-21 18:11:43 +00:00
Mark Brown
56a926dd72 ASoC: Convert WM8753 to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-21 18:07:18 +00:00
Axel Lin
afe713089a ASoC: Remove redundant regcache_sync call in cs42l73_resume
It's done in cs42l73_set_bias_level when the dapm.bias_level is switching
from SND_SOC_BIAS_OFF to SND_SOC_BIAS_STANDBY.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-21 17:05:53 +00:00
Axel Lin
8421f620da ASoC: cs42l73: Show correct revision id
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-21 17:05:52 +00:00
Axel Lin
ea07561581 ASoC: cs42l73: Return proper error code if device id mismatch
Return -ENODEV instead of 0 if device id mismatch.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-21 17:05:52 +00:00
Mark Brown
6413d542b0 Merge branch 'for-3.2' into for-3.3 2011-11-21 17:01:12 +00:00
Mark Brown
cb555318ca ASoC: Use table based init for wm8731_snd_controls
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-21 17:00:17 +00:00
Mark Brown
ed3e80c4c9 ASoC: Ensure WM8731 register cache is synced when resuming from disabled
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2011-11-21 16:58:46 +00:00
Mark Brown
70a28f841d Merge branch 'for-3.2' into for-3.3 2011-11-21 11:28:19 +00:00
Mark Brown
1d9a91db92 Merge branch 'DB_RANGE-size-fixes' of git://git.alsa-project.org/alsa-kprivate into for-3.2 2011-11-21 11:28:11 +00:00
Axel Lin
ef0cd47093 ASoC: cs4271: Fix wrong mask parameter in some snd_soc_update_bits calls
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Alexander Sverdlin <subaparts@yandex.ru>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-20 20:58:21 +00:00
Clemens Ladisch
028aa634e1 ASoC: wm_hubs: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
reading more data than actually is in the array.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:52 +01:00
Clemens Ladisch
a1320fee27 ASoC: wm9090: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
reading more data than actually is in the arrays.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:51 +01:00
Clemens Ladisch
dac678f5c2 ASoC: wm8993: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
reading more data than actually is in the array.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:51 +01:00
Clemens Ladisch
43e9dc7bce ASoC: wm8962: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
reading more data than actually is in the arrays.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:50 +01:00
Clemens Ladisch
740fb9d512 ASoC: sgtl5000: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
reading more data than actually is in the array.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:50 +01:00
Clemens Ladisch
a19ea0b8ec ASoC: rt5631: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
the last entry from being omitted.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:25 +01:00
Clemens Ladisch
0aed4a95ce ASoC: adau1373: fix DB_RANGE size
Give the correct number of entries to TLV_DB_RANGE_HEAD to prevent
reading more data than actually is in the array.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2011-11-20 15:46:24 +01:00
Leon Romanovsky
2f534edc15 ASoC: alc5632: Remove volatile registers from regmap defaults
There is no need to provide defaults for the volatile
registers and doing so might cause confusion.

Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-17 16:49:39 +00:00
Mark Brown
4fbf4ad40f Merge branch 'for-3.2' into for-3.3 2011-11-17 16:48:57 +00:00
Timo Juhani Lindfors
2391a0e067 ASoC: wm8753: Skip noop reconfiguration of DAI mode
This patch makes it possible to set DAI mode to its currently applied
value even if codec is active. This is necessary to allow

aplay -t raw -r 44100 -f S16_LE -c 2 < /dev/urandom &
alsactl store -f backup.state
alsactl restore -f backup.state

to work without returning errors. This patch is based on a patch sent
by Klaus Kurzmann <mok@fluxnetz.de>.

Signed-off-by: Timo Juhani Lindfors <timo.lindfors@iki.fi>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2011-11-17 16:48:25 +00:00
Leon Romanovsky
277c01bb45 ASoC: alc5632: Update of i2c_probe function to use regmap API only
Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-17 16:48:18 +00:00
Leon Romanovsky
9b4156cbe9 ASoC: alc5632: Added support of two undocumented registers
There are two undocumented registers in use in alc5632_i2c_probe
function. It must be added to support future rewrite of this
function to use regmap API completely.

Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-17 16:48:17 +00:00
Leon Romanovsky
43fa8e5337 ASoC: alc5632: Remove unrelevant registers and name the relevant
Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-17 16:48:17 +00:00
Brian Austin
6d10c91493 ASoC: Add support for CS42L73 codec
This patch adds support for the Cirrus Logic CS42L73 low power stereo
codec.

Signed-off-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Georgi Vlaev <joe@nucleusys.com>
Acked-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-17 16:46:40 +00:00
Mark Brown
086834e2d2 ASoC: Say how long short WM8958 DSP2 firmwares are
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-16 17:33:58 +00:00
Andrey Danin
1a083257eb ASoC: alc5632: rename volume/switch contols for master and speaker volumes.
Signed-off-by: Andrey Danin <danindrey@mail.ru>
Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-16 10:43:28 +00:00
Leon Romanovsky
bb39753c2b ASoC: Convert ALC5632 codec to use regmap API
Signed-off-by: Leon Romanovsky <leon@leon.nu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-11-16 10:41:56 +00:00