Wan ZongShun [Tue, 18 May 2010 05:41:46 +0000 (13:41 +0800)]
ASoC: NUC900/audio: add nuc900 audio driver support
Add support for NUC900 AC97
Signed-off-by: Wan ZongShun <mcuos.com@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
apatard@mandriva.com [Sat, 15 May 2010 15:30:01 +0000 (17:30 +0200)]
ASoC: Add SOC_DOUBLE_R_SX_TLV control
This patch is adding a new control which has the following capabilities:
- tlv
- variable data size (for instance, 7 ou 8 bit)
- double mixer
- data range centered around 0
Signed-off-by: Arnaud Patard <apatard@mandriva.com>
Acked-by: Liam Girdwood <lrg@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Mon, 10 May 2010 17:36:37 +0000 (18:36 +0100)]
ASoC: Don't restart unconfigured WM8994 FLLs
If the FLL is not configured attempting to resume it will produce a
warning message so skip the resume.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 10 May 2010 15:13:11 +0000 (16:13 +0100)]
ASoC: Reorder power down sequence for WM hubs devices
Disable the output stage prior to the delay stage rather than the
other way around. Fixes merge issue with previous headphone output
path corrections.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 10 May 2010 13:56:03 +0000 (14:56 +0100)]
ASoC: Add additional WM hubs DC servo trace
Log the values we're getting back from the DC servo and the values we
write to it.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 10 May 2010 13:55:04 +0000 (14:55 +0100)]
ASoC: Add register write logging for WM8994
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Mon, 10 May 2010 11:39:24 +0000 (14:39 +0300)]
ASoC: core: Fix for the volume limiting when invert is in use
If the register for the volume needs invert, than the inversion
need to be done from the chip maximum, and not from the platform
dependent limit.
Introduce soc_mixer_control.platform_max value, which initially
equals to chip maximum.
The snd_soc_limit_volume function only modify the platform_max,
all volsw_info call returns this as well.
The .max value holds the chip default (maximum), and it is used
for the inversion, if it is needed.
Additional check in the volsw_info call has been added to check
the validity of the platform_max in case, when custom macros
used by codec drivers are not initializing it correctly.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 17:39:25 +0000 (18:39 +0100)]
ASoC: Use more idiomatic driver name for WM8731
Make dev_() prints much prettier.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Fri, 7 May 2010 18:14:45 +0000 (19:14 +0100)]
ASoC: Refactor WM8731 regulator management into bias management
This allows more flexible integration with subsystem features.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Sun, 9 May 2010 12:25:43 +0000 (13:25 +0100)]
ASoC: Allow DAI links to be kept active over suspend
As well as allowing DAPM pins to be marked as ignoring suspend allow DAI
links to be similarly marked. This is primarily intended for digital
links between CODECs and non-CPU devices such as basebands in mobile
phones and will suppress all suspend calls for the DAI link. It is
likely that this will need to be revisited if used with devices which
are part of the SoC CPU.
Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 20:18:53 +0000 (21:18 +0100)]
ASoC: Allow active paths from the GSM modem while the GTA02 is suspended
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 20:11:40 +0000 (21:11 +0100)]
ASoC: Support leaving paths enabled over system suspend
Some devices can usefully run audio while the Linux system is suspended.
One of the most common examples is smartphone systems, which are normally
designed to allow audio to be run between the baseband and the CODEC
without passing through the CPU and so can suspend the CPU when on a
voice call for additional power savings.
Support such systems by providing an API snd_soc_dapm_ignore_suspend().
This can be used to mark DAPM endpoints as not being sensitive to
system suspend. When the system is being suspended paths between
endpoints which are marked as ignoring suspend will be kept active.
Both source and sink must be marked, and there must already be an
active path between the two endpoints prior to suspend.
When paths are active over suspend the bias management will hold the
device bias in the ON state. This is used to avoid suspending the
CODEC while it is still in use.
Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 19:24:05 +0000 (20:24 +0100)]
ASoC: Refactor DAPM suspend handling
Instead of using stream events to handle power down during suspend
integrate the handling with the normal widget path checking by
replacing all cases where we report a connected endpoint in a path
with a function snd_soc_dapm_suspend_check() which looks at the ALSA
power state for the card and reports false if we are in a D3 state.
Since the core moves us into D3 prior to initating the suspend all
power checks during suspend will cause the widgets to be powered
down. In order to ensure that widgets are powered up on resume set
the card to D2 at the start of resume handling (ALSA API calls
require D0 so we are still protected against userspace access).
Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 17:40:54 +0000 (18:40 +0100)]
ASoC: Remove unused DAPM suspend flag
We now manage suspend within the main power analysis rather than by
flipping the state of widgets.
Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 19:30:00 +0000 (20:30 +0100)]
ASoC: Remove unneeded suspend bias managment from CODEC drivers
The core will ensure that the device is in either STANDBY or OFF bias
before suspending, restoring the bias in the driver is unneeded. Some
drivers doing slightly more roundabout things have been left alone
for now.
Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:57:17 +0000 (15:57 +0900)]
ASoC: SMDK64XX: Switch to IISv4 CPU driver
Switch the MACHINE driver to use IISv4 CPU dai.
Remove BROKEN dependency now that we have proper CPU driver available.
Also, disable build for SMDK6400, since the S3C6400 doesn't have IISv4
controller.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:57:11 +0000 (15:57 +0900)]
ASoC: S3C64XX: IISv4: Add CPU driver
Add the CPU driver for the IISv4 block found on S3C6410.
For now, the driver is almost a copy of s3c64xx-i2s.c but
it should diverge as more IISv4 specific stuff is added.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Peter Ujfalusi [Fri, 7 May 2010 11:24:11 +0000 (14:24 +0300)]
ASoC: tpa6130a2: Fix for the custom kcontrol functions
Since the functions arre only used for volume register,
change their name, and also fix them to properly
handle the cases, when via soc core the volume is
limited.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Peter Ujfalusi [Fri, 7 May 2010 11:24:10 +0000 (14:24 +0300)]
Revert "ASoC: tpa6130a2: Support for limiting gain"
This reverts commit
6f3991152f20933b77eff30413e893bf1a15e578.
Since core has now support for limiting the volume on controls this
patch is not needed. Furthermore, this patch actually prevents the core
to set new volume on the TPA.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Peter Ujfalusi [Fri, 7 May 2010 11:05:49 +0000 (14:05 +0300)]
ASoC: core: Support for limiting the volume
Add support for the core to limit the maximum volume on an
existing control.
The function will modify the soc_mixer_control.max value
of the given control.
The new value must be lower than the original one (chip maximum)
If there is a need for limiting a gain on a given control,
than machine drivers can do the following in their
snd_soc_dai_link.init function:
snd_soc_limit_volume(codec, "TPA6140A2 Headphone Playback Volume", 21);
This will modify the original 31 (chip maximum) to 21, so user
space will not be able to set the gain higher than this.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 7 May 2010 15:38:26 +0000 (16:38 +0100)]
Merge branch 'topic/asoc' of git://git./linux/kernel/git/tiwai/sound-2.6 into for-2.6.35
Jassi Brar [Fri, 7 May 2010 01:21:39 +0000 (10:21 +0900)]
ARM: S3C2412: DMA: Remove I2S FIFO address
The S3C DMA API doesn't make use of hw_addr.to/from and also
the FIFO addresses are provided from the I2S drivers. So these
fields are redundant.
This patch removes the hw_addr.to/from fields for I2S and the
inclusion of header, paving way for the header to be moved closer
to the I2S controller drivers.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Thu, 6 May 2010 15:06:27 +0000 (17:06 +0200)]
Merge branch 'for-2.6.35' of git://git./linux/kernel/git/lrg/asoc-2.6 into topic/asoc
Peter Ujfalusi [Thu, 6 May 2010 09:04:25 +0000 (12:04 +0300)]
ASoC: tlv320dac33: Use codec defaults for LOM/LOP and DAC power
Do not change the codec defaults for the following registers:
0x40, 0x41: Line output gains, do not use amplification
0x42: LOM/LOP Voltage hold, and selection
0x44: LOM inversion control
It has been found, that the values configured to these registers
can cause amplification, which can make the output of DAC33
distorted.
The codec reset values are considered safe in all environmnts.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Thu, 6 May 2010 07:37:18 +0000 (10:37 +0300)]
ASoC: tpa6130a2: Support for limiting gain
Add support for platform dependent gain limiting on the
tpa6130a2 (and tpa6140a2) Headset amplifier.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Jarkko Nikula [Wed, 5 May 2010 10:02:03 +0000 (13:02 +0300)]
ASoC: tlv320aic3x: Add platform data and reset gpio handling
Handle the reset GPIO within the codec driver in order to follow
the startup protocol for the tlv320aic3x codecs.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Jarkko Nikula [Wed, 5 May 2010 08:14:22 +0000 (11:14 +0300)]
ASoC: omap: Add basic audio support for Nokia RX-51/N900
This patch adds support for integrated stereo speakers and digital
microphone found on Nokia RX-51 hardware. This is a cut down version based
on Maemo kernel sources and earlier patchset by Eduardo Valentin et al.
http://mailman.alsa-project.org/pipermail/alsa-devel/2009-October/022033.html
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Cc: Eduardo Valentin <eduardo.valentin@nokia.com>
Cc: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Jassi Brar [Tue, 27 Apr 2010 06:57:05 +0000 (15:57 +0900)]
ASoC: S3C: I2S: Move set_sysclk to common code
Now that we can specify feature of a particular controller, we can
avoid multiple copies of same code by defining the CDCLKCON bit
feature in controller specific code and detecting that flag in the
code common to all controllers.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:56 +0000 (15:56 +0900)]
ASoC: S3C: I2Sv2: New field for controller feature
In order to make s3c-i2s-v2.c manage controllers with minor
quirks and variation in features, we define a per-block flag
that indicates the availability/lack of a particular feature
to the s3c-i2s-v2.c
While adding support for new SoCs' I2S, check for the blocks
of older SoCs that have similar feature and set the flag for
that feature.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:51 +0000 (15:56 +0900)]
ASoC: S3C64XX: I2S: Use s3c2412 defines
Now that the fields are defined for s3c2412, use them and avoid having
multiple copies of same defines.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:45 +0000 (15:56 +0900)]
ASoC: S3C: I2Sv2: Unify i2s_get_clock callback
Now that we have two callbacks s3c2412_i2s_get_clock & s3c64xx_i2s_get_clock
doing exactly the same thing, we can define one generic s3c_i2sv2_get_clock
and discard other two copies. Also, switch the users to make calls to the
newly defined and generic s3c_i2sv2_get_clock
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:39 +0000 (15:56 +0900)]
ASoC: S3C: I2Sv2: Discard redundant field iis_clk
No need to keep redundant field iis_clk in s3c_i2sv2_info.
iis_cclk and iis_pclk is all we need.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:34 +0000 (15:56 +0900)]
ASoC: S3C2412: I2S: Return correct source clock
Until now, s3c2412_get_iisclk would return NULL since iis_clk was never
initialized.
Return appropriate pointer as per the selection made for source clock.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:27 +0000 (15:56 +0900)]
ASoC: S3C2412: I2S: Debug IMS field
The IMS field of s3c2412/13 is essentially the same as that of s3c64xx.
That is, the IISMOD[11] bit decides Master/Slave mode and IISMOD[10] bit
selects source clock for signal generation.
For that reason, remove improper defines for IISMOD[11:10] field mask
and define two 1bit fields that can be set independent of each other.
As a consequence, corresponding fields for PLAT_S3C64XX too get to use
these new defines.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:56:03 +0000 (15:56 +0900)]
ASoC: SAMSUNG: I2S: Add bit definitions
Define more bit definitions in the order of mainline
support for the SoC.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Jassi Brar [Tue, 27 Apr 2010 06:55:21 +0000 (15:55 +0900)]
ASoC: S3C: I2Sv2: Move defines closer to driver
The header for I2Sv2
linux/arch/arm/plat-s3c/include/plat/regs-s3c2412-iis.h
contains only controller specific definitions and nothing
SoC specific. So, it could be moved to sound/soc/s3c24xx/
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Mon, 3 May 2010 15:25:52 +0000 (16:25 +0100)]
ASoC: Add debug output tracing all cache register writes
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Tue, 4 May 2010 08:08:18 +0000 (11:08 +0300)]
ASoC: tpa6130a2: TLV mapping for tpa6140a2
Both tpa6130a2, and tpa6140a2 is supported by the
same driver, but the gain dB scaling is different on
the amplifiers.
Provide different mixer control for the chips with correct
TLV mapping.
User space will see:
"TPA6130A2 Headphone Playback Volume" in case of 6130
"TPA6140A2 Headphone Playback Volume" in case of 6140
The way machine drivers are using this amplifier remained
the same.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 30 Apr 2010 11:59:36 +0000 (14:59 +0300)]
ASoC: tlv320dac33: Support for turning off the codec
Let the codec to hit OFF instead of STANDBY, when there is no activity.
When the codec is off, than the associated regulator can be also turned
off (if the number of users on the regulator is 0).
After initialization, the codec remains in power off, it is only turned
on for reading the ID registers (also testing the regulators).
The codec power is enabled, when the codec is moving from BIAS_OFF
to BIAS_STANDBY.
The codec is turned off, when it hits BIAS_OFF.
There are few scenarios, which has to be taken care::
1. Analog bypass caused BIAS_OFF -> BIAS_ON
We need to power on the codec, and do the chip init, but we does not
need to execute the playback related configuration
2. Playback caused BIAS_OFF -> BIAS_ON
We need to power on the codec, and do the chip init, and also we need
to execute the playback related configuration.
3. Playback start, while Analog bypass is on (BIAS_ON -> BIAS_ON)
We need to execute the playback related configuration. The codec is
already on.
4. Analog bypass enable, while playback (BIAS_ON -> BIAS_ON)
Nothing need to be done.
5. Playback start withing soc power down timeout (BIAS_ON -> BIAS_ON)
We need to execute the playback related configuration. The codec is
still on.
Since the power up, and the codec init is optimized, the added overhead
in stream start is minimal.
Withing this patch, the hard_power function is now only doing what it
supposed to: only handle the powers, and GPIO reset line.
The codec initialization and state restore has been moved out.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 30 Apr 2010 11:59:35 +0000 (14:59 +0300)]
ASoC: tlv320dac33: Manage a pointer for snd_pcm_substream in private structure
As a preparation for supporting codec to be turned off,
when we are in BIAS_STANDBY.
The substream must be easily available in other places than
pcm_* callbacks.
Manage a pointer in _startup, and _shutdown for this.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 30 Apr 2010 11:59:34 +0000 (14:59 +0300)]
ASoC: tlv320dac33: Revised module loading, and DAC33 ID read
Optimize the way how tlv320dac33 is powered uppon module and
soc initialization.
Also read the DAC33 ID registers, and update the reg_cache
to reflect it.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 30 Apr 2010 11:59:33 +0000 (14:59 +0300)]
ASoC: tlv320dac33: Optimize power up, and restore
On power up we only need to initialize the codec, and
restore only registers, which are not in either in DAPM
nor in the playback start sequence.
These are mostly gain related registers.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Thu, 29 Apr 2010 07:58:09 +0000 (10:58 +0300)]
ASoC: TWL4030: Remove OUTL/R outputs
OUTL/R are leftovers from the original driver, and they
are no longer needed.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Thu, 29 Apr 2010 07:58:08 +0000 (10:58 +0300)]
ASoC: TWL4030: AIF/APLL fix in DAPM domain
This patch orders the APLL and AIF power sequence in
case of HiFi (audio in TWL4030 terms) playback/capture.
We also need to make sure that the AIF is running during
playback/capture, when there is no valid DAPM route
available. For this purpose I introduce these virtual
widgets:
/* To have complete playback route all the time */
DAPM_OUTPUT("Virtual HiFi OUT") /* Will keep AIF/APLL enabled */
/* To have complete capture route all the time */
DAPM_INPUT("Virtual HiFi IN") /* Will keep AIF/APLL enabled */
/* To have complete playback route for the voice module */
DAPM_OUTPUT("Virtual Voice OUT") /* Will keep APLL enabled */
The DAPM_SUPPLY widgets for APLL and AIF are placed in a way,
that during any audio activity the needed configuration of AIF
and APLL will be enabled (playback, capture, analog loopback,
digital loopback, and voice activity).
The apll reference counting code has been lifted,
and modified from Liam Girdwood's earlier patch.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Wed, 28 Apr 2010 17:36:10 +0000 (18:36 +0100)]
ASoC: Add WM9090 amplifier driver
The WM9090 is a high performance low power audio subsystem, including
headphone and class D speaker drivers.
Note that this driver is a standalone CODEC driver and so is only
immediately suitable for use with the WM9090 as a standalone sound card
taking line inputs, or with a DAC with no software control. The pending
ASoC multi-CODEC support will expand the range of systems that can use
the driver, or system-specific adaptations can be made.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Liam Girdwood [Fri, 26 Mar 2010 20:05:54 +0000 (20:05 +0000)]
ASoC: tlv320dac33 - disable regulators at i2c remove()
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Liam Girdwood [Mon, 22 Mar 2010 19:35:06 +0000 (19:35 +0000)]
ASoC: zoom2 - update DAPM pins
Remove bogus twl4030 pins
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Liam Girdwood [Mon, 22 Mar 2010 19:30:54 +0000 (19:30 +0000)]
ASoC: pandora - update DAPM pins
Remove bogus TWL4030 pins.
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Tue, 27 Apr 2010 19:01:56 +0000 (20:01 +0100)]
ASoC: Remove redundant WM8960 SYSCLKSEL clkdiv option
The SYSCLK source is automatically managed when configuring the PLL.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Tue, 27 Apr 2010 13:35:59 +0000 (15:35 +0200)]
Merge branch 'for-2.6.35' of git://git./linux/kernel/git/lrg/asoc-2.6 into topic/asoc
Jarkko Nikula [Mon, 26 Apr 2010 12:49:14 +0000 (15:49 +0300)]
ASoC: tlv320aic3x: Add basic regulator support
This patch adds the TLV320AIC3x supplies and enables all of them for the
entire lifetime of the device.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Jarkko Nikula [Mon, 26 Apr 2010 12:49:13 +0000 (15:49 +0300)]
ASoC: tlv320aic3x: Change bias management semantics
Move PLL enable from BIAS_ON state to BIAS_PREPARE to be pair with
BIAS_STANDBY where PLL is disabled. Remove also old comments about power
control.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Jarkko Nikula [Mon, 26 Apr 2010 12:49:12 +0000 (15:49 +0300)]
ASoC: tlv320aic3x: Remove needless power off from aic3x_set_bias_level
These ADC, DAC and output pin power off commands are needless in
aic3x_set_bias_level since they are not enabled in aic3x_init and they are
defined in aic3x_dapm_widgets so the ASoC DAPM will take care of them
anyway.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Jarkko Nikula [Mon, 26 Apr 2010 12:49:11 +0000 (15:49 +0300)]
ASoC: tlv320aic3x: Remove unused version string
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Vladimir Zapolskiy [Mon, 26 Apr 2010 10:56:57 +0000 (14:56 +0400)]
ASoC: UDA134X: Add UDA1345 CODEC support
This patch adds support for Philips UDA1345 CODEC. The CODEC has only
volume control, de-emphasis, mute, DC filtering and power control features.
Signed-off-by: Vladimir Zapolskiy <vzapolskiy@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Sun, 25 Apr 2010 11:20:30 +0000 (12:20 +0100)]
ASoC: Warn on low WM8994 AIFCLK
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Fri, 23 Apr 2010 16:39:23 +0000 (17:39 +0100)]
ASoC: Correct inversion of speaker mixer PCM switch
Reported-by: Anti Sullin <anti.sullin@artecdesign.ee>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 23 Apr 2010 07:10:01 +0000 (10:10 +0300)]
ASoC: tlv320dac33: FIFO caused delay reporting
Delay reporting for the three implemented DAC33 FIFO modes.
DAC33 has FIFO depth status register(s), but it can not be used, since
inside of pcm_pointer we can not send I2C commands.
Timestamp based estimation need to be used. The method of calculating
the delay depends on the active FIFO mode.
Bypass mode: FIFO is bypassed, report 0 as delay
Mode1: nSample fill mode. In this mode I need to use two timestamp
ts1: taken when the interrupt has been received
ts2: taken before writing to nSample register.
Interrupts are coming when DAC33 FIFO depth goes under alarm threshold.
Phase1: when we received the alarm threshold, but our workqueue has
not been executed (safeguard phase). Just count the played out
samples since ts1 and subtract it from the alarm threshold
value.
Phase2: During nSample burst (after writing to nSample register), count
the played out samples since ts1, count the samples received
since ts2 (in a burst). Estimate the FIFO depth using these and
alarm threshold value.
Phase3: Draining phase (after the burst read), count the played out
samples since ts1. Estimate the FIFO depth using the nSample
configuration and the alarm threshold value.
Mode7: Threshold based fill mode. In this mode one timestamp is enough.
ts1: taken when the interrupt has been received
Interrupts are coming when DAC33 FIFO depth reaches upper threshold.
Phase1: Draining phase (after the burst), counting the played out
samples since ts1, and subtract it from the upper threshold
value.
Phase2: During burst operation. Using the pre calculated time needed to
play out samples from the buffer during the drain period (from
upper to lower threshold), move the time window to cover the
estimated time from the burst start to the current time.
Calculate the samples played out since lower threshold and also
the samples received during the same time.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 23 Apr 2010 07:10:00 +0000 (10:10 +0300)]
ASoC: tlv320dac33: Calculate the interface speed during bursts
When the DAC33 FIFO is in use the dai interface is running in
much higher speed than the sampling frequency.
Calculate the rate based on the internal base frequency and
the bclk divider.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 23 Apr 2010 07:09:59 +0000 (10:09 +0300)]
ASoC: tlv320dac33: Change magic numbers used in Mode7
Upper and Lower threshold values are used as magic
numbers. Replace them with defines for later use.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 23 Apr 2010 07:09:58 +0000 (10:09 +0300)]
ASoC: tlv320dac33: Skip calculations in FIFO Bypass mode
There is no need for calculations for FIFO bypass mode.
Just in case set the nsample maximum limit, which
has been done in the calculation phase.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Peter Ujfalusi [Fri, 23 Apr 2010 07:09:57 +0000 (10:09 +0300)]
ASoC: tlv320dac33: Fix for early interrupt in FIFO Mode1
Alarm threshold interrupt is triggered right after the
playback start.
This interrupt is recieved during the first burst period,
and caused the state machine to write additional nSample
command, which has to be avoided.
To fix this issue move the DAC33 interrupt unmasking
after we configured the PREFILL register with a small
delay.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 29 Mar 2010 19:31:14 +0000 (20:31 +0100)]
ASoC: Allow reporting of NULL jacks
Follow the core jack implementation and allow reporting on the status
of NULL jacks, avoiding the need to check in detection implementations.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Barry Song [Wed, 21 Apr 2010 09:36:49 +0000 (17:36 +0800)]
ASoC: ad193x: fix typo, delete redundant space
Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Barry Song [Wed, 21 Apr 2010 09:36:48 +0000 (17:36 +0800)]
ASoC: ad193x: fix wrong register setting in ad193x_set_dai_fmt
Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Wed, 21 Apr 2010 17:29:01 +0000 (02:29 +0900)]
ASoC: Allow unspecified source when stopping WM8994 FLLs
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Tue, 20 Apr 2010 04:57:08 +0000 (13:57 +0900)]
ASoC: Tone down debugging for WM8994 class W
It's a little verbose during path changes.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Tue, 20 Apr 2010 04:36:11 +0000 (13:36 +0900)]
ASoC: Set full range of WM8994 FLL Fratio values
Use all the available Fratio values when configuring the WM8994 FLL, not
just 0 and 3, following more complete characterisation of the device
performance.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Tue, 20 Apr 2010 03:56:18 +0000 (12:56 +0900)]
ASoC: Support FLL input clock selection on WM8994
The WM8994 FLL can be clocked from one of four inputs, the two MCLKs and
the LRCLK and BCLK of the AIF associated with the FLL. Allow all four
inputs to be used rather than defaulting to MCLK1.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Phil Carmody [Wed, 14 Apr 2010 14:03:13 +0000 (17:03 +0300)]
ASoC: da7210: Fencepost error in reg cache read
An index equal to the array size may not be accessed.
Signed-off-by: Phil Carmody <ext-phil.2.carmody@nokia.com>
Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Tue, 20 Apr 2010 06:20:31 +0000 (08:20 +0200)]
ASoC: missing conversions to snd_soc_codec_*_drvdata()
Conversions to snd_soc_codec_{get|set}_drvdata() were missing in some files
in the previous commit.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mark Brown [Wed, 14 Apr 2010 06:35:19 +0000 (15:35 +0900)]
ASoC: Add indirection for CODEC private data
One of the features of the multi CODEC work is that it embeds a struct
device in the CODEC to provide diagnostics via a sysfs class rather than
via the device tree, at which point it's much better to use the struct
device private data rather than having two places to store it. Provide
an accessor function to allow this change to be made more easily, and
update all the CODEC drivers are updated.
To ensure use of the accessor the private data structure member is
renamed, meaning that if code developed with older an older core that
still uses private_data is merged it will fail to build.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Sat, 17 Apr 2010 01:45:54 +0000 (10:45 +0900)]
Merge branch 'for-2.6.34' into for-2.6.35
Sascha Hauer [Wed, 14 Apr 2010 07:17:30 +0000 (09:17 +0200)]
ASoC: imx-ssi: do not call hrtimer_disable in trigger function
Doing so causes a deadlock, so just signal the timer to stop
using an atomic variable.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Sascha Hauer [Wed, 14 Apr 2010 07:17:31 +0000 (09:17 +0200)]
ASoC: imx-ssi: increase minimum periods to 4
Currently the notification of elapsed periods is not very exact.
Increase minimum periods to 4 as suggested by Liam Girdwood.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Marek Vasut [Mon, 5 Apr 2010 04:13:38 +0000 (06:13 +0200)]
ASoC: Zipit Z2 WM8750 ASoC driver
This patch adds support for sound through the WM8750 codec on Zipit Z2.
Also, this patch incorporates support for detecting headset jack
insertion through the jack detection API.
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Bill Gatliff [Fri, 9 Apr 2010 17:08:08 +0000 (18:08 +0100)]
ASoC: Use SNDRV_PCM_RATE_8000_96000 macro for WM8731
Signed-off-by: Bill Gatliff <bgat@billgatliff.com>
Acked-by: Richard Purdie <rpurdie@rpsys.net>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Marek Vasut [Thu, 8 Apr 2010 18:48:51 +0000 (20:48 +0200)]
ASoC: WM8750: Convert to new API
Register the WM8750 as a SPI or I2C device. This patch mostly shuffles code
around. Hugely inspired by WM8753 which was already converted.
Also, this patch fixes the Jive and Spitz machine.
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Sascha Hauer [Thu, 8 Apr 2010 09:31:26 +0000 (11:31 +0200)]
ASoC: imx-ssi: Use a hrtimer in FIQ mode
Using a regular timer results in poll times < 1 jiffie with small
buffers, so we loaded the timer with the actual jiffie value. We can
be more accurate using a hrtimer. Also, we have to call
snd_pcm_period_elapsed after playing period_bytes and not
runtime->period_size (which is in samples and not in bytes).
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Sascha Hauer [Thu, 8 Apr 2010 09:31:25 +0000 (11:31 +0200)]
ASoC: imx-pcm-dma-mx2: restart DMA after an error
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Sascha Hauer [Thu, 8 Apr 2010 09:31:24 +0000 (11:31 +0200)]
ASoC: imx-ssi: honor IMX_SSI_DMA flag
When checking if we are DMA capable we have to check for the
IMX_SSI_DMA flag which is already set from platform_data instead
of setting it again when we want to do DMA.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Liam Girdwood <lrg@Slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Huang Weiyi [Thu, 8 Apr 2010 11:50:08 +0000 (19:50 +0800)]
ASoC: wm2000: remove unused #include <linux/version.h>
Remove unused #include <linux/version.h>('s) in
sound/soc/codecs/wm2000.c
Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Mon, 5 Apr 2010 18:19:32 +0000 (19:19 +0100)]
Merge branch 'for-2.6.34' into for-2.6.35
Conflicts due to context changes next to the backported DMA data change:
include/sound/soc.h
Mark Brown [Mon, 29 Mar 2010 19:57:12 +0000 (20:57 +0100)]
ASoC: Implement interrupt based WM8994 microphone detection
Support interrupt based microphone bias detection. The WM8994 has two
microphone bias supplies, with detection supported on both. Detection
using GPIOs together with the standard GPIO based jack framework is
already supported via the platform data for the WM8994 core driver.
Note that as well as the microphone bias itself the system clock and
whichever AIF clock is supplying the system clock will need to be
enabled for detection to function.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 2 Apr 2010 13:51:59 +0000 (14:51 +0100)]
gpiolib: Implement gpio_to_irq for WM8994 GPIO controller
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Fri, 26 Mar 2010 16:49:15 +0000 (16:49 +0000)]
mfd: Add WM8994 interrupt controller support
The WM8994 has an interrupt controller which supports interrupts for
both CODEC and GPIO portions of the chip. Support this using genirq,
while allowing for systems that do not have an interrupt hooked up.
Wrapper functions are provided for the IRQ request and free to simplify
the code in consumer drivers when handling cases where IRQs are not
set up.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Daniel Mack [Mon, 22 Mar 2010 09:11:15 +0000 (10:11 +0100)]
ALSA: ASoC: move dma_data from snd_soc_dai to snd_soc_pcm_stream
This fixes a memory corruption when ASoC devices are used in
full-duplex mode. Specifically for pxa-ssp code, where this pointer
is dynamically allocated for each direction and destroyed upon each
stream start.
All other platforms are fixed blindly, I couldn't even compile-test
them. Sorry for any breakage I may have caused.
[Note that this is a backported version for 2.6.34.
Upstream commit is
fd23b7dee]
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Reported-by: Sven Neumann <s.neumann@raumfeld.com>
Reported-by: Michael Hirsch <m.hirsch@raumfeld.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Tue, 30 Mar 2010 13:29:14 +0000 (14:29 +0100)]
ASoC: Only do WM8994 bias off transition from standby
Otherwise we may try to power down multiple times when the using
idle bias off and the driver is removed.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 29 Mar 2010 16:18:41 +0000 (17:18 +0100)]
ASoC: Don't use DCS_DATAPATH_BUSY for WM hubs devices
The DCS_DATAPATH_BUSY bit used to monitor the completion of DC servo
operations has been deprecated and with some more recente revisions
may perform incorrectly, especially when only analogue bypass paths
are in use. Switch to using readback from the DC servo command
register instead, which is supported for all devices. Without this
unacceptably long timeouts may be observed in some circumstances.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 29 Mar 2010 15:34:42 +0000 (16:34 +0100)]
ASoC: Don't do runtime wm_hubs DC servo updates if using offset correction
If we need to offset correct the DC servo then don't use runtime
recalibration since that is likely to introduce further offsets
which will be evident on powerdown.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 29 Mar 2010 16:09:45 +0000 (17:09 +0100)]
ASoC: Support second DC servo readback method for wm_hubs
More recent Wolfson hubs devices add the ability to read back the DC
servo calibration information from the register used to write offsets,
and later still ones remove the old readback registers. Add support
for the new scheme, and use it for WM8994 device revisions that
support it.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Mark Brown [Mon, 29 Mar 2010 14:24:40 +0000 (15:24 +0100)]
ASoC: Avoid wraparound in wm_hubs DC servo correction
If the correction wraps around then a substantial offset would be
introduced.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Janusz Krzysztofik [Sun, 28 Mar 2010 20:29:29 +0000 (22:29 +0200)]
ASoC: OMAP: Fix capture pointer handling for OMAP1510 to work correctly with recent ALSA PCM code
With recent (2.6.34) chnages in PCM handling, capture stopped working on my
OMAP1510 based Amstrad Delta videophone.
Using 2.6.34-rc2, I was able to correct the problem in 3 different ways:
1. reverting commit
7b3a177b0d4f92b3431b8dca777313a07533a710,
2. enabling additional jiffies check with
echo 4 >/proc/asound/card0/pcm0c0/xrun_debug
3. applying the patch below.
Since I wasn't able to reproduce the problem on my i686 PC, I guess the
problem is probably machine specific.
The patch reuses the method for software emulation of missing hardware
pointer, already implemented for playback on OMAP1510. It's possible that
event if a hardware pointer is available for capture on this machine, its
behaviour may be not compatible with what upper layer expects.
If you think the problem may be more general and should be solved differently,
on a higher level, I can try to work more on it if you give me a hint.
If the patch gets accepted, I suggest it goes as a fix in the current release
cycle.
Created and tested against linux-2.6.34-rc2.
Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Acked-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tejun Heo [Mon, 29 Mar 2010 17:52:40 +0000 (02:52 +0900)]
mfd: update gfp/slab.h includes
Implicit slab.h inclusion via percpu.h is about to go away. Make sure
gfp.h or slab.h is included as necessary.
Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Mon, 29 Mar 2010 20:03:20 +0000 (21:03 +0100)]
Merge branch 'for-2.6.34' into for-2.6.35
Barry Song [Mon, 29 Mar 2010 03:16:00 +0000 (11:16 +0800)]
ASoC: ad193x: move codec register/unregister to bus probe/remove
The way i've factored out the bus probe and removal functions so
that there's no code in the individual I2C and SPI functions means
that the register() and unregister() functions could just be squashed
into the bus_probe() and bus_remove() functions.
Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Graham Gower [Thu, 25 Mar 2010 00:22:12 +0000 (10:52 +1030)]
ASoC: Fix passing platform_data to ac97 bus users and fix a leak
[The issue is an attempt to write the pdata without the AC97 device
allocated when using ac97.c - also added a comment in soc-core.c for the
special case for ac97. -- broonie]
Signed-off-by: Graham Gower <graham.gower@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Mon, 29 Mar 2010 20:00:04 +0000 (21:00 +0100)]
Merge branch 'topic/asoc' of git://git./linux/kernel/git/tiwai/sound-2.6 into for-2.6.35
Tejun Heo [Mon, 29 Mar 2010 17:52:29 +0000 (02:52 +0900)]
ASoC: update gfp/slab.h includes
Implicit slab.h inclusion via percpu.h is about to go away. Make sure
gfp.h or slab.h is included as necessary.
Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 29 Mar 2010 07:31:57 +0000 (09:31 +0200)]
ASoC: Fix file permission of soc/codecs/twl6040.c
Signed-off-by: Takashi Iwai <tiwai@suse.de>