Takashi Iwai [Sun, 18 Mar 2012 17:22:33 +0000 (18:22 +0100)]
Merge branch 'topic/misc' into for-linus
Takashi Iwai [Sun, 18 Mar 2012 17:22:30 +0000 (18:22 +0100)]
Merge branch 'topic/hda' into for-linus
Takashi Iwai [Fri, 16 Mar 2012 15:09:03 +0000 (16:09 +0100)]
ALSA: hda - Fix build with CONFIG_PM=n
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 16 Mar 2012 08:54:00 +0000 (09:54 +0100)]
ALSA: au88x0 - Avoid possible Oops at unbinding
The irq handler must check whether the MPU401 instance is still alive.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 15 Mar 2012 15:14:38 +0000 (16:14 +0100)]
ALSA: usb-audio - Fix build error by consitification of rate list
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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>
Takashi Iwai [Wed, 14 Mar 2012 07:20:20 +0000 (08:20 +0100)]
ALSA: hda - Fix build of patch_sigmatel.c without CONFIG_SND_HDA_POWER_SAVE
Now the mute-LED is controlled without powersave hack, and the ifdefs must
be removed.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Cc: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Cc: stable@kernel.org
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 13 Mar 2012 07:07:41 +0000 (08:07 +0100)]
ALSA: ymfpci - Fix legacy registers on S3/S4 resume
We need to resume two legacy registers to recover MIDI/FM functionality
on S3/S4 resume, too.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jeffrin Jose [Wed, 7 Mar 2012 17:27:39 +0000 (22:57 +0530)]
ALSA: control - Fixe a trailing white space error
Fixed a trailing white space error detected
in sound/core/control.c by checkpatch.pl script.
Signed-off-by: Jeffrin Jose <ahiliation@yahoo.co.in>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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).
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 12 Mar 2012 11:25:03 +0000 (12:25 +0100)]
ALSA: hda - Return the created kcontrol in __snd_hda_add_vmaster()
It'll be used for adding hooks in later patches.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 9 Mar 2012 16:41:53 +0000 (17:41 +0100)]
ALSA: core - Refactor card id string creation code
The code to handle the card id string is fairly messy, so here is a
tidy up.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 7 Mar 2012 08:05:15 +0000 (09:05 +0100)]
Merge branch 'fix/hda' into topic/hda
Conflicts:
sound/pci/hda/patch_realtek.c
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>
Takashi Iwai [Tue, 6 Mar 2012 13:02:32 +0000 (14:02 +0100)]
ALSA: hda - Add Gigabyte GA-MA790X to the beep whitelist
Its BIOS suppresses the PC beep although it's implemented.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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.
Signed-off-by: Marton Balint <cus@passwd.hu>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
David Henningsson [Mon, 5 Mar 2012 10:38:46 +0000 (11:38 +0100)]
ALSA: hda - fix broken automute/autoswitch for Realtek
The recent addition of volume-knob widget in the auto-parser broke
automute/autoswitch for some Realtek devices.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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>
Takashi Iwai [Sun, 4 Mar 2012 15:13:58 +0000 (16:13 +0100)]
Merge tag 'asoc-3.3' of git://git./linux/kernel/git/broonie/sound into for-linus
A driver specific fix that wasn't noticed as the OpenMoko guys have been
stuck on 2.6.39 for a very long time now and are just starting to catch
up again.
Denis 'GNUtoo' Carikli [Sun, 26 Feb 2012 18:21:54 +0000 (19:21 +0100)]
ASoC: neo1973: fix neo1973 wm8753 initialization
The neo1973 driver had wrong codec name which prevented the "sound card"
from appearing.
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@no-log.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
Takashi Iwai [Fri, 2 Mar 2012 08:00:33 +0000 (09:00 +0100)]
Merge branch 'fix/hda' into topic/hda
Speaker-Out renames are merged.
Conflicts:
sound/pci/hda/patch_realtek.c
Takashi Iwai [Thu, 1 Mar 2012 17:14:41 +0000 (18:14 +0100)]
ALSA: hda - Kill hyphenated names
Kill hyphens from "Line-Out" name strings, as suggested by Mark Brown.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 1 Mar 2012 13:17:07 +0000 (14:17 +0100)]
Merge tag 'asoc-3.3' of git://git./linux/kernel/git/broonie/sound into for-linus
A small fix for the SSI driver and a fix for system shutdown with modern
devices. Most of the modern devices will never get shut down normally
with a visible kernel log as the systems they're in tend not to shut
down often and when they do it's usually in form factors that don't have
a user visible console.
Takashi Iwai [Mon, 20 Feb 2012 11:30:59 +0000 (12:30 +0100)]
ALSA: hda/conexant - Clear unsol events on unused pins
It seems that Lenovo machines (or codec chip itself?) leave the unsol
event tags and the enablement-flag from other pins bogusly even on the
unused pins. Although this shouldn't be too critical, it's better to
clear them up sanely.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 27 Feb 2012 14:00:58 +0000 (15:00 +0100)]
ALSA: hda - Add a fake mute feature
Some codecs don't supply the mute amp-capabilities although the lowest
volume gives the mute. It'd be handy if the parser provides the mute
mixers in such a case.
This patch adds an extension amp-cap bit (which is used only in the
driver) to represent the min volume = mute state. Also modified the
amp cache code to support the fake mute feature when this bit is set
but the real mute bit is unset.
In addition, conexant cx5051 parser uses this new feature to implement
the missing mute controls.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=42825
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 29 Feb 2012 08:41:17 +0000 (09:41 +0100)]
ALSA: hda - Always set HP pin in unsol handler for STAC/IDT codecs
A bug report with an old Sony laptop showed that we can't rely on BIOS
setting the pins of headphones but the driver should set always by
itself.
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 28 Feb 2012 20:49:55 +0000 (21:49 +0100)]
ALSA: hda - Enable docking-station SPDIF for Thinkpad
The docking-station of Thinkpad X200 & co supports also an SPDIF output,
and the corresponding pin 0x1c has to be enabled for using it.
Reported-and-tested-by: Sebastian Glita <sebastian.glita@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 28 Feb 2012 10:58:40 +0000 (11:58 +0100)]
ALSA: hda - Add position_fix=4 (COMBO) option
This patch adds a new position_fix option value, 4, as a combo mode
to use LPIB for playbacks and POSBUF for captures. It's the way
recommended by Intel hardware guys.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Vitaliy Kulikov [Mon, 27 Feb 2012 22:47:37 +0000 (16:47 -0600)]
ALSA: hda - Fix audio playback support on HP Zephyr system
Enables port E of IDT 92HD91 codec as output and sets correct output
phase between ports E and D and high pass filter.
Signed-off-by: Vitaliy Kulikov <Vitaliy.Kulikov@idt.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Alban Bedel [Sat, 25 Feb 2012 15:15:57 +0000 (16:15 +0100)]
ALSA: azt3328 - Fix NULL ptr dereference on cards without OPL3
opl3->private_data was set even if opl3 could not be created.
Signed-off-by: Alban Bedel <albeu@free.fr>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Sat, 25 Feb 2012 10:13:16 +0000 (11:13 +0100)]
ALSA: hda/realtek - Fix resume of multiple input sources
When there are multiple input sources, the driver wrongly overwrites with
the value of the last input source on other slots at resume. Thus the
primary input source may be shown wrongly.
Reported-and-tested-by: Julian Sikorski <belegdol@gmail.com>
Cc: <stable@kernel.org> [v3.1+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Torsten Schenk [Fri, 24 Feb 2012 20:34:22 +0000 (21:34 +0100)]
ALSA: snd-usb-6fire: Select missing SND_VMASTER option in Kconfig
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Javier Martin [Thu, 23 Feb 2012 14:43:18 +0000 (15:43 +0100)]
ASoC: i.MX SSI: Fix DSP_A format.
According to i.MX27 Reference Manual (p 1593) TXBIT0 bit selects
whether the most significant or the less significant part of the
data word written to the FIFO is transmitted.
As DSP_A is the same as DSP_B with a data offset of 1 bit, it
doesn't make any sense to remove TXBIT0 bit here.
Signed-off-by: Javier Martin <javier.martin@vista-silicon.com>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
Masanari Iida [Thu, 23 Feb 2012 14:23:06 +0000 (23:23 +0900)]
ALSA: ctxfi: Fix typo in ctvmem.c
Correct spelling "virtural" to "virtual" in
sound/pci/ctxfi/ctvmem.c
Signed-off-by: Masanari Iida <standby24x7@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mark Brown [Wed, 22 Feb 2012 15:52:56 +0000 (15:52 +0000)]
ASoC: dapm: Check for bias level when powering down
Recent enhancements in the bias management means that we might not be
in standby when the CODEC is idle and can have active widgets without
being in full power mode but the shutdown functionality assumes these
things. Add checks for the bias level at each stage so that we don't
do transitions other than the ON->PREPARE->STANDBY->OFF ones that the
drivers are expecting.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
Wu Fengguang [Thu, 23 Feb 2012 07:07:44 +0000 (15:07 +0800)]
ALSA: hda - add id for Atom Cedar Trail HDMI codec
[the order sorted by tiwai]
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Torsten Schenk [Wed, 22 Feb 2012 14:21:30 +0000 (15:21 +0100)]
ALSA: snd-usb-6fire: add analog input volume control
Add a stereo volume control for analog input channel pair 1/2.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Torsten Schenk [Wed, 22 Feb 2012 14:21:23 +0000 (15:21 +0100)]
ALSA: snd-usb-6fire: add mute control for analog outputs
Add a mute control for every analog output channel.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Torsten Schenk [Wed, 22 Feb 2012 14:21:12 +0000 (15:21 +0100)]
ALSA: snd-usb-6fire: add individual volume control for analog channels
Add a stereo volume control for every analog output pair 1/2, 3/4, 5/6.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Torsten Schenk [Wed, 22 Feb 2012 14:20:54 +0000 (15:20 +0100)]
ALSA: snd-usb-6fire: add tlv to controls
Remove the soft log-conversion and add a dB scale according to
the DAC documentation instead.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Torsten Schenk [Wed, 22 Feb 2012 14:20:45 +0000 (15:20 +0100)]
ALSA: snd-usb-6fire: remove driver version information
Remove unused driver version information from the individual files.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 22 Feb 2012 11:34:08 +0000 (12:34 +0100)]
ALSA: hda/via - Add a few sanity checks
Added sanity checks in a few places not to assume the pins having the
certain amp caps or the input-source being always assigned to a mux.
No actual bugs have been triggered by these, but surely better to be a
bit more robust.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 22 Feb 2012 11:26:38 +0000 (12:26 +0100)]
ALSA: hda/via - Don't create duplicated boost controls
The driver may create duplicated mic boost controls when there are
multiple mics with the very same type / location, and this leads to
the error at actual kcontrol creation. It needs to check the validity
of the created control and add a proper index if it's duplicated.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mark Hills [Tue, 21 Feb 2012 21:26:31 +0000 (21:26 +0000)]
ALSA: snd-usb-caiaq: Fix the return of XRUN
Commit
3702b08 added a lock, but did not account for the case of
SNDRV_PCM_POS_XRUN, which would get immediately overwritten.
This could be bundled into one if-else-if statement, but the goto
helps to clarify the 'exceptional' case.
Thanks to Andreas Pape for spotting this.
Signed-off-by: Mark Hills <mark@pogo.org.uk>
Acked-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 20:21:57 +0000 (21:21 +0100)]
Merge tag 'asoc-3.3' of git://git./linux/kernel/git/broonie/sound into for-linus
A couple of small, driver specific fixes - nothing too exciting going
on.
Takashi Iwai [Tue, 21 Feb 2012 11:54:17 +0000 (12:54 +0100)]
ALSA: hda/realtek - Small code cleanups
A few clean-ups for post-static-quirk time:
- Call alc_auto_init_std() statically in alc_init() instead of setting
spec->init_hook in each caller. spec->init_hook field is left
unused for any future use.
- Move the call of set_capture_mixer() to to alc_parse_auto_config()
instead of each caller.
- Get rid of the ADC-filling and imux check in each parser function.
This is no longer needed since the auto-parser always check ADCs and
imux. It was only for the static quirks.
- Kill unused defines
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 11:37:00 +0000 (12:37 +0100)]
ALSA: hda/realtek - Fix the wrong offset for two-speaker systems
When the machine has two speakers but wants to put more multi-io
jacks, the parser shouldn't consider about the shared DAC but try to
assign the individual DACs. Otherwise the channel mapping would be
fairly confused and lead to the wrong DACs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 11:35:27 +0000 (12:35 +0100)]
ALSA: hda/realtek - Fix the possible conflicts of Bass Speaker name
When the multi-io is added to the two speaker output configuration,
the parser would try to add yet another "Bass Speaker" control since
it checks only cfg->line_outs. Add a workaround for it by simply
passing the channel name in the case of multi-io outputs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 11:12:57 +0000 (12:12 +0100)]
ALSA: hda/realtek - Create individual mute switches for shared DAC
Even if the outputs are using shared DACs, we can still create individual
mute siwtches since they are assigned per pin. This allows to create,
e.g. Speaker and Bass Speaker mute switches while the single volume is
used for these outputs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 10:59:45 +0000 (11:59 +0100)]
ALSA: hda/realtek - Fix possible Oops with NULL input_mux
When BIOS is damn crazy and gives no pin-config at all, the driver might
lead to a NULL dereference. Let's add a NULL check for such a case.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 10:27:09 +0000 (11:27 +0100)]
ALSA: hda/realtek - Parse aa-loopback items dynamically
Similarly in patch_via.c, parse the active analog-loopback connections
and create a list dynamically rather than static arrays.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 21 Feb 2012 10:11:48 +0000 (11:11 +0100)]
ALSA: hda/realtek - Remove the last static quirks for ALC882
Resitance is futile. The remaining static model quirks for Apple
machines with ALC882-compatible codecs are converted to the auto-parser
now. We can remove all alc*_quirks.c finally.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Kuninori Morimoto [Tue, 21 Feb 2012 04:14:16 +0000 (20:14 -0800)]
ASoC: ak4642: fixup HeadPhone L/R dapm settings
Current ak4642 driver had wrong dapm settings for headphone L/R.
If you select headphone L, and select R after that,
headphone L setting was removed by R settings.
This patch fixes it up.
It provides just "Headphone Enable" to user side
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Takashi Iwai [Mon, 20 Feb 2012 17:41:02 +0000 (18:41 +0100)]
ALSA: hda/realtek - Add model=fixup not to apply fix-ups
If anyone wants to debug the driver and avoid the existing fix-ups,
pass model=nofixup option. Then the driver will skip to pick up the
fixup list.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 17:20:42 +0000 (18:20 +0100)]
ALSA: hda/realtek - Drop all ALC880 static quirks
Finally the all static quirks for ALC880 are converted to the
auto-parser. Since we are never sure whether the BIOS on so many old
machines are really correct, the quirk table entries are copied as
they are, but just providing the proper pin-config values
accordingly.
Since alc880_quirks.c is removed, alc882_quirks.c has to be adjusted
slightly to be built again. There might be some compile warnings due
to the remaining alc882 quirks, but these shall be killed sooner or
later, I don't care it much at this point.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 16:56:57 +0000 (17:56 +0100)]
ALSA: hda/realtek - Drop model=asus* from ALC880
It turned out that BIOS on most of ASUS mobo's set the pin-config tables
reasonably well for the auto-parser. We'd need GPIO setups, but should
work as is other than that.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 16:48:19 +0000 (17:48 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=asus-w1v with auto-parser
ASUS W1V has a sane pin-config table set by BIOS. The only missing piece
is the setup of GPIO1.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 16:41:51 +0000 (17:41 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=z71v with auto-parser
ASUS Z71V has a totally broken BIOS setup (at least the info I got),
thus we need to override the whole pin-config table to make the
auto-parser working correctly.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 16:31:02 +0000 (17:31 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=uniwill-dig with auto-parser
ALC880 model=uniwill-dig requires the fix-up of bogus BIOS pin default
configurations. Other than that, it's pretty normal.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 16:20:48 +0000 (17:20 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=uniwill with auto-parser
The model=uniwill would work almost as is, but a couple of adjustments
are needed to make the mutli-io working correctly. The headphone and
speaker pins have to be marked properly in pin configs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 16:11:38 +0000 (17:11 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=uniwill-p53 with auto-parser
Uniwill p53 has a sane BIOS setup but just needs the volume-knob handling
like Fujitsu laptops with ALC880.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 15:36:52 +0000 (16:36 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=F1734 with auto-parser
Similar as the previous patch for model=fujitsu, we can now move the
static quirk for F1734 to the auto-parser. The only difference is the
default pin configurations: F1734 has less pins than Amilo's.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 15:31:07 +0000 (16:31 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=futjisu with auto-parser
Now adding the support for the volume-knob widget, we can move the static
quirk for ALC880 model=fujitsu to the auto-parser completely.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 20 Feb 2012 14:47:55 +0000 (15:47 +0100)]
ALSA: hda/realtek - Apply probe-fixup really after probing
Move the call of alc_apply_fixup() with ALC_FIXUP_ACT_PROBE after the
whole setups of patch_ops & co, so that the fix-up function may override
the default setup. This will be needed for installing the own unsol
event handler (e.g. for volume-knob controls).
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jeffrin Jose [Thu, 16 Feb 2012 16:20:49 +0000 (21:50 +0530)]
ALSA: Fixed a trailing white space error
This is a patch to the sound/core/misc.c file that
fixes up a trailing white space issue found by the
checkpatch.pl tool.
Signed-off-by: Jeffrin Jose <ahiliation@yahoo.co.in>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 16:54:44 +0000 (17:54 +0100)]
ALSA: hda/realtek - Replace ALC880 model=tcl with auto-parser
It needs a few extra setups for EAPD, but others look fairly
straightforward.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 16:49:54 +0000 (17:49 +0100)]
ALSA: hda/realtek - Drop ALC880 model=clevo
Clevo machines with ALC880 are all well with proper BIOS setup.
It seems still requiring the additional COEF setup for the EAPD.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 16:27:53 +0000 (17:27 +0100)]
ALSA: hda/realtek - Refactor the DAC filler function
Refactor the DAC filling function to be used for both the primary
line outputs and extra outputs using the individual badness tables.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 15:33:56 +0000 (16:33 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=w810 with auto-parser
The Medion W810 with ALC880 has a typical BIOS bug, copying the
pin-defaults without disabling the unused pins. At least, the pin
0x17 must be disabled. Also, it requires GPIO-2 setup.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 15:18:59 +0000 (16:18 +0100)]
ALSA: hda/realtek - Rewrite ALC880 model=lg with the auto-parser
ALC880 model=lg could work fine with the auto-parser due to the recent
rewrite, but it still needs the manual adjustment; namely, the BIOS leaves
unused pins as some real active jacks. This confuses the parser.
Thus we just cover these pins and override the pin-configs as a fix-up.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 15:17:03 +0000 (16:17 +0100)]
ALSA: hda/realtek - Adjust badness calculation for multi-ios
Try harder to fit the multi-io pins also by checking the hard-wired
connections for multi-ios. Also, the badness values are adjusted to
prioritize the multi-ios as more valuable. These changes will enable
the multi-io on some machines without losing the current capability.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 13:09:20 +0000 (14:09 +0100)]
ALSA: hda/realtek - Show multi-io pins in debug prints
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Fri, 17 Feb 2012 09:12:38 +0000 (10:12 +0100)]
ALSA: hda/realtek - Fix surround output regression on Acer Aspire 5935
The previous fix for the speaker on Acer Aspire 59135 introduced
another problem for surround outputs. It changed the connections on
the line-in/mic pins for limiting the routes, but it left the modified
connections. Thus wrong connection indices were written when set to
4ch or 6ch mode.
This patch fixes it by restoring the right connections just after
parsing the tree but before the initialization.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=42740
Cc: <stable@kernel.org> [v3.2+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 17:39:45 +0000 (18:39 +0100)]
ALSA: hda/realtek - Try harder to fit the single-connections
So far, the Realtek driver tires to assign the single-connected routes
for all pins only once at the beginning. However, since some DACs have
been already mapped, the rest pins might have also single conections.
In this patch, the driver does the single-connection assignment in a
loop until all possbile single-connections are checked. This will
improve the DAC assignment, e.g. for ASUS G72.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 15:45:59 +0000 (16:45 +0100)]
ALSA: hda/realtek - Finer tuning of auto-parser with badness evaluation
This patch improves the Realtek auto-parser for assigning the DACs and
mixers in more suitable ways by evaluating the assignment with "badness"
calculations.
When assigning a DAC hinders the assignment of individual DACs for
other pins, some badness point is given. Similarly, when it blocks the
assignment of unique mixer controls, another badness point is added.
Also, if no DAC, even shared DAC, can be assigned, more badness is
pointed. Finally, comparing the accumulated badness, the best route is
chosen among several trials.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 16:23:46 +0000 (17:23 +0100)]
ALSA: hda/realtek - Improve the signel-connection check
When the connections from the pin selector contain only two
widgets, a route to DAC and the aa-mixer, it's certainly a
single connection. In such a case, get_dac_if_single() should
return the connected DAC, too.
This will improve the detection of the individual DAC
assignment for each pin.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 15:43:09 +0000 (16:43 +0100)]
Merge branch 'fix/hda' into topic/hda
The fix for bitmap-overflow in Realtek codec driver is needed for the
further development of the auto-parser with badness evaluation.
Takashi Iwai [Thu, 16 Feb 2012 15:38:07 +0000 (16:38 +0100)]
ALSA: hda/realtek - Fix overflow of vol/sw check bitmap
The bitmap introduced in the commit [
527e4d73: ALSA: hda/realtek - Fix
missing volume controls with ALC260] is too narrow for some codecs,
which may have more NIDs than 0x20, thus it may overflow the bitmap
array on them.
Just double the number to cover all and also add a sanity-check code
to be safer.
Cc: <stable@kernel.org> [v3.2+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 12:03:18 +0000 (13:03 +0100)]
ALSA: hda/realtek - Disable static fixups for ASUS with ALC269
We've enabled the static fixups for ASUS machines with ALC269 codec,
just for making things compatible during the transition to the auto-
parser. However, it seems that the static configurations do more harmful
than good, as some of entries don't match with the actual hardware setups.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 11:59:55 +0000 (12:59 +0100)]
ALSA: hda/realtek - Remove leftover static quirks for ALC260
Now we can clean up all static quirks for ALC260.
Also many codes in alc_quirks.c can be ripped off since they have been
used only by ALC260 static quirks.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 11:47:36 +0000 (12:47 +0100)]
ALSA: hda/realtek - Drop model=fujitsu from ALC260 static quirks
The model works with the auto-parser as is, thus now good to drop.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 11:45:03 +0000 (12:45 +0100)]
ALSA: hda/realtek - Drop model=favorit100 for ALC260
It's working with the auto-parser just with the standard GPIO 1 setup.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 11:42:30 +0000 (12:42 +0100)]
ALSA: hda/realtek - Add the support for HP Presario B1900
HP Presario B1900 needs a similar hack like Replacer, toggling GPIO1
per the jack state, in addition to the COEF setup used for other Acer
laptops.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 11:35:16 +0000 (12:35 +0100)]
ALSA: hda/realtek - Replace ALC260 model=replacer with the auto-parser
The support for Replacer 627V in the auto-parser needs the unique unsol
event handling: although the machine has a single output pin 0x0f, it's
used for both the headphone and the speaker, and the driver needs to
toggle the output route via GPIO 1.
In addition, it needs a special COEF setup with 0x3050.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 11:02:53 +0000 (12:02 +0100)]
ALSA: hda/realtek - Replace ALC260 model=acer with the auto-parser
The ALC260 model=acer needs GPIO1 setup. It could be selected well
if the codec SSID is set properly by BIOS, but to make sure, enable it
forcibly.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Thu, 16 Feb 2012 10:51:19 +0000 (11:51 +0100)]
ALSA: hda/realtek - Add the fixup codes for ALC260 model=will
The model=will for ALC260 requires the pin 0x0f to be a headphone and
some special verbs for the COEF to turn on the amp. Now added these as
fixup entries and removed the static model quirk.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Xi Wang [Tue, 14 Feb 2012 10:18:48 +0000 (05:18 -0500)]
ALSA: usb-audio: avoid integer overflow in create_fixed_stream_quirk()
A malicious USB device could feed in a large nr_rates value. This would
cause the subsequent call to kmemdup() to allocate a smaller buffer than
expected, leading to out-of-bounds access.
This patch validates the nr_rates value and reuses the limit introduced
in commit
4fa0e81b ("ALSA: usb-audio: fix possible hang and overflow
in parse_uac2_sample_rate_range()").
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Masanari Iida [Tue, 14 Feb 2012 15:38:55 +0000 (00:38 +0900)]
ALSA: usx2y: Fix typo in usbusx2yaudio.c and usx2yhwdeppcm.c
Correct spelling "propably" to "probably" and "activ" to "active"
in sound/usb/usx2y/usbusx2yaudio.c and usx2yhwdeppcm.c
Signed-off-by: Masanari Iida <standby24x7@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mark Brown [Tue, 14 Feb 2012 06:00:47 +0000 (22:00 -0800)]
ASoC: wm8962: Fix sidetone enumeration texts
The sidetone enumeration texts have left and right swapped.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org