Commit graph

377419 commits

Author SHA1 Message Date
Wang Xingchao
8b2c7a5c40 ALSA: hda - Add In-driver connection info
Pin's connection list may change dynamically with hot-plug event
on Intel Haswell chip. Users would see connections be "0" in codec#.
when play audio on this pin, software driver choose converter from cache
connections. So add "In-driver connection" info to avoid confuse when
raw connections are different with cache connection.

Signed-off-by: Wang Xingchao <xingchao.wang@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-25 08:13:56 +02:00
Takashi Iwai
eb33ccf763 ALSA: hda - Use auto_mute_via_amp=1 for VT1708
We've got bug report wrt many machines with VT1708 (e.g. IBM POS
machines) showing the broken auto-mute behavior.  It turned out that
the problem is that the pin control values of the speaker and line-out
pins are completely ignored.  As a workaround, let's use the newly
introduced feature of the generic parser, to control the mute via amp
on pins.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-25 08:13:55 +02:00
Takashi Iwai
7eebffd3f4 ALSA: hda - Add auto_mute_via_amp flag to generic parser
Add a new flag, auto_mute_via_amp, to determine the behavior of the
headphone / line-out auto-mute.  When this flag is set, the generic
driver mutes the speaker and line outputs via the amp mute of each
pin, instead of changing the pin control values.

This is introduced for devices that don't work expectedly with the pin
control values; for example, some devices are known to keep enabling
the speaker outputs no matter which pin control values are set on the
speaker pins.

The driver doesn't check actually whether the pins have the output amp
caps, but assumes that the proper mixer (mute) controls are created on
all these pins.  If not the case, you can't use this flag for your
device.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-25 08:13:51 +02:00
Takashi Iwai
1ca2f2ec9e ALSA: vmaster: Add snd_ctl_sync_vmaster() helper function
Introduce a new helper function, snd_ctl_sync_vmaster(), which updates
the slave put callbacks forcibly as well as calling the hook.  This
will be used in the upcoming patch in HD-audio codec driver for
toggling the mute in vmaster slaves.

Along with the new function, the old snd_ctl_sync_vmaster_hook() is
replaced as a macro calling with the argument hook_only=true.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-24 15:51:54 +02:00
Wang Xingchao
e1a4dca671 ALSA: hda - Remove unused variable
Signed-off-by: Wang Xingchao <xingchao.wang@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-24 14:08:57 +02:00
Mengdong Lin
3af3f356e1 ALSA: hda - reset hda link during system/runtime suspend
If all the codecs report ClkStopOK (OK to stop bus clock) after being put to
D3, this patch will reset the HDA link before the controller is put to D3.

So the link will be in reset during system or runtime suspend, the bus clock
stops and the codecs are in D3(ClkStop) state.

This may help to reduce power consumption by dozens of mW on some peripheral
hda codecs.

Signed-off-by: Mengdong Lin <mengdong.lin@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-24 10:06:04 +02:00
Antonio Ospite
a91c3fb2f8 Add M2Tech hiFace USB-SPDIF driver
Add driver for M2Tech hiFace USB-SPDIF interface and compatible devices.

M2Tech hiFace and compatible devices offer a Hi-End S/PDIF Output
Interface, see http://www.m2tech.biz/hiface.html

The supported products are:

  * M2Tech Young
  * M2Tech hiFace
  * M2Tech North Star
  * M2Tech W4S Young
  * M2Tech Corrson
  * M2Tech AUDIA
  * M2Tech SL Audio
  * M2Tech Empirical
  * M2Tech Rockna
  * M2Tech Pathos
  * M2Tech Metronome
  * M2Tech CAD
  * M2Tech Audio Esclusive
  * M2Tech Rotel
  * M2Tech Eeaudio
  * The Chord Company CHORD
  * AVA Group A/S Vitus

Signed-off-by: Antonio Ospite <ao2@amarulasolutions.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-24 09:26:08 +02:00
Takashi Iwai
04c9548c78 ASoC: samsung: Fix a typo of CONFIG_SND_SOC_BT_SCO
... instead of CONFIG_SND_SOC_SCO.
Introduced in the commit 200ceb96.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 18:09:49 +02:00
Takashi Iwai
26889e51d3 ASoC: omap: Fix the leftover CONFIG_SND_SOC_HDMI_CODEC
Replace the leftover CONFIG_SND_SOC_OMAP_HDMI_CODEC in
sound/soc/omap/Kconfig with CONFIG_SND_SOC_HDMI_CODEC, which was
forgotten in the commit bf7c6e6c.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 18:02:01 +02:00
Takashi Iwai
0a1801e26c ASoC: Updates for v3.11
Not a big release subsystem wise, the main changes have been some nice
 improvements on the driver side:
 
 - Lots of cleanups and fixes for Blackfin, SGTL5000 and UX500.
 - Generalisation of the Bluetooth and HDMI stub drivers.
 - New CODEC drivers for SSM2518 and RT5640.
 - New machine driver for Tegra CPUs with RT5640.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.12 (GNU/Linux)
 
 iQIcBAABAgAGBQJRvz1tAAoJELSic+t+oim9x20QAIswcfaLkogh6AEhrP+ayzRA
 xuwrROZoaoHXCoD1xC/YkFYDbYWp69ms3JR5oYrplOpq1h5+jkmbAcsq2mllLL7y
 02uQP73acysze6YKB00wG/khAxmqTLENbiOLbQ2w+X7Ao6Gh0v/BRmNU34OSpj6R
 VDp9eNdLBJ4iZQ8m+S8NTn2bdxtqlRDVNP6aC6L8kxt2khuGTa3acGyFcer8hPwx
 WZFsP9lt5J+8rrZ6l3OH3ZpbldJRB+63ff5O+q0s5KihSfWEeVy3NgK7AG7chG4a
 mffoqymgrtjJDosuhNIwU0mjFLWdFoPI7byTi9Hd5WBJ+d3d1uNr1iFxD7+c+fWd
 Xr5PimssX983D9dbJN3yikzhQt7A2TK9OUCHXdWlLf2fCeYH5PwLySqaDPvmayvh
 5UccHo2j7sDcrztazCFqcfbSdEW/VA5mlHexz1xW9eGDWJncHDYdFPxDp45rwno4
 ZjilEOHNP/1HJl+Nl0D8HArYsk/svLY7t5SpITDjAMPHcCSND4ZH+WknnCFMl2sq
 R67LaeW4UHFUJk7fZHx3a3Gr90OsEC1yb0NaJJ59e8o8fV4e47wNp/yUjCULvSuP
 9136KjBQEofyR5xDiBM6HudFT1wEwpIva5YQoKKZgjqX2sYhwjH5SwfsSd0r25Mh
 PFKtvO1/U63w/AJyn/sM
 =gWf9
 -----END PGP SIGNATURE-----

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

ASoC: Updates for v3.11

Not a big release subsystem wise, the main changes have been some nice
improvements on the driver side:

- Lots of cleanups and fixes for Blackfin, SGTL5000 and UX500.
- Generalisation of the Bluetooth and HDMI stub drivers.
- New CODEC drivers for SSM2518 and RT5640.
- New machine driver for Tegra CPUs with RT5640.
2013-06-21 17:52:58 +02:00
Antonio Ospite
0af49ffe3c ALSA: usb: uniform style used in MODULE_SUPPORTED_DEVICE()
In sound/usb/card.c and sound/usb/misc/ua101.c there are no spaces
between the vendor and the device names, use this style in the other
drivers too.

This also helps keeping consistency when new drivers copies from the
ones already in the mainline tree.

Signed-off-by: Antonio Ospite <ao2@amarulasolutions.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 14:37:08 +02:00
Antonio Ospite
4a9f911861 ALSA: snd-usb-6fire: use vmalloc buffers
For USB devices it's not necessary to allocate physically contiguous
buffers.

Signed-off-by: Antonio Ospite <ao2@amarulasolutions.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 14:36:41 +02:00
Antonio Ospite
fc76f86376 ALSA: snd-usb-caiaq: use vmalloc buffers
For USB devices it's not necessary to allocate physically contiguous
buffers.

Signed-off-by: Antonio Ospite <ao2@amarulasolutions.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 14:35:52 +02:00
Antonio Ospite
3dd446a7e5 ALSA: snd-usb-caiaq: remove the unused snd_card_used variable
The snd_card_used variable is only read but never written, remove it.

Signed-off-by: Antonio Ospite <ao2@amarulasolutions.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 14:33:05 +02:00
Dan Carpenter
fefe228c5f ALSA: vx_core: off by one in vx_read_status()
This code is older than git, and I haven't tested it, but if size ==
SIZE_MAX_STATUS then we would write one space past the end of the
rmh->Stat[] array.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-21 14:32:06 +02:00
David Henningsson
88d5760649 ALSA: hda - Make Thinkpad X220-tablet use generic parser
Like the X220, this quirk was added to support docking station,
so enable the fixup instead.

According to Jan, the generic parser works equal or better
than the current parser. This was tested under a 3.9 kernel.

Reported-by: Jan Alexander Steffens <jan.steffens@gmail.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-20 12:53:36 +02:00
Takashi Iwai
d045c5dc43 ALSA: hda - Fix missing Mic Boost controls for VIA codecs
Some VIA codecs like VT1708S have Mic boost amps in the mic pins but
they aren't exposed in the capability bits.  In the past driver code,
we override the pin caps and create mic boost controls forcibly.
While transition to the generic parser, we lost the mic boost controls
although the pin caps are still overridden, because the generic parser
code checks the widget caps, too.

So this patch adds a new helper function to allow the override of the
given widget capability bits, and makes VIA codecs driver to add the
missing input-amp capability bit.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=59861
Cc: <stable@vger.kernel.org> [v3.9+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-19 07:54:09 +02:00
Takashi Iwai
fd678cac34 ALSA: hda - Use snd_hda_check_power_state() in patch_hdmi.c
... instead of open codes.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 16:28:36 +02:00
Wang Xingchao
7ef166b831 ALSA: hda - Avoid choose same converter for unused pins
For Intel Haswell HDMI codecs, the pins choose converter 0 by default.
This would cause conflict when playing audio on unused pins,the pin with
physical device connected would get audio data too.
i.e. Pin 0/1/2 default choose converter 0, pin 1 has HDMI monitor connected.
when play audio on Pin 0 or pin 2, pin 1 could get audio data too.

This patch configure unused pins to choose different converter.

Signed-off-by: Wang Xingchao <xingchao.wang@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 16:17:48 +02:00
Takashi Iwai
bddee96b5d ALSA: hda - Cache the MUX selection for generic HDMI
When a selection to a converter MUX is changed in hdmi_pcm_open(), it
should be cached so that the given connection can be restored properly
at PM resume.  We need just to replace the corresponding
snd_hda_codec_write() call with snd_hda_codec_write_cache().

Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 16:14:22 +02:00
Wei Yongjun
1389fd03b7 ALSA: firewire: fix error return code in scs_probe()
Fix to return -ENOMEM in the kmalloc() error handling
case instead of 0, as done elsewhere in this function.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Acked-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 16:11:57 +02:00
Wang Xingchao
53b434f093 ALSA: hda - Haswell converter power state D0 verify
Haswell converters maybe in wrong power state before usage.
i.e. only converter 0 is in D0, converter 1/2 are in D3.
When pin choose converter 1/2, there's no audio output, this
cause dependency when playing differnt stream on pins.

AUD_PWRST  ConvertorA_Widget_Power_State_Current        D0
AUD_PWRST  ConvertorA_Widget_Power_State_Requsted       D0
AUD_PWRST  ConvertorB_Widget_Power_State_Current        D3
AUD_PWRST  ConvertorB_Widget_Power_State_Requested      D3
AUD_PWRST  ConvC_Widget_PwrSt_Curr                      D3
AUD_PWRST  ConvC_Widget_PwrSt_Req                       D3

This patch check converter's power state and set D0 if it's in D3 mode.

Signed-off-by: Wang Xingchao <xingchao.wang@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 08:04:15 +02:00
Takashi Iwai
06ec56d3c6 ALSA: hda - Fix return value of snd_hda_check_power_state()
The refactoring by commit 9040d102 introduced the new function
snd_hda_check_power_state().  This function is supposed to return true
if the state already reached to the target state, but it actually
returns false for that.  An utterly stupid typo while copy & paste.

Fortunately this didn't influence on much behavior because powering up
AFG usually powers up the child widgets, too.  But the finer power
control must have been broken by this bug.

Cc: <stable@vger.kernel.org> [v3.9+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 07:59:43 +02:00
Dave Jones
cd1199edc7 ALSA: sound/usb/misc/ua101.c: convert __list_for_each usage to list_for_each
Signed-off-by: Dave Jones <davej@redhat.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-06-18 07:47:32 +02:00
Mark Brown
84bbc4aa2d Merge remote-tracking branch 'asoc/topic/x86' into asoc-next 2013-06-17 17:20:33 +01:00
Mark Brown
5464389755 Merge remote-tracking branch 'asoc/topic/wm8994' into asoc-next 2013-06-17 17:20:32 +01:00
Mark Brown
f57019aa0a Merge remote-tracking branch 'asoc/topic/wm8962' into asoc-next 2013-06-17 17:20:32 +01:00
Mark Brown
7daf390b8b Merge remote-tracking branch 'asoc/topic/wm0010' into asoc-next 2013-06-17 17:20:31 +01:00
Mark Brown
458bcee95d Merge remote-tracking branch 'asoc/topic/ux500' into asoc-next 2013-06-17 17:20:30 +01:00
Mark Brown
93d4c1e04f Merge remote-tracking branch 'asoc/topic/tegra' into asoc-next 2013-06-17 17:20:30 +01:00
Mark Brown
bfe617d33d Merge remote-tracking branch 'asoc/topic/ssm2518' into asoc-next 2013-06-17 17:20:29 +01:00
Mark Brown
5f5eb4efe5 Merge remote-tracking branch 'asoc/topic/spear' into asoc-next 2013-06-17 17:20:28 +01:00
Mark Brown
d238ffabc5 Merge remote-tracking branch 'asoc/topic/spdif' into asoc-next 2013-06-17 17:20:28 +01:00
Mark Brown
0c5f45065c Merge remote-tracking branch 'asoc/topic/sn95031' into asoc-next 2013-06-17 17:20:27 +01:00
Mark Brown
14345a5898 Merge remote-tracking branch 'asoc/topic/sgtl5000' into asoc-next 2013-06-17 17:20:27 +01:00
Mark Brown
1ee9271d67 Merge remote-tracking branch 'asoc/topic/samsung' into asoc-next 2013-06-17 17:20:26 +01:00
Mark Brown
60790c5735 Merge remote-tracking branch 'asoc/topic/rt5640' into asoc-next 2013-06-17 17:20:25 +01:00
Mark Brown
3843e87ebd Merge remote-tracking branch 'asoc/topic/pxa' into asoc-next 2013-06-17 17:20:25 +01:00
Mark Brown
b2d34a822b Merge remote-tracking branch 'asoc/topic/omap' into asoc-next 2013-06-17 17:20:24 +01:00
Mark Brown
c76a507bfe Merge remote-tracking branch 'asoc/topic/mxs' into asoc-next 2013-06-17 17:20:23 +01:00
Mark Brown
ff868b2296 Merge remote-tracking branch 'asoc/topic/max98090' into asoc-next 2013-06-17 17:20:23 +01:00
Mark Brown
6502737276 Merge remote-tracking branch 'asoc/topic/kirkwood' into asoc-next 2013-06-17 17:20:22 +01:00
Mark Brown
46dd30a893 Merge remote-tracking branch 'asoc/topic/jz4740' into asoc-next 2013-06-17 17:20:22 +01:00
Mark Brown
18923d7ec7 Merge remote-tracking branch 'asoc/topic/hdmi' into asoc-next 2013-06-17 17:20:21 +01:00
Mark Brown
0d664db622 Merge remote-tracking branch 'asoc/topic/fsl' into asoc-next 2013-06-17 17:20:20 +01:00
Mark Brown
5ec393bcda Merge remote-tracking branch 'asoc/topic/fsi' into asoc-next 2013-06-17 17:20:20 +01:00
Mark Brown
59338599d8 Merge remote-tracking branch 'asoc/topic/ep93xx' into asoc-next 2013-06-17 17:20:19 +01:00
Mark Brown
e95e939d15 Merge remote-tracking branch 'asoc/topic/dwc' into asoc-next 2013-06-17 17:20:19 +01:00
Mark Brown
c44ddeb837 Merge remote-tracking branch 'asoc/topic/dfmbcs320' into asoc-next 2013-06-17 17:20:18 +01:00
Mark Brown
684d8c515c Merge remote-tracking branch 'asoc/topic/davinci' into asoc-next 2013-06-17 17:20:18 +01:00