Dan Carpenter [Wed, 28 Mar 2012 06:57:02 +0000 (09:57 +0300)]
ALSA: asihpi - fix return type of hpios_locked_mem_alloc()
This function returns zero or -ENOMEM, but because it's type is u16, the
-ENOMEM gets changed to 65524. None of the callers care, but lets fix
it anyway as a cleanup.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 22 Mar 2012 13:36:50 +0000 (14:36 +0100)]
ALSA: hda/realtek - Fix ADC assignment with a shared HP/Mic pin
The recent Realtek driver tries to assign an extra input via the
headphone plug when only a single input source is found. The code
worked on Samsung Q1, but it broke ASUS 1015 where the mic is a
digital-mic and only a specific ADC works.
This patch fixes the assignment of ADC in the shared mic/hp case.
Instead of assuming the single ADC at first, reduce the ADCs after
trying to assign both mic and HP pins.
Takashi Iwai [Wed, 21 Mar 2012 07:06:05 +0000 (08:06 +0100)]
Merge tag 'asoc-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
Last minute ASoC updates for 3.4
There's a couple of small features here that were added late on but have
been in -next in my tree and some bug fixes. The wm_hubs stuff is
actually bug fixes - the stuff that's currently in 3.4 is a half way
house between the two solutions that the latest change allows the
machine to select between.
Mark Brown [Mon, 19 Mar 2012 17:32:06 +0000 (17:32 +0000)]
ASoC: wm8994: Provide VMID mode control and fix default sequence
The optimal management of VMID depends on a number of factors which vary
dynamically at runtime, for example the connection to a system docking
station. In some circumstances it is desirable to keep VMID enabled all
the time, in others it is desirable to aggressively power it up and down.
Provide a callback allowing machine driver to configure either the normal
power up/down mode (WM8994_VMID_MODE_NORMAL) or to maintain VMID even
when idle (WM8994_VMID_MODE_FORCE). This callback, wm8994_vmid_mode(),
should be called with the CODEC lock.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Daniel Mack [Mon, 19 Mar 2012 08:12:53 +0000 (09:12 +0100)]
ASoC: pxa-ssp: atomically set stream active masks
PXA's SSP engine fails to take its current channel phase into account
when enabling a stream while the engine is already running. This
results in randomly swapped left/right channels on either the record
or the playback side, depending on which one was enabled first.
The following patch fixes this by factoring out the bit field
modifications in question to a separate function that pauses the
engine temporarily, modifies the bits and kicks it off again
afterwards. Appearantly, a transition of SSCR0_SSE syncs both
directions properly.
The patch has been rolled out to quite a number of devices over the
last weeks and seems to fix the issue reliably.
Signed-off-by: Daniel Mack <zonque@gmail.com> Reported-and-tested-by: Sven Neumann <s.neumann@raumfeld.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
Timur Tabi [Fri, 16 Mar 2012 21:32:52 +0000 (16:32 -0500)]
ASoC: fsl: p1022ds: tell the WM8776 codec driver that it's the master
The WM8776 codec driver requires the machine driver to set one of the
SND_SOC_DAIFMT_CBx_xxx values. The P1022DS machine driver should be setting
SND_SOC_DAIFMT_CBM_CFM, but since that value was zero, no one noticed.
Commit 75d9ac46 ("ASoC: Allow DAI formats to be specified in the
dai_link"), however, changed the value of SND_SOC_DAIFMT_CBM_CFM from zero
to a non-zero value, which means that it now needs to be specifically set
by the machine driver.
We also set SND_SOC_DAIFMT_NB_NF, for the same reason.
Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
Sangsu Park [Fri, 16 Mar 2012 06:40:53 +0000 (15:40 +0900)]
ASoC: Samsung: Added to support mono recording
The dma size will be changed by requested number of
channel(mono/stereo) from platform. For mono recording,
channels_min value should be 1.
Signed-off-by: Sangsu Park <sangsu4u.park@samsung.com> Signed-off-by: Sangbeom Kim <sbkim73@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Wed, 14 Mar 2012 20:18:49 +0000 (20:18 +0000)]
ASoC: core: Fix obscure leak of runtime array
We're currently not freeing card->rtd in cases where the card is
unregistered before being instantiated - convert it to devm_kzalloc() to
make sure that happens.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
Takashi Iwai [Thu, 15 Mar 2012 06:37:22 +0000 (07:37 +0100)]
Merge tag 'asoc-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into topic/asoc
Linus decided to go for another week so here's a few more updates - a
mixed bag here, a few minor diagnostic tweaks, some driver enhancements
and the dmaengine conversion for ep93xx drivers which was tested a while
ago and just waiting for a signoff.
Takashi Iwai [Tue, 13 Mar 2012 14:55:43 +0000 (15:55 +0100)]
ALSA: pcm - Avoid GFP_ATOMIC in snd_pcm_link()
GFP_ATOMIC is used in snd_pcm_link() just because the kmalloc is
called inside a lock. Since this function isn't too critical for
speed and is rarely called in practice, better to allocate the chunk
at first before spinlock and free it in error paths, so that
GFP_KERNEL can be used.
Mark Brown [Wed, 14 Mar 2012 19:48:43 +0000 (19:48 +0000)]
ALSA: pcm: Constify the list in snd_pcm_hw_constraint_list
Allows the constraint lists to be declared const by drivers which seems
reasonable; there's plenty of other constification we could do if we were
being complete but this was easy and quick.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Fabio Estevam [Mon, 12 Mar 2012 22:48:49 +0000 (19:48 -0300)]
ASoC: mx27vis-aic32x4: Convert it to platform driver
Convert mx27vis-aic32x4 to platform driver.
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Tested-by: Javier Martin <javier.martin@vista-silicon.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Anssi Hannula [Tue, 13 Mar 2012 15:43:02 +0000 (17:43 +0200)]
ALSA: hda - fix printing of high HDMI sample rates
A previous commit af65cbf296 (ALSA: hdmi: fix printout of SAD sampling
rates) fixed the sample rates shown in /proc/asound/cardX/eldY and
kernel log to not be entirely wrong. However, a missing rate from the
array added in the patch causes HDMI rates 88.2 kHz, 96 kHz, 176.4 kHz,
and 192 kHz to be shown as 96 kHz, 176.4 kHz, 192 kHz, and 384 kHz,
respectively.
Fix the reporting by adding the ALSA rate 64 kHz into the conversion
array between 48 kHz and 88.2 kHz.
Takashi Iwai [Tue, 13 Mar 2012 06:55:10 +0000 (07:55 +0100)]
ALSA: hda - Add expose_enum_ctl flag to snd_hda_add_vmaster_hook()
Since it's not always safe to assume that the vmaster hook is purely the
mute-LED control, add the flag indicating whether to expose the mute-LED
enum control or not. Currently, conexant codec sets this off for non-HP
laptops where EAPD may be used really as EAPD.
Takashi Iwai [Mon, 12 Mar 2012 15:59:58 +0000 (16:59 +0100)]
ALSA: hda - Add "Mute-LED Mode" enum control
Create snd_hda_add_vmaster_hook() and snd_hda_sync_vmaster_hook()
helper functions to handle the mute-LED in vmaster hook more
commonly. In the former function, a new enum control "Mute-LED Mode"
is added. This provides user to choose whether the mute-LED should be
turned on/off explicitly or to follow the master-mute status.
Reviewed-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mika Westerberg [Mon, 5 Mar 2012 13:02:14 +0000 (14:02 +0100)]
ASoC: dmaengine_pcm: Reset pointer position when starting a stream
Otherwise a wrong position will be reported after restarting a stream and the
first few samples might be skipped.
Signed-off-by: Mika Westerberg <mika.westerberg@iki.fi> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Mon, 12 Mar 2012 16:31:50 +0000 (16:31 +0000)]
ASoC: wm8994: Prevent ABBA deadlock with CODEC and accdet mutexes
Currently we can the accdet mutex from within DAPM when updating the device
state which means we take accdet then the CODEC mutex but we also do the
locking the other way around when responding to the jackdet IRQ. Move all
the jackdet use of the CODEC mutex out of the accdet lock to avoid this.
Since all the DAPM interactions depend only on a single threaded IRQ this
is still serialised.
The locking improvements in 3.5 allow a better solution there.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Mon, 12 Mar 2012 11:38:51 +0000 (12:38 +0100)]
ALSA: hda - Add EAPD control to Conexnat auto-parser
Added the vmaster hook for controlling EAPD dynamically to Conexant
auto-parser. When the Master is muted, EAPDs are turned off as well.
This will fix the missing mute-LED control on some machines in
addition to the more power-saving in the auto-parser mode.
Takashi Iwai [Mon, 12 Mar 2012 11:35:27 +0000 (12:35 +0100)]
ALSA: hda - Rewrite the mute-LED control with vmaster hook for ALC269
We've had ugly static handling of the mute-LED with a powersave hook
for ALC269 HP laptops just like done in patch_sigmatel.c. This is now
rewritten with the new vmaster hook and a fixup code.
For that, the new fixup action, ALC_FIXUP_ACT_BUILD, is introduced.
It's called after build_controls is called. The reason of this new
action is that vmaster hook must be added at this stage (not in init
or probe).
Takashi Iwai [Mon, 12 Mar 2012 11:30:22 +0000 (12:30 +0100)]
ALSA: hda - Rewrite the mute-LED hook with vmaster hook in patch_sigmatel.c
The mute-LED is controlled in patch_sigmatel.c by (ab-)using the
powersave hook. This can be now rewritten with the vmaster hook
instead, which is much simpler and can work even without
CONFIG_SND_HDA_POWER_SAVE kconfig.
A drawback is that the mute-LED corresponds _only_ to the Master mixer
switch instead of checking the whole DACs. But usually this shouldn't
be a big problem as PA enables the mixer elements accordingly.
Also, this patch changes the code to create vmaster always even on
STAC9200 and STAC925x. The former "Master" on these chips are renamed
as "PCM" now.
Peter Ujfalusi [Fri, 9 Mar 2012 08:26:03 +0000 (10:26 +0200)]
ASoC: OMAP: Build config cleanup for McBSP
The McBSP driver stack has been moved, and rewritten resulting a single
driver - selected by CONFIG_SND_OMAP_SOC_MCBSP. There is no longer need to
have CONFIG_OMAP_MCBSP anymore.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonoie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Fri, 9 Mar 2012 08:23:27 +0000 (10:23 +0200)]
ARM: OMAP: Remove CONFIG_OMAP_MCBSP references
The McBSP driver stack has been moved to ASoC. The CONFIG_OMAP_MCBSP will
be removed since the CONFIG_SND_OMAP_SOC_MCBSP will trigger to build the
McBSP (audio) drivers.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
We are setting SNDRV_PCM_HW_PARAM_BUFFER_SIZE based on
SNDRV_PCM_HW_PARAM_CHANNELS, not vice versa. This bug didn't
have much impact because the rules are evaluated multiple times
by the core, and intended value got set eventually.
Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Thu, 8 Mar 2012 11:34:16 +0000 (13:34 +0200)]
ASoC: omap-mcbsp: Correct clock muxing for CLKR/FSR signals
Remove the no longer valid check for McBSP1 regarding to signal mux
selection (on OMAP4 McBSP4 has 6 pin setup).
Only clear the srgr2, pcr0 register configuration if the requested clock
configuration will actually going to touch it. In this way we can avoid
issues if the CLKR/FSR mux has been configured after the clock selection.
We are going to check for the valid McBSP port in the
omap_mcbsp_6pin_src_mux() function based on the validity of the mux_signal
callback (which is only valid for ports having 6 pin setup).
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Thu, 8 Mar 2012 09:01:37 +0000 (11:01 +0200)]
ASoC: omap-mcbsp: Single function CLKR/FSR source mux configuration
Use single function for the CLKR/FSR mux configuration.
OMAP2/3 has 6 pin configuration on McBSP1 instance, while on OMAP4
McBSP4 instance have the 6 pin configuration so the omap2_mcbsp1_mux_* is
not correct name for all support OMAP versions
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Thu, 8 Mar 2012 08:40:08 +0000 (10:40 +0200)]
ARM/ASoC: OMAP McBSP: Move remainig defines from arch to ASoC header
Clock signal muxing, and functional clock related defines are only needed
in ASoC drivers.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Acked-by: Mark Brown <broonoie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
On OMAP2/3 McBSP1 port has 6 pin setup, while on OMAP4 the port is McBSP4.
Implement the CLKR/FSR clock mux selection for OMAP4, and make sure that
we add the correct callback for the correct port across supported OMAP
versions.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Wed, 7 Mar 2012 09:15:37 +0000 (11:15 +0200)]
ASoC: omap McBSP: Clear rx_irq at probe time for OMAP4
On OMAP4 we have one interrupt line per McBSP port.
At probe time tx, and rx irq value will be -ENXIO,
and only the tx irq will get corrected.
In omap_mcbsp_request if the rx_irq is not 0 we proceed,
and try to request the interrupt, which will fail on
OMAP4 (rx_irq == -6).
To avoid this error, clear the rx_irq at probe time
on OMAP4.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Mon, 5 Mar 2012 09:32:27 +0000 (11:32 +0200)]
ASoC: omap-mcbsp: When closing the port select PRCM source for CLKS signal
If external source for the CLKS signal selection kept after the port is no
longer in use the system might refuse to go suspend.
There is also a chance that the external clock is not running when next
time the McBSP port is started which can result errors when we try to
access McBSP registers.
Reset the CLKS source back to PRCM source unconditionally.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Mon, 5 Mar 2012 09:27:40 +0000 (11:27 +0200)]
ASoC: omap-mcbsp: Configure wakeup in later phase
Configure the WAKEUPEN register at the same time we configure the rest of
the McBSP registers.
In case of OMAP3+, if the sysclock has been reconfigured we are going to
disable McBSP for the duration of the clock change, which will reset the
McBSP registers. The WAKEUPEN register need to be configured later, so
the changes will be effective during runtime.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicrocom> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Thu, 23 Feb 2012 13:40:55 +0000 (15:40 +0200)]
ASoC: omap: mcbsp: Remove redundant checks for the st_data pointer
The parent functions of omap_st_start/stop also checks the validity of the
st_data pointer so we do not need to do it again inside of omap_st_start/stop
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Thu, 23 Feb 2012 13:38:37 +0000 (15:38 +0200)]
ASoC: omap: mcbsp: Use uniform st_data pointer initialization
In this way we can save few lines, and have uniform way of initializing the
st_data in all functions.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Tue, 14 Feb 2012 13:41:29 +0000 (15:41 +0200)]
ASoC: omap-mcbsp: Simplify DMA configuration
Configure the DMA request line, port address, and stream name at
probe time instead of every time we start a stream.
These settings are static in the system.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Tue, 14 Feb 2012 13:23:15 +0000 (15:23 +0200)]
ASoC: omap-mcbsp: Merge the omap_mcbsp_data into omap_mcbsp structure
Since the drivers has been merged, merge the two structures together.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Tue, 14 Feb 2012 12:52:42 +0000 (14:52 +0200)]
ASoC: omap-mcbsp: Cleanup of module probe/remove code
Use devm_* where it is possible to save on cleanup path.
Start merging the two mcbsp file content.
Move pm_runtime_enable/disable calls to ASoC probe, remove from module
probe/remove time.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Mon, 13 Feb 2012 14:26:54 +0000 (16:26 +0200)]
ASoC: OMAP McBSP: Remove redundant accessors
We no longer need accessor functions for max_tx/rx_threshold, dma_op_mode
or for the FIFO size.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Mon, 13 Feb 2012 13:36:49 +0000 (15:36 +0200)]
ASoC: OMAP: mcbsp.h: Clean up bit definitions
Use BIT() for bit position, correct field definition by adding mask to
them, and also adding the missing spaces around '<<'
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Tue, 14 Feb 2012 16:20:58 +0000 (18:20 +0200)]
ASoC: omap-mcbsp: Create a single driver for McBSP
The OMAP McBSP driver stack used to contain two different
drivers. One of them was used as kind low-level access to
the IP, while the other driver was the ASoC DAI driver.
There were global, shared structures, in different places,
the McBSP instances are reffered with id numbers (sometimes
0 based, in other cases 1 based id numbers).
Create one single driver for OMAP McBSP with name: omap-mcbsp.
Convert the old omap-mcbsp driver initially to be a library
for the omap-mcbsp DAI driver. With this change we can get rid
of all global variables, structures.
Further cleanup is coming...
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Move most of the content of the plat/mcbsp.h header file under
sound/soc/omap/ to help further cleanups.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Peter Ujfalusi [Thu, 26 Jan 2012 10:38:31 +0000 (12:38 +0200)]
ARM: OMAP: mcbsp: Convert core driver to proper platform driver
Convert the plat-omap/mcbsp.c driver to be proper platform driver.
Remove the omap_mcbsp_init function call which was called from
mach-omap1/2/mcbsp.c to register the platform driver for the just
created platform device in the same function.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Takashi Iwai [Mon, 12 Mar 2012 11:18:37 +0000 (12:18 +0100)]
ALSA: Add a hook capability to vmaster controls
This patch adds a hook to vmaster control to be called at each time
when the master value is changed. It'd be handy for an additional
mute LED control following the Master switch, for example.
Mark Brown [Mon, 12 Mar 2012 10:33:34 +0000 (10:33 +0000)]
ASoC: Revert widget I/O locking for 3.4
The widget locking depends on some of the other locking changes which
are queued up for 3.5 not 3.4 so revert the locking changes and reapply
them in 3.5.
Takashi Iwai [Fri, 9 Mar 2012 16:51:10 +0000 (17:51 +0100)]
ALSA: hda - Initialize vmaster slave volumes
When the driver is changed to use vmaster or a new slave element is
added by the improvement of the parser code, user may face often the
silent output because of the muted slave mixer although Master volume
is properly set. And they complain. And I get upset.
Although such a mixer element should be initialized via "alsactl init",
it'd be more user-friendly if the known output slaves are unmuted and
set to 0dB so that user can control the volume only with Master as
default. Since Master is still set muted as default even with this
change, no risk of the speaker blow up, too.
Ashish Chavan [Fri, 9 Mar 2012 08:21:30 +0000 (13:51 +0530)]
ASoC: da7210: Remove extra registers from defaults list
This patch removes following registers from reg map defaults,
- Registers which are currently not used by driver
- Non existing registers
- Volatile registers
Signed-off-by: Ashish Chavan <ashish.chavan@kpitcummins.com> Signed-off-by: David Dajun Chen <dchen@diasemi.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Shawn Guo [Thu, 8 Mar 2012 16:59:46 +0000 (00:59 +0800)]
ASoC: fsl: check property 'compatible' for the machine name
Check /compatible rather than /model to determine the machine name.
The p1022ds older device trees get a different /model from the new
ones, while /compatible is consistent there, so checking /compatible
will save the bother of detecting older p1022ds device trees.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Timur Tabi <timur@freescale.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Ashish Chavan [Thu, 8 Mar 2012 13:34:56 +0000 (19:04 +0530)]
ASoC: da7210: Update for using I2C regmap
Current DA7210 driver has I2C support using older register cache
methods. This patch updates it for latest regmap framework.
This has been tested on DA7210 EVB with Samsung SMDK6410 board.
Signed-off-by: Ashish Chavan <ashish.chavan@kpitcummins.com> Signed-off-by: David Dajun Chen <dchen@diasemi.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Adrian Knoth [Thu, 8 Mar 2012 14:38:04 +0000 (15:38 +0100)]
ALSA: hdspm - Provide ioctl_compat
snd_hdspm uses its own ioctls to acquire config- and status information.
Expose the corresponding ioctl handler via ioctl_compat, so that 32bit
applications can use it on 64bit kernels.
Signed-off-by: Adrian Knoth <adi@drcomp.erfurt.thur.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Fabio Estevam [Wed, 7 Mar 2012 18:19:57 +0000 (15:19 -0300)]
ASoC: imx: imx-audmux: Fix section mismatch
Fix the following section mismatch warning:
WARNING: vmlinux.o(.data+0x35be8): Section mismatch in reference from the variable imx_audmux_driver to the function .init.text:imx_audmux_probe()
The variable imx_audmux_driver references
the function __init imx_audmux_probe()
If the reference is valid then annotate the
variable with __init* or __refdata (see linux/init.h) or name the variable:
*_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown [Tue, 6 Mar 2012 23:58:22 +0000 (23:58 +0000)]
ASoC: dapm: Only lock CODEC for I/O if not using regmap
If we do use regmap then regmap will take care of things for us. We
actually already have this check at a higher level for the current
users but this makes sure we do the right thing in the future too if
we need to.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
Takashi Iwai [Wed, 7 Mar 2012 09:58:39 +0000 (10:58 +0100)]
ALSA: hda - Set codec to D3 forcibly even if not used
We've seen a problem with a pop-noise at suspend/resume on a HP
machine with ALC269, and it turned out to be an issue that the
controller going to D3 while the codec is unused.
When the device is once suspended and resumed and kept unused, the
driver doesn't initialize the codecs. Instead, the codec chips are
set up dynamically at the first usage. Now, suppose the device going
to suspend again before the codec is set up. The controller is turned
off to D3 while the codec chips are untouched. This caused a pop
noise because the codec chip might have been turned on implicitly by
the hardware.
As a workaround, the codec chip needs to be set to D3 when going to
suspend no matter whether it was used or not. Also, for making it
happening, the controller has to be always set up in the resume path.
Takashi Iwai [Wed, 7 Mar 2012 07:37:19 +0000 (08:37 +0100)]
ALSA: hda/realtek - Reuse init_hook for ALC269VB coef setup
Move the currently unused spec->init_hook at the beginning of the init
sequence so that the recently added ALC269VB coef setup can be put
there. The alc_init() is again clean without an ugly check.
Kailang Yang [Wed, 7 Mar 2012 07:25:20 +0000 (08:25 +0100)]
ALSA: hda/realtek - Apply the coef-setup only to ALC269VB
The coef setup in alc269_fill_coef() was designed only for ALC269VB
model, and this has some bad effects for other ALC269 variants, such
as turning off the external mic input. Apply it only to ALC269VB.
Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Stephen Warren [Tue, 6 Mar 2012 19:13:07 +0000 (12:13 -0700)]
ASoC: tegra: Remove unused variable
Fixes the following warning:
sound/soc/tegra/tegra_alc5632.c: In function 'tegra_alc5632_asoc_init':
sound/soc/tegra/tegra_alc5632.c:118:6: warning: unused variable 'ret' [-Wunused-variable]
Signed-off-by: Stephen Warren <swarren@wwwdotorg.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Tue, 6 Mar 2012 13:04:16 +0000 (14:04 +0100)]
Merge tag 'asoc-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into topic/asoc
A few more ASoC updates, the main one is the move of the audmux driver
from arch/arm into sound/soc. There's also some general driver specific
tweaks and fixes.
Richard Zhao [Mon, 5 Mar 2012 14:31:04 +0000 (22:31 +0800)]
ASoC: fsl: add dt support for imx-audmux
It adds device tree probe support for imx-audmux driver.
Signed-off-by: Richard Zhao <richard.zhao@linaro.org> Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Marton Balint [Mon, 5 Mar 2012 20:33:23 +0000 (21:33 +0100)]
ALSA: hda - add quirk to detect CD input on Gigabyte EP45-DS3
My CD input got lost in commit 68ef0561efe494143516df38c03a16b837b8e79c.
Raymond helped me to add the necessary pin fixup to make it appear again. In
fact, this is basically his patch. It fixes alsa bug #5541.
Shawn Guo [Mon, 5 Mar 2012 14:30:56 +0000 (22:30 +0800)]
ASoC: imx: add an explicit Kconfig option for imx-ssi driver
Currently ASoC:imx uses menuconfig option SND_IMX_SOC selects imx-ssi
driver, and it works because all the machine driver covered by the
menuconfig need to build imx-ssi driver in. However, it will not work
any more if we have a imx based machine driver going into the menuconfig
while working with fsl_ssi driver (sound/soc/fsl/fsl_ssi.c) rather than
imx-ssi one.
The patch adds an explicit Kconfig option SND_SOC_IMX_SSI for imx-ssi
driver, so that it can be selected independently from the menuconfig
option SND_IMX_SOC.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Shawn Guo [Mon, 5 Mar 2012 14:30:55 +0000 (22:30 +0800)]
ASoC: imx: separate imx-pcm bits from imx-ssi driver
Currently the imx-ssi.c[h] accommodates the imx-pcm common bits which
are shared between imx-pcm-dma-mx2 and imx-pcm-fiq drivers. It assumes
that imx-pcm-dma-mx2 and imx-pcm-fiq will always be used together with
imx-ssi driver. However this becomes untrue when we see that driver
sound/soc/fsl/fsl_ssi could possibly work with imx-pcm-dma-mx2 too.
The patch moves the imx-pcm common bits from imx-ssi.c[h] into new
files imx-pcm.c[h], and let imx-pcm-dma-mx2 and imx-pcm-fiq drivers
build it in, so that imx-pcm-dma-mx2 can work with no dependency on
imx-ssi driver.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Shawn Guo [Mon, 5 Mar 2012 14:30:53 +0000 (22:30 +0800)]
ASoC: imx: move audmux driver into sound/soc/imx
As audmux becomes a platform driver and its callers are all ASoC
machine drivers, there is no reason to keep it in arch folder, so
move it to sound/soc/imx.
One bonus point would be those ASoC machine drivers stop including
mach/audmux.h, since it's been moved to sound/soc/imx/imx-audmux.h.
This should be a move to the right direction in terms of single kernel
image goal.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Shawn Guo [Mon, 5 Mar 2012 14:30:50 +0000 (22:30 +0800)]
ASoC: imx: move phycore audmux call into ASoC machine driver
It moves phycore audmux configuration call from board file into ASoC
machine driver phycore-ac97 to ease converting audmux into a platform
driver later.
It moves phycore audmux configuration call from board file into ASoC
machine driver phycore-ac97, so that it gets aligned with wm1133-ev1
and mx27vis-aic32x4, and more importantly it will ease the moving of
audmux into sound/soc/imx as a platform driver later.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Shawn Guo [Mon, 5 Mar 2012 14:30:49 +0000 (22:30 +0800)]
ASoC: imx: move eukrea audmux call into ASoC machine driver
It moves eukrea audmux configuration call from board file into ASoC
machine driver eukrea-tlv320, so that it gets aligned wm1133-ev1 and
mx27vis-aic32x4, and more importantly it will ease the moving of audmux
into sound/soc/imx as a platform driver later.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Mon, 5 Mar 2012 14:07:33 +0000 (15:07 +0100)]
Merge tag 'asoc-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into topic/asoc
This has been a very active release for ASoC, as well as the usual raft
of bugfixes and driver updates there's quite a few framework enhancements.
Most are either small or are laying the groundwork for user visible
features (especially dynamic PCM), the most directly visible change is
the dmaengine library. There's also a bunch of regmap API enhancements
pulled into the tree so that either the framework or drivers can take
advantage of the new features.
Changes include:
- Support for widgets not associated with a CODEC, an important part of
the dynamic PCM framework.
- A library factoring out the common code shared by dmaengine based DMA
drivers contributed by Lars-Peter Clausen. This will save a lot of
code and make it much easier to deploy enhancements to dmaengine.
- Support for binary controls, used for providing runtime configuration
of algorithm coefficients.
- A new DAPM widget type for regulator supplies allowing drivers for
devices that can power down unused supplies while active to do without
any per-driver code.
- DAPM widgets for DAIs, initially giving a speed boost for playback
startup and shutdown and also the basis for CODEC<->CODEC DAI link
support.
- Support for specifying the number of significant bits on audio
interfaces, useful for allowing applications to know how much effort to
put into generating data for a larger sample format.
- Conversion of the FSI driver used on some SH processors to DMAEngine.
- New CODEC drivers for Maxim MAX9768 and Wolfson Microelectronics WM2200.
Pavel Hofman [Fri, 2 Mar 2012 21:09:39 +0000 (22:09 +0100)]
ALSA: ice1724 - constrain runtime rates for locked internal rate
The driver already defines control "Multi Track Rate Locking" which
locks the card at current rate if switched to internal clock. This patch
limits the runtime rates to this rate only, allowing proper reporting
of the card capabilities, and e.g. automatic rate conversion by the plug
plugin to the currently locked rate.
Signed-off-by: Pavel Hofman <pavel.hofman@ivitera.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>