Commit graph

323307 commits

Author SHA1 Message Date
David Henningsson 5c2e4e0ab6 ALSA: hda - make Cirrus codec use generic unsol event handler
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-08 15:48:09 +02:00
David Henningsson 4e2d16d326 ALSA: hda - make VIA codec use generic unsol event handler
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-08 15:48:02 +02:00
David Henningsson 67aeda1f34 ALSA: hda - Remove dead GPIO code for VIA codec
From what I can conclude all GPIO handling was removed in 2009.
Remove dead code remnants.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-08 15:47:54 +02:00
Oto Petřík 613769fcab ALSA: usb-audio: Add TASCAM US122 MKII playback
Added quirk to provide at least playback-only support.

Signed-off-by: Oto Petrik <oto.petrik@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-08 15:16:33 +02:00
Kailang Yang 7ff34ad80b ALSA: hda - Add new codec ALC283 ALC290 support
These are compatible with standard ALC269 parser.

Signed-off-by: Kailang Yang <kailang@realtek.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 17:02:30 +02:00
David Henningsson eee3ed43a6 ALSA: hda - avoid unneccesary indices on "Headphone Jack" controls
In case there is one "Headphone Jack" and one "Dock Headphone Jack",
one of them will get an index, even though that is not needed.
This patch fixes that issue.

BugLink: https://bugs.launchpad.net/bugs/1060729
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:51:09 +02:00
David Henningsson 74d3e69728 ALSA: hda - fix indices on boost volume on Conexant
After the recent patch "ALSA: hda - use both input paths on Conexant
auto parser" suddenly we can have more than one "Mic Boost", this
happened on Acer Aspire One 722. Therefore we must add the possibility
to put an index on this "Mic Boost" just as we do for the other
"Mic Boost" earlier in the same function.

BugLink: https://bugs.launchpad.net/bugs/1059523
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:50:47 +02:00
Omair Mohammed Abdullah d4f1e48bd1 ALSA: aloop - add locking to timer access
When the loopback timer handler is running, calling del_timer() (for STOP
trigger) will not wait for the handler to complete before deactivating the
timer. The timer gets rescheduled in the handler as usual. Then a subsequent
START trigger will try to start the timer using add_timer() with a timer pending
leading to a kernel panic.

Serialize the calls to add_timer() and del_timer() using a spin lock to avoid
this.

Signed-off-by: Omair Mohammed Abdullah <omair.m.abdullah@linux.intel.com>
Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:50:28 +02:00
Dylan Reid d17344b354 ALSA: hda - Fix hang caused by race during suspend.
There was a race condition when the system suspends while hda_power_work
is running in the work queue.  If system suspend (snd_hda_suspend)
happens after the work queue releases power_lock but before it calls
hda_call_codec_suspend,  codec_suspend runs with power_on=0, causing the
codec to power up for register reads, and hanging when it calls
cancel_delayed_work_sync from the running work queue.

The call chain from the work queue will look like this:
hda_power_work <<- power_on = 1, unlock, then power_on cleard by suspend
  hda_call_codec_suspend
    hda_set_power_state
      snd_hda_codec_read
        codec_exec_verb
          snd_hda_power_up
	    snd_hda_power_save
	      __snd_hda_power_up
	        cancel_delayed_work_sync <<-- cancelling executing wq

Fix this by waiting for the work queue to finish before starting suspend
if suspend is not happening on the work queue.

Signed-off-by: Dylan Reid <dgreid@chromium.org>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:49:30 +02:00
Peter Senna Tschudin 395d9dd5dd sound: Remove unnecessary semicolon
A simplified version of the semantic patch that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@r1@
statement S;
position p,p1;
@@
S@p1;@p

@script:python r2@
p << r1.p;
p1 << r1.p1;
@@
if p[0].line != p1[0].line_end:
        cocci.include_match(False)
@@
position r1.p;
@@
-;@p
// </smpl>

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:47:53 +02:00
Herton Ronaldo Krzesinski 9f720bb940 ALSA: hda/realtek - Fix detection of ALC271X codec
In commit af741c1 ("ALSA: hda/realtek - Call alc_auto_parse_customize_define()
always after fixup"), alc_auto_parse_customize_define was moved after
detection of ALC271X.

The problem is that detection of ALC271X relies on spec->cdefine.platform_type,
and it's set on alc_auto_parse_customize_define.

Move the alc_auto_parse_customize_define and its required fixup setup
before the block doing the ALC271X and other codec setup.

BugLink: https://bugs.launchpad.net/bugs/1006690
Signed-off-by: Herton Ronaldo Krzesinski <herton.krzesinski@canonical.com>
Reviewed-by: David Henningsson <david.henningsson@canonical.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:47:24 +02:00
Felix Kaechele e4db0952e5 ALSA: hda - Add inverted internal mic quirk for Lenovo IdeaPad U310
The Lenovo IdeaPad U310 has an internal mic where the right channel
is phase inverted.

Signed-off-by: Felix Kaechele <felix@fetzig.org>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:45:53 +02:00
David Henningsson 29adc4b9e6 ALSA: hda - make Realtek/Sigmatel/Conexant use the generic unsol event
For less duplication of code between codecs, and to make it easier
in the future to improve code for all codecs simultaneously.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:43:40 +02:00
David Henningsson 954df2a968 ALSA: hda - make a generic unsol event handler
Moving towards less duplication of code between codecs - this patch
takes some of the common code of unsol event handling and makes it
generic.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-10-06 16:43:31 +02:00
Takashi Iwai 0fd0ba5f9e ASoC: Additional updates for v3.7
A couple more updates for 3.7, enhancements to the ux500 and wm2000
 drivers, a new driver for DA9055 and the support for regulator bypass
 mode.  With the exception of the DA9055 this has all had a chance to
 soak in -next (the driver was added on Friday so should be in -next
 today).
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.12 (GNU/Linux)
 
 iQIcBAABAgAGBQJQaWzdAAoJEOoSHmUN5Tg4UB0P/Avr2Xbg+aH6hrqcSBe7TR1C
 410uSU/4b9vz3BOoZ3ITW8+6C9chwtnOPuRsCtUQbWFy8Rd9rZvmNQL2xLYK/NMt
 tMvRMJXQZtwGCes8Agw5mme9Pcun7ra5vKwQ93mxvTqAQOkLTlCo43PcXSr9j8+Z
 QnnVlajOECm3+PjwXzQ9dwc+QhgAiLR35Xhe7CsCKvj278Ng4FenZpxj+FySaXhL
 rZnSnImNUn/zAuSIlsOasTOciSNwuqrGcdholpWcFJ8qHzAmntAL4VBrQQl3FNNh
 qTsrIzzlByEdK5qFr8/7erRlni4Xy1YmSOhtJ85fGFfo62xUK+cdLCpvPFKwqTPt
 GfQtsqnKTUNBUSoAHDHWCf0zP4/80ZD4XTEpt8+3Oj7QsKzwU2YS3gNf9zQktDtZ
 lMKo/yN0ihPAmIHLtQdXpNDCuZDyurP/r11sJku4GQXnQG302pzGo8Lc5mig7Tzw
 5TDQ58OY4Gz4pJZ7y70nGn8+z3nMMBkoMFXZD1dBxgQnNdvNWrgu1jiGPOHrHXMm
 TkVS3i7VWXAwX5jAGnXeUOuNmlGsvHE/WO7dantGGgf1ef06oqcM/FEeew7heme0
 oLYiklbhaxdWED632FVjzsOpgEwTF+QUqKpzAMFsFieK9yQzFiZ2mkuMT+1QoQaI
 8ksSVvD1cP/yXkVf8h1E
 =nHb7
 -----END PGP SIGNATURE-----

Merge tag 'asoc-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next

ASoC: Additional updates for v3.7

A couple more updates for 3.7, enhancements to the ux500 and wm2000
drivers, a new driver for DA9055 and the support for regulator bypass
mode.  With the exception of the DA9055 this has all had a chance to
soak in -next (the driver was added on Friday so should be in -next
today).
2012-10-06 16:33:52 +02:00
Ashish Chavan 9911f7f756 ASoC: codecs: Add DA9055 codec driver
This patch adds support for Dialog semiconductor's DA9055 audio codec.

This has been tested on DA9055 EVB with Samsung SMDK6410 board.

Signed-off-by: Ashish Chavan <ashish.chavan@kpitcummins.com>
Signed-off-by: David Dajun Chen <david.chen@diasemi.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-28 14:21:54 +01:00
Fabio Estevam da75c92487 ASoC: eukrea-tlv320: Convert it to platform driver
Convert eukrea-tlv320 to platform driver.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-28 14:12:52 +01:00
Daniel Mack a31ebc349d ALSA: ASoC: add DT bindings for CS4271
Apart from pure matching, the bindings also support setting the the
reset gpio line.

Signed-off-by: Daniel Mack <zonque@gmail.com>
Cc: Alexander Sverdlin <subaparts@yandex.ru>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-28 14:12:09 +01:00
Mark Brown eb4d5fc1f0 ASoC: wm_hubs: Ensure volume updates are handled during class W startup
In some circumstances we may need to flush volume updates to the device
after switching to class W mode. Do this unconditionally to ensure that
these situations are handled.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2012-09-28 12:06:31 +01:00
Charles Keepax ae60503741 ASoC: wm5110: Adding missing volume update bits
The volume update bits were being set on all but one input and one output.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2012-09-27 17:58:25 +01:00
Mark Brown 20bf691f4e ASoC: wm5110: Add OUT3R support
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 19:21:29 +01:00
Mark Brown dac8f1c422 ASoC: wm5110: Add AEC loopback support
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 19:21:28 +01:00
Mark Brown 35d3889389 ASoC: wm5110: Rename EPOUT to HPOUT3
The third output on WM5110 is a general purpose headphone output which can
be used to drive an earpice rather than a dedicated earpiece driver.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 19:21:28 +01:00
Mark Brown aeaeee1a1f ASoC: arizona: Add more clock rates
Some devices support additional clock rates.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 19:16:35 +01:00
Mark Brown c922cc4c1c ASoC: arizona: Add more DSP options for mixer input muxes
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 19:16:26 +01:00
Mark Brown 9bb684442c ASoC: wm0010: Initialise chip state before we register the interrupt
The interrupt handler uses the chip state.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 13:54:00 +01:00
Mark Brown 5afe5bfe24 ASoC: wm0010: Don't check if reset GPIO is defined when removing
We will fail to probe without one.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 13:53:59 +01:00
Mark Brown fff00cbca1 ASoC: wm0010: Allow slow GPIO for reset
We never set the GPIO from atomic context so there's no reason why we
can't support a GPIO that needs to sleep when configuring.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 13:53:55 +01:00
Mark Brown 76dbd2af78 ASoC: wm5110: Enable bypass mode for MICVDD
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 12:30:03 +01:00
Mark Brown bb09d97855 ASoC: wm5102: Enable bypass mode for MICVDD
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 12:30:01 +01:00
Mark Brown c05b84d14b ASoC: dapm: Allow regulators to bypass as well as disable when idle
Allow regulators managed via DAPM to make use of the bypass support that
has recently been added to the regulator API by setting a flag
SND_SOC_DAPM_REGULATOR_BYPASS. When this flag is set the regulator will
be put into bypass mode before being disabled, allowing the regulator to
fall into bypass mode if it can't be disabled due to other users.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-26 12:29:59 +01:00
Mark Brown 8f6862d4bd regulator: Bypass mode support
Allow regulators to be put into a non-regulating mode bypassing the
 input straight to the output, mostly used by low power retention modes.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.12 (GNU/Linux)
 
 iQIcBAABAgAGBQJQYuORAAoJEOoSHmUN5Tg4xRUQAL1OwYJsLfbwNEjeVnxDjpWU
 La4HS3xLYZ/CHHSXJRJnithc/fqrjuTryEMUYVDaXW3MHt53Yc98ENJmnieurR4Y
 LJ6lMI2+DKPmgiR9G2HlqOUPbqBRMytAQS7e8u+xLV4MFB+xSPO/y/ntHPfQCzS3
 OqEU1xXkmxRMUPBugY5fgoI92tpYAmTJwP+EziiBV5mWjL85DA7oARGU1V3opgrh
 EKJzMFdiajtCaTj8JTjMDaGLAd6+R8S1TrT+dEF85VWZgVCcMG+RY37z3oknWfHR
 2yDC7jBRl9LiPaP/QvBegbauU862uQlZo0Kz3xDPdU3a1fV7ugpuIusuQCalh0nD
 RHLaiqK4Y8xDvvh0P6WwBKY1HTTs6Y0vgN/OqYoLETnavkOV8LM4JnkoHb9BfeiP
 LhGKBX5u/AiffDL30gVhy5adSXLJQBPyFYjVXCXZQB6EA4XsDxS+bVq31E0XXCY+
 JsNOOu391sEsOPrtpnGDsztvG+AMKBWDe594xGUTWJKnlScW3vd3wEWS1JNw90TG
 TkiA6GadKRADPV1R49iEJdKRcgqGnbY3+msP3rK9Pe/0gxF4QSfSwmvE9eWv+UFA
 Jq0899StOIbovIC+IyY49CgxiewnwOeZO52dmU4gQ7EiXzq4y2wsGYX4SMd52B2q
 dqTs4BzNw2B/kcrPw3Qb
 =Fi2j
 -----END PGP SIGNATURE-----

Merge tag 'bypass' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator into for-3.7

regulator: Bypass mode support

Allow regulators to be put into a non-regulating mode bypassing the
input straight to the output, mostly used by low power retention modes.
2012-09-26 12:29:31 +01:00
Fabio Estevam f76fe059dd ASoC: cs4270: Remove mono support
According to cs4270 datasheet, there is no reference to mono mode.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-25 13:52:42 +01:00
Peter Ujfalusi b7ef37d0e3 ARM: SAMSUNG: dma-ops: Fix dmaengine_prep_dma_cyclic() parameter list
There is a new flags parameter for the function.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-09-24 18:35:47 +02:00
Peter Ujfalusi e7736cdea2 dmaengine: Add flags parameter to dmaengine_prep_dma_cyclic()
With this parameter added to dmaengine_prep_dma_cyclic() the API will be in
sync with other dmaengine_prep_*() functions.
The dmaengine_prep_dma_cyclic() function primarily used by audio for cyclic
transfer required by ALSA, we use the from audio to ask dma drivers to
suppress interrupts (if DMA_PREP_INTERRUPT is cleared) when it is supported
on the platform.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
CC: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-09-24 18:35:29 +02:00
Takashi Iwai 9d069dc00b ALSA: Make snd_sgbuf_get_{ptr|addr}() available for non-SG cases
Passing struct snd_dma_buffer pointer instead, so that they work no
matter whether real SG buffer is used or not.

This is a preliminary work for the HD-audio DSP loader code.

Signed-off-by: Ian Minett <ian_minett@creativelabs.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-09-23 11:24:42 +02:00
Mark Brown 2ef39e606b Merge remote-tracking branch 'asoc/topic/ux500' into for-3.7 2012-09-22 18:47:58 -04:00
Mark Brown a89be93c28 ASoC: wm2000: Add regulator support
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 18:38:06 -04:00
Mark Brown 8fed54aec8 ASoC: wm2000: Convert to devm_regmap_init_i2c()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 18:38:04 -04:00
Takashi Iwai 3d98c21d06 ASoC: Updates for v3.7
Lots and lots of driver specific cleanups and enhancements but the only
 substantial framework feature this time round is the compressed API
 binding:
 
 - Addition of ASoC bindings for the compressed API, used by the mid-x86
   drivers.
 - Lots of cleanups and API refreshes for CODEC drivers and DaVinci.
 - Conversion of OMAP to dmaengine.
 - New machine driver for Wolfson Microelectronics Bells.
 - New CODEC driver for Wolfson Microelectronics WM0010.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.12 (GNU/Linux)
 
 iQIcBAABAgAGBQJQXdwSAAoJEOoSHmUN5Tg4wxcP/i9EMF61pXgVPG7V+2/+irtr
 n8mw7gFOISK88ay7j/ZZ+ePzfnU1+YzKyhGTbYYn9fdU7/dkj3ME5tLL4s2NWe2w
 G1YDrQ16ttyNx5c53tZM7dmjbsv1UILaVmXcKSmMqbQrgSUS1UvjG1qsLErOSz02
 bTSCW2GpwmLWBChe4vnDyCAJxfUI+TZ1XrsW4oLvIt8SKnHU9GItQOw8XUlV2DZc
 Ylf8L7nLlPx3jkiwjTp2kDHK4MG8yH2ljam4cFXoDQxW3PWkrws9ATpHZjsQhpmd
 vQDa4Wd1OhxPogXZCKh9cLC5B3CTKoFPbyVEJbpmAI04lYJCgxF8amRX+/dmDmS3
 mH38Czv+8rKg76jfOn3bENUNBTL3Q1cPAvoGtwLZX+5MRZyy3kTdkU+N8l4vxrbj
 P7wSgz2KLTJr/im3Lta6YkgbAFCttvZoFfD1jOiUgv00KfBgomY3yWWdgPq/tK/L
 J1J9rJdN8iretaPYrG6ae32V+77HNFYPuUFkPn6vXn+/sTYfoTWw6XSFavK3p9Hg
 kyfuLK/j+SjPVvoNAIOUvwHkYtBDseZe3APGbN/CuIdyzbQVp0v0SGOok2z4S9ZY
 3Ivy2cpeYYqtLuig1IuZEEMUi0Xxp5GfRtITlwrst9BBRQLKdswdh4JOxGPipguM
 vtYzpPeNT622xBtWzMNg
 =JSSt
 -----END PGP SIGNATURE-----

Merge tag 'asoc-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next

ASoC: Updates for v3.7

Lots and lots of driver specific cleanups and enhancements but the only
substantial framework feature this time round is the compressed API
binding:

- Addition of ASoC bindings for the compressed API, used by the mid-x86
  drivers.
- Lots of cleanups and API refreshes for CODEC drivers and DaVinci.
- Conversion of OMAP to dmaengine.
- New machine driver for Wolfson Microelectronics Bells.
- New CODEC driver for Wolfson Microelectronics WM0010.
2012-09-22 18:31:08 +02:00
Mark Brown ddfb43f388 Linux 3.6-rc6
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2.0.18 (GNU/Linux)
 
 iQEcBAABAgAGBQJQVkutAAoJEHm+PkMAQRiGW8sH/36FVQ3zI75QH16AmR++2nMZ
 BRJGoxcRFMssrXTYVdkMyzygf8b7MZbNEn1qt2g63MNzGaJucPlw5NVL4GLzR+zr
 x/EglLrTEPCD5el9wJ3ls9iC1soudKQTvC2BjcdUjpoSwHrDM/7GKfbOacE54Wqc
 C1VHCcg5DWOD7F0RnYT2SQEVCeDODNmcyFdk7Oi4cUicTPJoYWJ9O9MGfBDBok0N
 M+dXxa9nvsl7EeEKpBKH9vo4TfXn3Gsj6LCRdedvI15ilZjfo8jdHYbSn7KBfQuZ
 JIKRnqkaQ1JfMFt+M/JJZ1b/+Wrd4HLMmmn5oUmrGGIvhpi32nJfi/97+nSy8iU=
 =c5gW
 -----END PGP SIGNATURE-----

Merge tag 'v3.6-rc6' into for-3.7

Linux 3.6-rc6 has all our bug fixes.

Conflicts (trivial overlap):
	sound/soc/omap/am3517evm.c
2012-09-22 11:26:27 -04:00
Peter Ujfalusi 2d6d649a2e ASoC: twl4030: Support for DT booted kernel
When the kernel has been booted with DT blob the platform data is NULL for
the driver.
We need to construct the pdata based on the DT information for runtime use.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:33 -04:00
Peter Ujfalusi 182f73f6bb ASoC: twl4030: Add pointer to pdata within the private data
Access the pdata via a pointer within the twl4030_priv structure.
In preparation for DeviceTree support.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:33 -04:00
Peter Ujfalusi f2b1ce4949 ASoC: twl4030: Convert to use devm_kzalloc
Allocate the private data with devm_kzalloc.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:32 -04:00
Peter Ujfalusi d0b3847b40 ASoC/mfd: twl4030: Remove set_hs_extmute callback from platform data
We no longer have users for the set_hs_extmute callback which has been
replaced by hs_extmute_gpio so the codec driver can handle the external
mute if it is needed by the board.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:26 -04:00
Peter Ujfalusi eb775d38e0 ARM: OMAP/ASoC: Zoom2: Let the codec to handle the hs_extmute GPIO
Remove the use of set_hs_extmute callback and let the codec driver to
handle the extmute GPIO.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:25 -04:00
Peter Ujfalusi 281ecd1611 ASoC: twl4030: Move hs_extmute GPIO handling to driver
The external mute (if it is in use) is handled by a GPIO line. Prepare to
remove the set_hs_extmute callback and replace it with:
hs_extmute_gpio: the GPIO number to use for external mute

When the users of set_hs_extmute has been converted the callback can be removed.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:24 -04:00
Peter Ujfalusi 7902621958 Input: twl4030-vibra: Support for DT booted kernel
Add support when the kernel has been booted with DT blob. In this case the
pdata is NULL, we need to reach up to the core node and check if the codec
part has been enabled to determine if we need to coexist with the codec or
not.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:18:24 -04:00
Peter Ujfalusi 7bf7ff6f57 mfd: twl4030-audio: Add DT support
Support for loading the twl4030 audio module via devicetree.
Sub devices for codec and vibra will be created as mfd devices once the
core MFD driver is loaded when the kernel is booted with a DT blob.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:15:04 -04:00
Peter Ujfalusi 5382a0171f dt: Add empty of_find_node_by_name() function
This commit adds an empty of_find_node_by_name() function for !CONFIG_OF
builds.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22 11:15:03 -04:00