]> git.karo-electronics.de Git - karo-tx-linux.git/log
karo-tx-linux.git
13 years agoMerge branch 'fix/hda' into for-next
Takashi Iwai [Wed, 23 Mar 2011 07:01:40 +0000 (08:01 +0100)]
Merge branch 'fix/hda' into for-next

13 years agoALSA: hda - VIA: Fix VT1708 can't build up Headphone control issue
Lydia Wang [Tue, 22 Mar 2011 08:26:36 +0000 (16:26 +0800)]
ALSA: hda - VIA: Fix VT1708 can't build up Headphone control issue

Since VT1708 didn't support the control of getting connection number,
building of headphone control will fail in via_hp_build() function.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - VIA: Correct stream names for VT1818S
Lydia Wang [Tue, 22 Mar 2011 08:25:56 +0000 (16:25 +0800)]
ALSA: hda - VIA: Correct stream names for VT1818S

Correct stream names of analog playback and capture streams
for VT1818S.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - VIA: Fix codec type for VT1708BCE at the right timing
Lydia Wang [Tue, 22 Mar 2011 08:25:03 +0000 (16:25 +0800)]
ALSA: hda - VIA: Fix codec type for VT1708BCE at the right timing

Add get_codec_type() in via_new_spec() function to make sure getting
correct codec type before building mixer controls.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - VIA: Fix invalid A-A path volume adjust issue
Lydia Wang [Tue, 22 Mar 2011 08:24:10 +0000 (16:24 +0800)]
ALSA: hda - VIA: Fix invalid A-A path volume adjust issue

Modify vt_auto_create_analog_input_ctls() function to fix invalid a-a path
volume adjust issue for VT1708S, VT1702 and VT1716S codecs.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - VIA: Add missing support for VT1718S in A-A path
Lydia Wang [Tue, 22 Mar 2011 08:23:23 +0000 (16:23 +0800)]
ALSA: hda - VIA: Add missing support for VT1718S in A-A path

Modify mute_aa_path() function to support VT1718S codec.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - VIA: Fix independent headphone no sound issue
Lydia Wang [Tue, 22 Mar 2011 08:22:37 +0000 (16:22 +0800)]
ALSA: hda - VIA: Fix independent headphone no sound issue

Modify via_independent_hp_put() function to support VT1718S and VT1812
codecs, and fix independent headphone no sound issue.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - VIA: Fix stereo mixer recording no sound issue
Lydia Wang [Tue, 22 Mar 2011 08:21:38 +0000 (16:21 +0800)]
ALSA: hda - VIA: Fix stereo mixer recording no sound issue

Modify function via_mux_enum_put() to fix stereo mixer recording
no sound issue.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - Set EAPD for Realtek ALC665
Andres Mejia [Sun, 20 Mar 2011 18:07:40 +0000 (14:07 -0400)]
ALSA: hda - Set EAPD for Realtek ALC665

Set EAPD for Realtek ALC665 (Vendor Id: 0x10eSet EAPD for Realtek
ALC665 (Vendor Id: 0x10ec0665).

Signed-off-by: Andres Mejia <mcitadel@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: usb - Remove trailing spaces from USB card name strings
Takashi Iwai [Mon, 21 Mar 2011 11:00:00 +0000 (12:00 +0100)]
ALSA: usb - Remove trailing spaces from USB card name strings

Some USB devices give trailing spaces in strings returned from
usb_string().  This confuses the automatic card-id creation, resulting
always in "default".
This patch fixes the behavior by removing trailing spaces.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agosound: read i_size with i_size_read()
Xiaochen Wang [Fri, 18 Mar 2011 08:29:25 +0000 (16:29 +0800)]
sound: read i_size with i_size_read()

Convert direct read of inode->i_size to using i_size_read().
i_size_read is guaranteed to return a valid value and
its caller does not need to use addtional locking.

Signed-off-by: Xiaochen Wang <wangxiaochen0@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/misc' into for-linus
Takashi Iwai [Fri, 18 Mar 2011 06:39:08 +0000 (07:39 +0100)]
Merge branch 'topic/misc' into for-linus

13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Fri, 18 Mar 2011 06:38:54 +0000 (07:38 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: sound/pci/asihpi: check adapter index in hpi_ioctl
Dan Rosenberg [Thu, 17 Mar 2011 22:32:24 +0000 (18:32 -0400)]
ALSA: sound/pci/asihpi: check adapter index in hpi_ioctl

The user-supplied index into the adapters array needs to be checked, or
an out-of-bounds kernel pointer could be accessed and used, leading to
potentially exploitable memory corruption.

Signed-off-by: Dan Rosenberg <drosenberg@vsecurity.com>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: aloop - Fix possible IRQ lock inversion
Takashi Iwai [Fri, 18 Mar 2011 06:31:53 +0000 (07:31 +0100)]
ALSA: aloop - Fix possible IRQ lock inversion

loopback_pos_update() can be called in the timer callback, thus the lock
held should be irq-safe.  Otherwise you'll get AB/BA deadlock together
with substream->self_group.lock.

Reported-and-tested-by: Knut Petersen <Knut_Petersen@t-online.de>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/hda' into for-linus
Takashi Iwai [Wed, 16 Mar 2011 16:38:46 +0000 (17:38 +0100)]
Merge branch 'topic/hda' into for-linus

13 years agoMerge branch 'topic/asoc' into for-linus
Takashi Iwai [Wed, 16 Mar 2011 16:38:41 +0000 (17:38 +0100)]
Merge branch 'topic/asoc' into for-linus

13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Wed, 16 Mar 2011 16:37:11 +0000 (17:37 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: sound/core: merge list_del()/list_add_tail() to list_move_tail()
Nicolas Kaiser [Wed, 16 Mar 2011 16:10:11 +0000 (17:10 +0100)]
ALSA: sound/core: merge list_del()/list_add_tail() to list_move_tail()

Merge list_del() + list_add_tail() to list_move_tail().

Signed-off-by: Nicolas Kaiser <nikai@nikai.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/asoc' into for-next
Takashi Iwai [Wed, 16 Mar 2011 11:23:06 +0000 (12:23 +0100)]
Merge branch 'topic/asoc' into for-next

13 years agoMerge branch 'for-2.6.39' of git://git.kernel.org/pub/scm/linux/kernel/git/lrg/asoc...
Takashi Iwai [Wed, 16 Mar 2011 11:14:46 +0000 (12:14 +0100)]
Merge branch 'for-2.6.39' of git://git.kernel.org/pub/scm/linux/kernel/git/lrg/asoc-2.6 into topic/asoc

13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Wed, 16 Mar 2011 06:49:02 +0000 (07:49 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: ctxfi - use list_move() instead of list_del()/list_add() combination
Kirill A. Shutemov [Tue, 15 Mar 2011 22:53:24 +0000 (00:53 +0200)]
ALSA: ctxfi - use list_move() instead of list_del()/list_add() combination

Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/firewire' into for-next
Takashi Iwai [Wed, 16 Mar 2011 06:47:59 +0000 (07:47 +0100)]
Merge branch 'topic/firewire' into for-next

13 years agoALSA: firewire - msleep needs delay.h
Stephen Rothwell [Wed, 16 Mar 2011 06:39:28 +0000 (17:39 +1100)]
ALSA: firewire - msleep needs delay.h

fixes this error:

sound/firewire/fcp.c: In function 'fcp_avc_transaction':
sound/firewire/fcp.c:103: error: implicit declaration of function 'msleep'

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/asoc' into for-next
Takashi Iwai [Tue, 15 Mar 2011 16:41:23 +0000 (17:41 +0100)]
Merge branch 'topic/asoc' into for-next

13 years agoMerge branch 'topic/firewire' into for-next
Takashi Iwai [Tue, 15 Mar 2011 07:44:00 +0000 (08:44 +0100)]
Merge branch 'topic/firewire' into for-next

13 years agoALSA: firewire-lib, firewire-speakers: handle packet queueing errors
Clemens Ladisch [Tue, 15 Mar 2011 06:57:24 +0000 (07:57 +0100)]
ALSA: firewire-lib, firewire-speakers: handle packet queueing errors

Add an AMDTP stream error state that occurs when we fail to queue
another packet.  In this case, the stream is stopped, and the error can
be reported when the application tries to restart the PCM stream.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: firewire-lib: allocate DMA buffer separately
Clemens Ladisch [Tue, 15 Mar 2011 06:55:50 +0000 (07:55 +0100)]
ALSA: firewire-lib: allocate DMA buffer separately

For correct cache coherency on some architectures, DMA buffers must be
allocated in a different cache line than data that is concurrently used
by the CPU.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: firewire-lib: use no-info SYT for packets without SYT sample
Clemens Ladisch [Tue, 15 Mar 2011 06:55:02 +0000 (07:55 +0100)]
ALSA: firewire-lib: use no-info SYT for packets without SYT sample

In non-blocking mode, the SYT_INTERVAL is larger than the number of
audio frames in each packet, so there are packets that do not contain
any frame to which the SYT could be applied.  For these packets, the
SYT must not be the timestamp of the next valid SYT frame, but the
special no-info SYT value.

This fixes broken playback on the FireWave at 44.1 kHz.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: add LaCie FireWire Speakers/Griffin FireWave Surround driver
Clemens Ladisch [Tue, 15 Mar 2011 06:53:21 +0000 (07:53 +0100)]
ALSA: add LaCie FireWire Speakers/Griffin FireWave Surround driver

Add a driver for two playback-only FireWire devices based on the OXFW970
chip.

v2: better AMDTP API abstraction; fix fw_unit leak; small fixes
v3: cache the iPCR value
v4: FireWave constraints; fix fw_device reference counting;
    fix PCR caching; small changes and fixes
v5: volume/mute support; fix crashing due to pcm stop races
v6: fix build; one-channel volume for LaCie
v7: use signed values to make volume (range checks) work; fix function
    block IDs for volume/mute; always use channel 0 for LaCie volume

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Acked-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Tested-by: Jay Fenlason <fenlason@redhat.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/hda' into for-next
Takashi Iwai [Mon, 14 Mar 2011 14:53:57 +0000 (15:53 +0100)]
Merge branch 'topic/hda' into for-next

13 years agoALSA: hda - Remove an unused variable in patch_realtek.c
Takashi Iwai [Mon, 14 Mar 2011 14:53:15 +0000 (15:53 +0100)]
ALSA: hda - Remove an unused variable in patch_realtek.c

Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - pin-adc-mux-dmic auto-configuration of 92HD8X codecs
Vitaliy Kulikov [Thu, 10 Mar 2011 19:43:35 +0000 (13:43 -0600)]
ALSA: hda - pin-adc-mux-dmic auto-configuration of 92HD8X codecs

This patch replaces use of the harcoded arrays of pins, muxes, digital
mics and adcs with the auto-generated ones using codec parsing and
auto-discovers all actually connected digital mic pins on 92HD8X-like
codecs

This patch also adds the support for d-mic on pin 0x20.

Signed-off-by: Vitaliy Kulikov <Vitaliy.Kulikov@idt.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - fix digital mic selection in mixer on 92HD8X codecs
Vitaliy Kulikov [Thu, 10 Mar 2011 01:47:43 +0000 (19:47 -0600)]
ALSA: hda - fix digital mic selection in mixer on 92HD8X codecs

When the mux for digital mic is different from the mux for other mics,
the current auto-parser doesn't handle them in a right way but provides
only one mic.  This patch fixes the issue.

Signed-off-by: Vitaliy Kulikov <Vitaliy.Kulikov@idt.com>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/hda' into for-next
Takashi Iwai [Mon, 14 Mar 2011 14:04:05 +0000 (15:04 +0100)]
Merge branch 'topic/hda' into for-next

13 years agoALSA: hda - Move default input-src selection to init part
Takashi Iwai [Thu, 10 Mar 2011 13:11:59 +0000 (14:11 +0100)]
ALSA: hda - Move default input-src selection to init part

Move the default input-src selection code for alc268/269 to the init
part instead of the parser.  The input-src selection might be overwritten
by init verbs.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: hda - Initialize special cases for input src in init phase
Takashi Iwai [Thu, 10 Mar 2011 11:51:11 +0000 (12:51 +0100)]
ALSA: hda - Initialize special cases for input src in init phase

Currently some special handling for the unusual case like dual-ADCs
or a single-input-src is done in the tree-parse time in
set_capture_mixer().  But this setup could be overwritten by static
init verbs.

This patch moves the initialization into the init phase so that
such input-src setup won't be lost.

Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Mon, 14 Mar 2011 10:44:31 +0000 (11:44 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: ctxfi - Clear input settings before initialization
Przemyslaw Bruski [Sun, 13 Mar 2011 15:18:58 +0000 (16:18 +0100)]
ALSA: ctxfi - Clear input settings before initialization

Clear input settings before initialization.

Signed-off-by: Przemyslaw Bruski <pbruskispam@op.pl>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: ctxfi - Fix SPDIF status retrieval
Przemyslaw Bruski [Sun, 13 Mar 2011 15:18:57 +0000 (16:18 +0100)]
ALSA: ctxfi - Fix SPDIF status retrieval

SDPIF status retrieval always returned the default settings instead of
the actual ones.

Signed-off-by: Przemyslaw Bruski <pbruskispam@op.pl>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: ctxfi - Fix incorrect SPDIF status bit mask
Przemyslaw Bruski [Sun, 13 Mar 2011 15:18:56 +0000 (16:18 +0100)]
ALSA: ctxfi - Fix incorrect SPDIF status bit mask

SPDIF status mask creation was incorrect.

Signed-off-by: Przemyslaw Bruski <pbruskispam@op.pl>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: ctxfi - Fix microphone boost codes/comments
Przemyslaw Bruski [Sun, 13 Mar 2011 15:18:55 +0000 (16:18 +0100)]
ALSA: ctxfi - Fix microphone boost codes/comments

microphone boost was set at +12dB, not +20dB (like in Windows driver
and in adc_conf structure declaration), some comments added.

Signed-off-by: Przemyslaw Bruski <pbruskispam@op.pl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Fri, 11 Mar 2011 14:47:51 +0000 (15:47 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: atiixp - Fix wrong time-out checks during ac-link reset
Takashi Iwai [Fri, 11 Mar 2011 14:45:32 +0000 (15:45 +0100)]
ALSA: atiixp - Fix wrong time-out checks during ac-link reset

The time-out in snd_atiixp_aclink_reset() is wrongly checked, and
it resulted in exiting from the loop at the first iteration.

Reported-by: Amir Shamsuddin <AmirS2+alsa@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Fri, 11 Mar 2011 14:22:23 +0000 (15:22 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: intel8x0m: append 'm' to "r_intel8x0"
Paul Bolle [Fri, 11 Mar 2011 10:41:06 +0000 (11:41 +0100)]
ALSA: intel8x0m: append 'm' to "r_intel8x0"

Appending an 'm' will distinguish it from a similar struct in intel8x0.c

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: intel8x0m: add 'm' as "suffix" to static functions
Paul Bolle [Fri, 11 Mar 2011 10:37:55 +0000 (11:37 +0100)]
ALSA: intel8x0m: add 'm' as "suffix" to static functions

Adding an 'm' will distinguish them from identical names in intel8x0.c.

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: intel8x0m: wait a bit before warm reset check
Paul Bolle [Fri, 11 Mar 2011 10:24:52 +0000 (11:24 +0100)]
ALSA: intel8x0m: wait a bit before warm reset check

At every resume a laptop I use prints this message (at KERN_ERR level):
    ALSA sound/pci/intel8x0m.c:904: AC'97 warm reset still in progress? [0x2]

The thing to note here is that 0x2 corresponds to ICH_AC97COLD. Ie, what
seems to be happening is that the register involved indicated a warm
reset for some time (as the ICH_AC97WARM bit was set) but by the time
the warning is printed, and that same register is checked again, that
bit is already cleared and only the ICH_AC97COLD bit is still set.

It turns out a warm reset needs some time to settle, but it is currently
checked right away. The test therefore fails the first time it is done
and schedule_timeout_uninterruptible() will be called. Once we return
from that jiffies is already (far) past end_time on this laptop, so we
exit the loop, print a warning, and exit the function while the warm
reset actually succeeded.

A way to fix this is to call usleep_range() after writing to the
register involved. A handful of tests suggest 500 usecs is a safe value.
(This might punish the "finish cold reset" case, but on this laptop such
a cold reset apparently never happens, so I can't say for sure.)

While we're at it drop the extra single tick from end_time, as it looks
rather silly.

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Fri, 11 Mar 2011 14:02:25 +0000 (15:02 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: usbaudio: implement USB autosuspend
Oliver Neukum [Fri, 11 Mar 2011 13:51:12 +0000 (14:51 +0100)]
ALSA: usbaudio: implement USB autosuspend

Devices are autosuspended if no pcm nor midi channel is open
Mixer devices may be opened. This way they are active when
in use to play or record sound, but can be suspended while
users have a mixer application running.

[Small clean-ups using static inline by tiwai]

Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: usbaudio: fix suspend/resume
Oliver Neukum [Fri, 11 Mar 2011 12:19:43 +0000 (13:19 +0100)]
ALSA: usbaudio: fix suspend/resume

- ESHUTDOWN must be correctly handled
- the optional interrupt endpoint's URB must be stopped and restarted

Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'fix/misc' into topic/misc
Takashi Iwai [Fri, 11 Mar 2011 13:48:09 +0000 (14:48 +0100)]
Merge branch 'fix/misc' into topic/misc

13 years agoASoC: Fix spacing in MAX8950
Mark Brown [Fri, 11 Mar 2011 12:07:31 +0000 (12:07 +0000)]
ASoC: Fix spacing in MAX8950

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: PXA: Z2: Fix codec pin name
Vasily Khoruzhick [Fri, 11 Mar 2011 09:05:38 +0000 (11:05 +0200)]
ASoC: PXA: Z2: Fix codec pin name

MONO was renamed to MONO1.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
13 years agoASoC: PXA: z2: Mute internal speaker when headphones are connected
Vasily Khoruzhick [Fri, 11 Mar 2011 09:05:37 +0000 (11:05 +0200)]
ASoC: PXA: z2: Mute internal speaker when headphones are connected

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoASoC: Add MAX9850 codec driver
Christian Glindkamp [Wed, 9 Mar 2011 10:20:04 +0000 (11:20 +0100)]
ASoC: Add MAX9850 codec driver

This patch adds ASoC support for the MAX9850 codec with headphone
amplifier.

Supported features:
- Playback
- 16, 20 and 24 bit audio
- 8k - 48k sample rates
- DAPM

Signed-off-by: Christian Glindkamp <christian.glindkamp@taskit.de>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoALSA: Add snd_ctl_activate_id()
Takashi Iwai [Fri, 29 Aug 2008 14:09:01 +0000 (16:09 +0200)]
ALSA: Add snd_ctl_activate_id()

Added a new API function snd_ctl_activate_id() for activate / inactivate
the control element dynamically.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoMerge branch 'topic/hda' into for-next
Takashi Iwai [Thu, 10 Mar 2011 16:45:14 +0000 (17:45 +0100)]
Merge branch 'topic/hda' into for-next

13 years agoALSA: hda: Prevent writing ICH6_PCIREG_TCSEL on AMD systems
Adam Lackorzynski [Thu, 10 Mar 2011 16:41:56 +0000 (17:41 +0100)]
ALSA: hda: Prevent writing ICH6_PCIREG_TCSEL on AMD systems

azx_init_pci() always writes PCI config register ICH6_PCIREG_TCSEL
although this looks to be only defined on Intel systems and has a
different meaning on AMD systems. On AMD systems the PCI interrupt pin
control register is modified instead.

Since the meaning of offset 0x44 in device specific configuration space is
unknown for devices by other vendors, we only exclude AMD systems to
retain the current behaviour.

Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/hda' into for-next
Takashi Iwai [Thu, 10 Mar 2011 16:36:58 +0000 (17:36 +0100)]
Merge branch 'topic/hda' into for-next

13 years agoALSA: HDA: Realtek ALC88x: Do not over-initialize speakers and hp that are primary...
David Henningsson [Fri, 4 Mar 2011 15:54:52 +0000 (16:54 +0100)]
ALSA: HDA: Realtek ALC88x: Do not over-initialize speakers and hp that are primary outputs

Do not initialize again the what has already been initialized as
multi outs, as this breaks surround speakers.

Tested-by: Bartłomiej Żogała <nusch88@gmail.com>
Cc: <stable@kernel.org>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: HDA: Fixup unnecessary volume control index on Realtek ALC88x
David Henningsson [Fri, 4 Mar 2011 13:22:25 +0000 (14:22 +0100)]
ALSA: HDA: Fixup unnecessary volume control index on Realtek ALC88x

Without this change, a volume control named "Surround" or "Side" would
get an unnecessary index, causing it to be ignored by the vmaster and
PulseAudio.

Tested-by: Bartłomiej Żogała <nusch88@gmail.com>
Cc: <stable@kernel.org>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: HDA: Fix volume control naming for surround speakers on Realtek auto-parser
David Henningsson [Fri, 4 Mar 2011 13:08:30 +0000 (14:08 +0100)]
ALSA: HDA: Fix volume control naming for surround speakers on Realtek auto-parser

When more than one pair of internal speakers is present, allow names
according to their channels.

Tested-by: Bartłomiej Żogała <nusch88@gmail.com>
Cc: <stable@kernel.org>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: HDA: Enable surround and subwoofer on Lenovo Ideapad Y530
David Henningsson [Fri, 4 Mar 2011 12:37:50 +0000 (13:37 +0100)]
ALSA: HDA: Enable surround and subwoofer on Lenovo Ideapad Y530

The pin config values would change the association instead of the
sequence, this commit fixes that up.

Tested-by: Bartłomiej Żogała <nusch88@gmail.com>
Cc: <stable@kernel.org>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Thu, 10 Mar 2011 15:48:55 +0000 (16:48 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: usb-audio - Add "cval->res = 384" quirk for Logitech Webcam C600
Alexey Fisher [Thu, 10 Mar 2011 13:53:39 +0000 (14:53 +0100)]
ALSA: usb-audio - Add "cval->res = 384" quirk for Logitech Webcam C600

One more affected devices: Logitech Webcam C600 (046d:0808)

Volume range before quirk is 6400, after (also real) is 16.

Signed-off-by: Alexey Fisher <bug-track@fisher-privat.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: usb-audio - Add volume range check and warn if it too big
Alexey Fisher [Thu, 10 Mar 2011 13:53:38 +0000 (14:53 +0100)]
ALSA: usb-audio - Add volume range check and warn if it too big

Signed-off-by: Alexey Fisher <bug-track@fisher-privat.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/asoc' into for-next
Takashi Iwai [Thu, 10 Mar 2011 15:04:09 +0000 (16:04 +0100)]
Merge branch 'topic/asoc' into for-next

13 years agoMerge branch 'for-2.6.38' into for-2.6.39
Mark Brown [Thu, 10 Mar 2011 14:16:35 +0000 (14:16 +0000)]
Merge branch 'for-2.6.38' into for-2.6.39

13 years agoASoC: Ensure WM8958 gets all WM8994 late revision widgets
Mark Brown [Wed, 9 Mar 2011 19:10:15 +0000 (19:10 +0000)]
ASoC: Ensure WM8958 gets all WM8994 late revision widgets

Without this fix the driver won't instantiate properly on relevant
devices.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Cc: stable@kernel.org
13 years agoASoC: Fix typo in late revision WM8994 DAC2R name
Mark Brown [Wed, 9 Mar 2011 19:09:17 +0000 (19:09 +0000)]
ASoC: Fix typo in late revision WM8994 DAC2R name

Without this fix the driver won't instantiate properly on relevant
devices.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Cc: stable@kernel.org
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Wed, 9 Mar 2011 19:11:17 +0000 (20:11 +0100)]
Merge branch 'topic/misc' into for-next

13 years agosound: Use sound_register_*() for additional OSS minor devices
Takashi Iwai [Wed, 9 Mar 2011 16:33:48 +0000 (17:33 +0100)]
sound: Use sound_register_*() for additional OSS minor devices

Since OSS driver creates the device entries for /dev/audio* and
/dev/dspW* by itself without coping with sound_core, it leads to
conflicts with others and let sysfs spewing warnings.

This patch rewrites the registration part of OSS driver to use
the standard method also for additional minor devices.

Reported-by: Steven Rostedt <rostedt@goodmis.org> (with ktest.pl)
Tested-by: Steven Rostedt <rostedt@goodmis.org> (with ktest.pl)
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'fix/asoc' into for-next
Takashi Iwai [Wed, 9 Mar 2011 19:09:59 +0000 (20:09 +0100)]
Merge branch 'fix/asoc' into for-next

13 years agoASoC: Enable 192kHz sample rate for EP93xx.
Alexander Sverdlin [Mon, 7 Mar 2011 17:30:12 +0000 (20:30 +0300)]
ASoC: Enable 192kHz sample rate for EP93xx.

Enable 192kHz sample rate for EP93xx.

Signed-off-by: Alexander Sverdlin <subaparts@yandex.ru>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoASoC: Improve EP93xx I2S clocks management.
Alexander Sverdlin [Mon, 7 Mar 2011 17:30:36 +0000 (20:30 +0300)]
ASoC: Improve EP93xx I2S clocks management.

Improve EP93xx I2S clocks management.
Some freqs values are set not exact as they requested for MCLK and
original code was not able to find divisors for SCLK and LRCLK.
This code just picks up nearest value from 3 possible variants.
This patch makes 44100 and 192000 rates working and fixes
capture function (by selecting SCLK/LRCLK=64 where possible).
All other rates should work as before.

Signed-off-by: Alexander Sverdlin <subaparts@yandex.ru>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoASoC: EDB93xx: Manage I2S rates according to datasheet for CS4271 CODEC.
Alexander Sverdlin [Mon, 7 Mar 2011 17:29:53 +0000 (20:29 +0300)]
ASoC: EDB93xx: Manage I2S rates according to datasheet for CS4271 CODEC.

Manage I2S rates according to datasheet for CS4271 CODEC in EDB93xx
machine driver.

Signed-off-by: Alexander Sverdlin <subaparts@yandex.ru>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoASoC: Manage mode and rate bits correctly for CS4271 CODEC.
Alexander Sverdlin [Mon, 7 Mar 2011 17:29:45 +0000 (20:29 +0300)]
ASoC: Manage mode and rate bits correctly for CS4271 CODEC.

Manage mode and rate bits correctly, according to datasheet in CS4271 CODEC.
This is done to make capture work properly.

Signed-off-by: Alexander Sverdlin <subaparts@yandex.ru>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoMerge branch 'for-2.6.38' into for-2.6.39
Mark Brown [Wed, 9 Mar 2011 12:37:42 +0000 (12:37 +0000)]
Merge branch 'for-2.6.38' into for-2.6.39

Conflicts:
sound/soc/codecs/wm8978.c
sound/soc/soc-dapm.c

13 years agoASoC: Fix double addition of prefixes due to widget prefixing
Mark Brown [Wed, 9 Mar 2011 11:33:09 +0000 (11:33 +0000)]
ASoC: Fix double addition of prefixes due to widget prefixing

We're not only prefixing all controls, we're also prefixing the widget
names in the runtime data. This causes us to add the prefix twice - once
when using the widget name to generate the control name and once when
adding the control.

Really we shouldn't be prefixing the widget names at all, the matching
code should be handing this as we always know which DAPM context a
widget came from and always display the widget name in terms of a DAPM
context.  However, we're quite close to the merge window and that's
relatively invasive.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Reported-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Use the correct DAPM context when cleaning up final widget set
Mark Brown [Tue, 8 Mar 2011 19:29:53 +0000 (19:29 +0000)]
ASoC: Use the correct DAPM context when cleaning up final widget set

Now we've got multi-component we need to make sure that the DAPM context
(and hence register I/O context) we use to apply the pending updates at
the end of a DAPM sequence is the one we were processing rather than the
one that was used to initate the state change.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
13 years agoASoC: Fix broken bitfield definitions in WM8978
Mark Brown [Wed, 2 Mar 2011 11:01:18 +0000 (11:01 +0000)]
ASoC: Fix broken bitfield definitions in WM8978

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Cc: stable@kernel.org
13 years agoASoC: Simplify WM9081 speaker startup by using widgets for spaker output
Mark Brown [Tue, 8 Mar 2011 18:52:08 +0000 (18:52 +0000)]
ASoC: Simplify WM9081 speaker startup by using widgets for spaker output

Now we have a register write minimisation code in DAPM we don't need to
worry about the ordering of the enable and disable of the PGA and the
output stage.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
13 years agoASoC: AM3517: Update codec name after multi-component update
Abhilash K V [Tue, 8 Mar 2011 15:32:43 +0000 (21:02 +0530)]
ASoC: AM3517: Update codec name after multi-component update

The i2c client device name (".2-001a" in this case, including
the separator period) for the AIC23 codec on the TI AM3517-EVM
was appended to the codec_name member of am3517evm_dai to
resolve the names mismatch happening in soc_bind_dai_link(),
due to which the card was not getting registered.

Signed-off-by: Abhilash K V <abhilash.kv@ti.com>
Acked-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
13 years agoASoC: omap: rx51: Enable McBSP2 sidetone
Jarkko Nikula [Wed, 9 Mar 2011 09:25:00 +0000 (11:25 +0200)]
ASoC: omap: rx51: Enable McBSP2 sidetone

McBSP sidetone is needed in telephony applications. McBSP sidetone is a
configurable FIR filter that forms a loopback from McBSP input to output.
This patch enables the McBSP2 sidetone ALSA controls so that it can be used
on Nokia RX-51/N900.

Sidetone feature can be tested with following commands:

(set up codec input and output paths)
# Enable and configure sidetone
amixer -D hw:0 set 'McBSP2 Sidetone' on
amixer set -D hw:0 'McBSP2 Sidetone Channel 0' 32767
echo 32767 >/sys/devices/platform/omap-mcbsp.2/st_taps
# Do not loop audio via CPU
arecord -f dat >/dev/null |aplay /dev/zero

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
13 years agoASoC: sgtl5000: use after free in ldo_regulator_register()
Dan Carpenter [Tue, 8 Mar 2011 11:39:24 +0000 (14:39 +0300)]
ASoC: sgtl5000: use after free in ldo_regulator_register()

The "ldo" variable was dereferenced after free on the error path.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoASoC: Fix prefixing of DAPM controls by factoring prefix into snd_soc_cnew()
Mark Brown [Tue, 8 Mar 2011 17:23:24 +0000 (17:23 +0000)]
ASoC: Fix prefixing of DAPM controls by factoring prefix into snd_soc_cnew()

Currently will ignore prefixes when creating DAPM controls. Since currently
all control creation goes through snd_soc_cnew() we can fix this by factoring
the prefixing into that function.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Warn rather than set a silly constraint when we can't do symmetry
Mark Brown [Tue, 8 Mar 2011 00:17:56 +0000 (00:17 +0000)]
ASoC: Warn rather than set a silly constraint when we can't do symmetry

Symmetric rate configuration can fail if the second stream starting tries
to apply the symmetric constraint before the first stream has got far
enough to pick a rate. Rather than try to enforce a nonsensical rate of
0Hz log a warning and allow the application to carry on. Things might go
wrong later on but the user will know about it and there's unlikely to be
lasting damage.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Refactor symmetric_rates check to reduce indentation
Mark Brown [Tue, 8 Mar 2011 00:11:15 +0000 (00:11 +0000)]
ASoC: Refactor symmetric_rates check to reduce indentation

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Convert WM9081 SYSCLK configuration to be device wide
Mark Brown [Mon, 7 Mar 2011 20:59:45 +0000 (20:59 +0000)]
ASoC: Convert WM9081 SYSCLK configuration to be device wide

Also respace the CODEC ops a bit for legibility.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Provide CODEC clocking operations and API calls
Mark Brown [Mon, 7 Mar 2011 20:58:11 +0000 (20:58 +0000)]
ASoC: Provide CODEC clocking operations and API calls

When multi component systems use DAIless amplifiers which require clocking
configuration it is at best hard to use the current clocking API as this
requires a DAI even though the device may not even have one. Address this
by adding set_sysclk() and set_pll() operations and APIs for CODECs.

In order to avoid issues with devices which could be used either with or
without DAIs make the DAI variants call through to their CODEC counterparts
if there is no DAI specific operation. Converting over entirely would create
problems for multi-DAI devices which offer per-DAI clocking setup.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Fix section mismatch warnings in WM8994
Mark Brown [Mon, 7 Mar 2011 16:42:20 +0000 (16:42 +0000)]
ASoC: Fix section mismatch warnings in WM8994

Annoying as the __devinitdata is actually correct.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Use data based init for WM9081 DAPM
Mark Brown [Mon, 7 Mar 2011 16:39:50 +0000 (16:39 +0000)]
ASoC: Use data based init for WM9081 DAPM

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoASoC: Add DAPM widget and path data to CODEC driver structure
Mark Brown [Mon, 7 Mar 2011 16:38:44 +0000 (16:38 +0000)]
ASoC: Add DAPM widget and path data to CODEC driver structure

Allow a slight simplification of CODEC drivers by allowing DAPM routes and
widgets to be provided in a table. They will be instantiated at the end of
CODEC probe.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Tue, 8 Mar 2011 17:21:39 +0000 (18:21 +0100)]
Merge branch 'topic/misc' into for-next

13 years agoALSA: asihpi - Use %zd for size_t argument in error message
Takashi Iwai [Tue, 8 Mar 2011 17:20:46 +0000 (18:20 +0100)]
ALSA: asihpi - Use %zd for size_t argument in error message

Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoMerge branch 'topic/hda' into for-next
Takashi Iwai [Tue, 8 Mar 2011 17:18:03 +0000 (18:18 +0100)]
Merge branch 'topic/hda' into for-next

13 years agoMerge branch 'topic/asoc' into for-next
Takashi Iwai [Tue, 8 Mar 2011 17:17:43 +0000 (18:17 +0100)]
Merge branch 'topic/asoc' into for-next

13 years agoMerge branch 'topic/misc' into for-next
Takashi Iwai [Tue, 8 Mar 2011 12:00:57 +0000 (13:00 +0100)]
Merge branch 'topic/misc' into for-next