Commit Graph

401786 Commits

Author SHA1 Message Date
Dan Carpenter 11b3fdacba ALSA: snd-aoa: two copy and paste bugs
These functions were cut and paste and the tests for NULL weren't
updated properly.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-13 09:28:23 +01:00
Takashi Iwai 468ac41304 ALSA: hda - Check keep_eapd_on before inv_eapd
We don't change the EAPD bit in set_pin_eapd() if keep_eapd_on flag is
set by the codec driver and enable is false.  But, we also apply the
flipping of enable value according to inv_eapd flag in the same
function, and this confused the former check, handled as if it's
turned ON.  The inverted EAPD check must be applied after keep_eapd_on
check, instead.

Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-12 11:36:00 +01:00
David Henningsson 5959a6bc11 ALSA: hda - Fix Line Out automute on Realtek multifunction jacks
In case there is both a multifunction headset jack and a Line Out
jack, automuting was not working properly from the Line Out jack.
This patch fixes that issue.

Cc: stable@vger.kernel.org (3.10+)
BugLink: https://bugs.launchpad.net/bugs/1250377
Tested-by: Cyrus Lien <cyrus.lien@canonical.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-12 11:35:31 +01:00
Takashi Iwai 092f9cd16a ALSA: msnd: Avoid duplicated driver name
msnd_pinnacle.c is used for both snd-msnd-pinnacle and
snd-msnd-classic drivers, and both should have different driver
names.  Using the same driver name results in the sysfs warning for
duplicated entries like
 kobject: 'msnd-pinnacle.7' (cec33408): kobject_release, parent   (null) (delayed)
 kobject: 'msnd-pinnacle' (cecd4980): kobject_release, parent cf3ad9b0 (delayed)
 ------------[ cut here ]------------
 WARNING: CPU: 0 PID: 1 at fs/sysfs/dir.c:486 sysfs_warn_dup+0x7d/0xa0()
 sysfs: cannot create duplicate filename '/bus/isa/drivers/msnd-pinnacle'
 ......

Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-12 08:06:20 +01:00
Richard Fitzgerald c15b149a30 ALSA: compress_core: don't return -EBADFD from poll if paused
Pausing audio playback is not an illegal state so it doesn't
seem sensible for poll() to return -EBADFD on a paused stream.
There's also no reason to assume that we can't write more data
to the DSP while playback is paused. Remove the -EBADFD so that
a stream in paused state will still report the buffer
availability from poll(). It is up to the user process to
manage its state so that it knows whether it is paused or not.

Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
Acked-by VInod Koul <vinod.koul@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-12 07:14:32 +01:00
Anssi Hannula 679605c768 ALSA: hda - hdmi: Fix wrong baseline length in ATI/AMD generated ELD
According to the HDA specification the baseline ELD length is counted in
DW of 4 bytes instead of in bytes.

Fix the code accordingly.

Baseline length is not used by the kernel so only the ELD exported to
userspace was affected. No issues have been reported.

v2: Fixed so that eld_size is adjusted upwards accordingly as well.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 17:08:39 +01:00
Anssi Hannula a5666824ce ALSA: hda - hdmi: Skip out-of-range latency values in AMD ELD generator
The ATI/AMD video/audio latencies are specified in apparent HDMI VSDB
format. In this format values above 251 are not valid (or stream
component is not supported - 255), but no checking is performed since
this was not mentioned in the AMD HDA verbs specification.

Check that the latencies are valid before using them, and add a comment
describing the formats.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 17:08:04 +01:00
Anssi Hannula 13122e6ebf ALSA: hda - hdmi: Add error-checking to some codec reads
Add error checks to HBR status reads (both generic and ATI/AMD) and
ATI/AMD codec reads for ELD generation.

Unchecked errors in these just caused more errors later on (invalid
codec writes for the HBR ones and ELD parsing errors for the ATI/AMD ELD
ones), but it is better to catch them earlier.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 17:07:49 +01:00
Anssi Hannula 71373fddf6 ALSA: usb: Fix wrong mapping of RLC and RRC channels
According to USB Audio spec v2 bits 25 and 26 of bmChannelConfig are
"Back Left of Center - BLC" and "Back Right of Center - BRC",
respectively.

They are currently assigned to ALSA channels BLC/BRC. However, the ALSA
BLC/BRC are actually the rather nonsensical "bottom left center" and
"bottom right center", so the channels will be assigned wrongly. The
comments in the USB code are also similarly wrong, so this is not
readily apparent without looking at the actual specification.

Fix the channel mapping by mapping bits 25 and 26 to RLC (Rear Left
Center) and RRC (Rear Right Center), respectively, instead.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 17:06:57 +01:00
Anssi Hannula 94908a39ce ALSA: hda - hdmi: Use TFx channel positions instead of FxH
Channel map positions FLH, FCH, FRH duplicate positions TFL, TFC, TFR.
Both are the speakers above the front speakers (CEA uses "high" and USB
audio uses "top" nomenclature).

Since the USB audio code has used the TFx positions since v3.8
(04324ccc75, "ALSA: usb-audio: add channel map support") but the HDMI
code only just started using FxH in a5b7d510b2 ("ALSA: hda -
hdmi: Fix channel maps with less common speakers") which is not yet in
any released kernel, standardize on TFx instead.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 17:06:40 +01:00
Wei Yongjun a522409e9c ALSA: sparc: fix missing unlock on error in snd_cs4231_playback_prepare()
Add the missing unlock before return from function
snd_cs4231_playback_prepare() in the error handling
case.

Fixes: 5a19b178d7 ('ALSA: sparc/cs4231: Use WARN_ON() instead of BUG_ON()')
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 16:23:16 +01:00
Takashi Iwai 0c52db8cca ALSA: hda - Control SPDIF out pin on MacBookPro 11,2
The SPDIF output MBP11,2 requires the pin control to be set/cleared
for turning on/off the optical SPDIF.  The red light turns off only
when the corresponding pin control is cleared (or powered to D3).

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=64401
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-11 16:22:04 +01:00
Takashi Iwai a6bc732b5a ASoC: Updates for v3.13
Some additional fixes for v3.13, the majority of which are removals and
 downgrades of BUG()s from Takashi.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.15 (GNU/Linux)
 
 iQIcBAABAgAGBQJSfQOIAAoJELSic+t+oim9LAEQAJYKPUcjUM81aK05UuapJEgP
 X1SJ4FP/SRkmQXaTEd+1cd8owD0qcYH1EFeUfK80vmXIaare+pPhAUGKfkJZeR26
 SzC34tJ5TjeQ3Is+2a0mymih8v+03iG7+s/4XSSxk7X+t/T3tr/1KvL96+Bvt/Fp
 /u+MzLOzTS3rMFfGX5kT2FARe9k941BnEsbRLrz7NAM//zSOpNzht+9bKWOKu0zp
 s8W3zqZc4zZxKuqweyo5F9++Nfcd+4lt7JqaB1veHHMuWhQmsmi1rAnAGWAVcoK8
 f70GAGY147BPCfdyWG3A9RRmZ5xlIGFA60XfCOr2c0Pz2Bo165p8sLGrctM9nOvq
 7+hrxK2X0jQGrQ774obaxqegm+YhAy2zl5ZhDXeu6io+Pg9kb98la0kO4SSkQGH9
 +HghpcFTdvk32pB9u4FzZ5Fp9/1OZHVGMBRp13Bs8ucZRqznvOIhFbeEV1yw4CPT
 /0zv4+ujTwtEJT7mN9CjtKuRbd9A3rpYSxK3d6MJkGNfwWC1vmwjTx02ryA4FVxs
 Evo/9ANfLgt7a7Cmt1avbZ1T1GNMZ6zvFpI1/6Zv6AT6oZhfBdMn/0iSnWunqNC/
 G0ppe/TQrFHpNSW6Z/FsWb3C/S7/HvWKObcWSjezAZLaLPxEZc61NrgP7ZNap7l1
 yNOtdb6HL7i569QU1SAc
 =osG+
 -----END PGP SIGNATURE-----

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

ASoC: Updates for v3.13

Some additional fixes for v3.13, the majority of which are removals and
downgrades of BUG()s from Takashi.
2013-11-08 16:45:38 +01:00
Kailang Yang 9a22a8f558 ALSA: hda/realtek - Add new codec ALC255/ALC3234 UAJ supported
New codec ALC255/ALC3234 support multifunction jacks.
It used for menual select the input device.

Signed-off-by: Kailang Yang <kailang@realtek.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-08 13:52:59 +01:00
Takashi Iwai 885845d785 ALSA: hda - Apply MacBook fixups for CS4208 correctly
The commit [8fe7b65ab465: ALSA: hda - Apply GPIO setup for MacBooks
with CS4208] added a fixup entry matching with the vendor id 0x106b.
This broke the fixups for previous MBA6,1 and 6,2, since the PCI SSID
vendor id matches before evaluating the codec SSIDs.

We had a similar issue on Mac with Sigmatel codecs, and solve this
problem again similarly, by introducing a skeleton entry matching with
the all MacBooks, then remap to the right one.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=64401
Fixes: 8fe7b65ab4 ('ALSA: hda - Apply GPIO setup for MacBooks with CS4208')
Cc: <stable@vger.kernel.org> [v3.12+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-11-08 13:50:56 +01:00
Mark Brown dd212bd5bb Merge remote-tracking branch 'asoc/topic/wm8996' into asoc-next 2013-11-08 10:43:43 +00:00
Mark Brown 22b468a06e Merge remote-tracking branch 'asoc/topic/wm8962' into asoc-next 2013-11-08 10:43:42 +00:00
Mark Brown 552b747564 Merge remote-tracking branch 'asoc/topic/wm8400' into asoc-next 2013-11-08 10:43:42 +00:00
Mark Brown a941145d2b Merge remote-tracking branch 'asoc/topic/wm0010' into asoc-next 2013-11-08 10:43:41 +00:00
Mark Brown 108145a606 Merge remote-tracking branch 'asoc/topic/warn' into asoc-next 2013-11-08 10:43:41 +00:00
Mark Brown 022aa51e3f Merge remote-tracking branch 'asoc/topic/twl6040' into asoc-next 2013-11-08 10:43:40 +00:00
Mark Brown 88cb5111e8 Merge remote-tracking branch 'asoc/topic/twl4030' into asoc-next 2013-11-08 10:43:40 +00:00
Mark Brown 86408059df Merge remote-tracking branch 'asoc/topic/tpa6130a2' into asoc-next 2013-11-08 10:43:40 +00:00
Mark Brown b24a63d5ef Merge remote-tracking branch 'asoc/topic/tlv320aic3x' into asoc-next 2013-11-08 10:43:39 +00:00
Mark Brown 32b7fdfefa Merge remote-tracking branch 'asoc/topic/tlv320aic32x4' into asoc-next 2013-11-08 10:43:39 +00:00
Mark Brown abdf150ade Merge remote-tracking branch 'asoc/topic/tlv320aic26' into asoc-next 2013-11-08 10:43:38 +00:00
Mark Brown e029530075 Merge remote-tracking branch 'asoc/topic/tlv320aic23' into asoc-next 2013-11-08 10:43:38 +00:00
Mark Brown d4af6be4f8 Merge remote-tracking branch 'asoc/topic/tegra' into asoc-next 2013-11-08 10:43:37 +00:00
Mark Brown be529a5b7f Merge remote-tracking branch 'asoc/topic/tas5086' into asoc-next 2013-11-08 10:43:37 +00:00
Mark Brown 6c61bbf0e8 Merge remote-tracking branch 'asoc/topic/spear' into asoc-next 2013-11-08 10:43:36 +00:00
Mark Brown bd6d35a370 Merge remote-tracking branch 'asoc/topic/sn95031' into asoc-next 2013-11-08 10:43:36 +00:00
Mark Brown 8bffb007a5 Merge remote-tracking branch 'asoc/topic/simple' into asoc-next 2013-11-08 10:43:35 +00:00
Mark Brown 6a2972b363 Merge remote-tracking branch 'asoc/topic/si476x' into asoc-next 2013-11-08 10:43:35 +00:00
Mark Brown 87373ad1f3 Merge remote-tracking branch 'asoc/topic/samsung' into asoc-next 2013-11-08 10:43:35 +00:00
Mark Brown 457eb9016b Merge remote-tracking branch 'asoc/topic/rt5640' into asoc-next 2013-11-08 10:43:34 +00:00
Mark Brown 9686e4b2a8 Merge remote-tracking branch 'asoc/topic/rcar' into asoc-next 2013-11-08 10:43:34 +00:00
Mark Brown 469cb9286e Merge remote-tracking branch 'asoc/topic/pxa' into asoc-next 2013-11-08 10:43:33 +00:00
Mark Brown df8aabe442 Merge remote-tracking branch 'asoc/topic/pcm1792a' into asoc-next 2013-11-08 10:43:33 +00:00
Mark Brown 97df0a0538 Merge remote-tracking branch 'asoc/topic/pcm1681' into asoc-next 2013-11-08 10:43:32 +00:00
Mark Brown 5ac452772f Merge remote-tracking branch 'asoc/topic/mxs' into asoc-next 2013-11-08 10:43:32 +00:00
Mark Brown 672922e975 Merge remote-tracking branch 'asoc/topic/ml26124' into asoc-next 2013-11-08 10:43:31 +00:00
Mark Brown efdf09add9 Merge remote-tracking branch 'asoc/topic/mc13783' into asoc-next 2013-11-08 10:43:31 +00:00
Mark Brown c462b1d8bb Merge remote-tracking branch 'asoc/topic/max9850' into asoc-next 2013-11-08 10:43:31 +00:00
Mark Brown b8a77af201 Merge remote-tracking branch 'asoc/topic/max98095' into asoc-next 2013-11-08 10:43:30 +00:00
Mark Brown 5f343663a2 Merge remote-tracking branch 'asoc/topic/max98088' into asoc-next 2013-11-08 10:43:30 +00:00
Mark Brown ca2b2252fc Merge remote-tracking branch 'asoc/topic/kirkwood' into asoc-next 2013-11-08 10:43:29 +00:00
Mark Brown ec7118e391 Merge remote-tracking branch 'asoc/topic/fsl' into asoc-next 2013-11-08 10:43:29 +00:00
Mark Brown 3352b80075 Merge remote-tracking branch 'asoc/topic/ep93xx' into asoc-next 2013-11-08 10:43:28 +00:00
Mark Brown 6157e734de Merge remote-tracking branch 'asoc/topic/doc' into asoc-next 2013-11-08 10:43:28 +00:00
Mark Brown 99a0ea2d5b Merge remote-tracking branch 'asoc/topic/devm' into asoc-next 2013-11-08 10:43:27 +00:00