Commit Graph

16469 Commits

Author SHA1 Message Date
Sun Mingjun
72e54fed64 rk312x : audio : fix the box audio crash bug when recording 2014-10-16 08:39:31 +08:00
Sun Mingjun
3b3c0c9b87 rk3128 codec : fixed the codec output bug for box 2014-09-29 08:15:05 +08:00
sugar
423f8a4057 Audio: spdif: add spdif card or not according dts define. 2014-09-28 21:48:20 +08:00
lxt
51bfb1cdab rk312x codec : add the ALC & AGC funtion of codec 2014-09-28 08:16:29 +08:00
lxt
74a5621d5e rk3128-sdk : add codec hp pin check hp interrupt 2014-09-26 10:53:36 +08:00
sugar
e0a50c334f Audio:
- update spdif driver.
- add spdif card, default disabled.
2014-09-11 11:08:16 +08:00
Sun Mingjun
bd7f36abd6 rk3036-codec : modified the debug print logic 2014-09-05 14:50:55 +08:00
Sun Mingjun
af83b4b66d rk312x-codec : Closed the debug print switch 2014-09-05 14:13:35 +08:00
hjc
599a16a283 audio: rk3036 codec: add init codec sample clock 2014-09-02 17:48:46 +08:00
hjc
ebce6fdb8f audio: rk3036 codec:
add rk3036 sound card unfinished function, If not,it not to
	set I2S clk and div,and lead to no sound on some TV.
2014-09-02 15:53:57 +08:00
lxt
c4568ed31a rk312x codec :
1 Optimized drive compatibility
	2 modified the volume to dts
2014-08-26 09:22:48 +08:00
Sun Mingjun
6f9799c3d1 rk3036 codec : optimize the startup sequence of codec 2014-08-21 15:15:12 +08:00
Sun Mingjun
c02c7deb95 codec : modified the codec debug level 2014-08-20 09:48:14 +08:00
Sun Mingjun
227e8f0536 codec modified :
- Changed name from spk_ctl to hp_ctl to Corresponding logic
	- Deleted some of Debugging Code
	- Add the support to fullalsa
2014-08-14 11:33:10 +08:00
Sun Mingjun
fc321ca0f2 spdif : changed the spdif device name to uniform naming 2014-08-14 09:34:18 +08:00
Sun Mingjun
f854ea25c4 codec : Support rk3126-sdk codec 2014-08-12 19:16:01 +08:00
Sun Mingjun
aea970bf5b Support the Rk312X Codec & SPDIF 2014-08-12 08:43:43 +08:00
dgl
65f991dd31 audio: rk3036 codec output waveform abnormalities
changed codec power up and codec start up time interval.
1. system power on and codec power on and codec initilize;
2. add delay work 15 second;
3. codec power up and codec initilize again;

Signed-off-by: dgl@rock-chips.com
2014-08-08 18:09:23 +08:00
黄涛
c7412991e9 Merge remote-tracking branch 'origin/develop-3.10' into develop-3.10-next
Conflicts:
	arch/arm/mach-rockchip/vcodec_service.c
	drivers/input/Makefile
2014-08-08 10:21:50 +08:00
黄涛
fcef60e36f Merge tag 'lsk-v3.10-android-14.07' into develop-3.10
LSK v3.10 Android 14.07 release

Conflicts:
	drivers/clocksource/arm_arch_timer.c
	lib/Makefile
2014-08-06 15:34:14 +08:00
dgl
d54505daaf audio: rk3036 spdif
debug rk3036 spdif, add DTS node and math dts node name.

Signed-off-by: dgl@rock-chips.com
2014-07-28 15:04:38 +08:00
dgl
b69daf1bd7 audio: rk3036 audio format check
change some scripts checkpatch ERROR and Warning,
do not care this version.

Signed-off-by: dgl@rock-chips.com
2014-07-28 10:46:53 +08:00
dgl
f3fcb4ab6a audio: rk3036 codec driver
add rk3036 audio codec driver program, include DTS node.

Signed-off-by: dgl@rock-chips.com
2014-07-28 10:07:40 +08:00
黄涛
678b7168ad ASoC: rockchip: rk30_i2s.c use pinctrl_pm_select_sleep_state
call pinctrl_select_state could trigger Oops when suspend
if pinctrl no configured.
2014-07-16 13:04:33 +08:00
Mark Brown
fa6e052947 Merge tag 'v3.10.48' into linux-linaro-lsk
This is the 3.10.48 stable release
2014-07-14 10:45:20 +01:00
Sander Eikelenboom
7b938dbb38 ALSA: usb-audio: Prevent printk ratelimiting from spamming kernel log while DEBUG not defined
commit b7a7723513 upstream.

This (widely used) construction:

if(printk_ratelimit())
	dev_dbg()

Causes the ratelimiting to spam the kernel log with the "callbacks suppressed"
message below, even while the dev_dbg it is supposed to rate limit wouldn't
print anything because DEBUG is not defined for this device.

[  533.803964] retire_playback_urb: 852 callbacks suppressed
[  538.807930] retire_playback_urb: 852 callbacks suppressed
[  543.811897] retire_playback_urb: 852 callbacks suppressed
[  548.815745] retire_playback_urb: 852 callbacks suppressed
[  553.819826] retire_playback_urb: 852 callbacks suppressed

So use dev_dbg_ratelimited() instead of this construction.

Signed-off-by: Sander Eikelenboom <linux@eikelenboom.it>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-09 11:14:02 -07:00
Tim Gardner
24ec54eece ALSA: usb-audio: Suppress repetitive debug messages from retire_playback_urb()
commit a5065eb6da upstream.

BugLink: http://bugs.launchpad.net/bugs/1305133

Malfunctioning or slow devices can cause a flood of dmesg SPAM.

I've ignored checkpatch.pl complaints about the use of printk_ratelimit() in favour
of prior art in sound/usb/pcm.c.

WARNING: Prefer printk_ratelimited or pr_<level>_ratelimited to printk_ratelimit
+	if (printk_ratelimit() &&

Cc: Jaroslav Kysela <perex@perex.cz>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: Eldad Zack <eldad@fogrefinery.com>
Cc: Daniel Mack <zonque@gmail.com>
Cc: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-09 11:14:02 -07:00
qjb
68bef378c7 rk616 codec : remove call function rk616_codec_power_up after
kfree rk616_priv.
2014-07-08 10:19:18 +08:00
qjb
cbf97455c2 rk616 codec: fixed rk616 codec shutdown function null pointer 2014-07-07 15:58:53 +08:00
Mark Brown
d01bd6fdb3 Merge tag 'v3.10.46' into linux-linaro-lsk
This is the 3.10.46 stable release
2014-07-01 11:19:52 +01:00
Lars-Peter Clausen
7fba24c6c9 ALSA: control: Make sure that id->index does not overflow
commit 883a1d49f0 upstream.

The ALSA control code expects that the range of assigned indices to a control is
continuous and does not overflow. Currently there are no checks to enforce this.
If a control with a overflowing index range is created that control becomes
effectively inaccessible and unremovable since snd_ctl_find_id() will not be
able to find it. This patch adds a check that makes sure that controls with a
overflowing index range can not be created.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:43 -04:00
Lars-Peter Clausen
0255758b24 ALSA: control: Handle numid overflow
commit ac902c112d upstream.

Each control gets automatically assigned its numids when the control is created.
The allocation is done by incrementing the numid by the amount of allocated
numids per allocation. This means that excessive creation and destruction of
controls (e.g. via SNDRV_CTL_IOCTL_ELEM_ADD/REMOVE) can cause the id to
eventually overflow. Currently when this happens for the control that caused the
overflow kctl->id.numid + kctl->count will also over flow causing it to be
smaller than kctl->id.numid. Most of the code assumes that this is something
that can not happen, so we need to make sure that it won't happen

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:43 -04:00
Lars-Peter Clausen
9abd948621 ALSA: control: Don't access controls outside of protected regions
commit fd9f26e4ec upstream.

A control that is visible on the card->controls list can be freed at any time.
This means we must not access any of its memory while not holding the
controls_rw_lock. Otherwise we risk a use after free access.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:43 -04:00
Lars-Peter Clausen
adbb1449cc ALSA: control: Fix replacing user controls
commit 82262a4662 upstream.

There are two issues with the current implementation for replacing user
controls. The first is that the code does not check if the control is actually a
user control and neither does it check if the control is owned by the process
that tries to remove it. That allows userspace applications to remove arbitrary
controls, which can cause a user after free if a for example a driver does not
expect a control to be removed from under its feed.

The second issue is that on one hand when a control is replaced the
user_ctl_count limit is not checked and on the other hand the user_ctl_count is
increased (even though the number of user controls does not change). This allows
userspace, once the user_ctl_count limit as been reached, to repeatedly replace
a control until user_ctl_count overflows. Once that happens new controls can be
added effectively bypassing the user_ctl_count limit.

Both issues can be fixed by instead of open-coding the removal of the control
that is to be replaced to use snd_ctl_remove_user_ctl(). This function does
proper permission checks as well as decrements user_ctl_count after the control
has been removed.

Note that by using snd_ctl_remove_user_ctl() the check which returns -EBUSY at
beginning of the function if the control already exists is removed. This is not
a problem though since the check is quite useless, because the lock that is
protecting the control list is released between the check and before adding the
new control to the list, which means that it is possible that a different
control with the same settings is added to the list after the check. Luckily
there is another check that is done while holding the lock in snd_ctl_add(), so
we'll rely on that to make sure that the same control is not added twice.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:43 -04:00
Lars-Peter Clausen
be3bae536e ALSA: control: Protect user controls against concurrent access
commit 07f4d9d74a upstream.

The user-control put and get handlers as well as the tlv do not protect against
concurrent access from multiple threads. Since the state of the control is not
updated atomically it is possible that either two write operations or a write
and a read operation race against each other. Both can lead to arbitrary memory
disclosure. This patch introduces a new lock that protects user-controls from
concurrent access. Since applications typically access controls sequentially
than in parallel a single lock per card should be fine.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:43 -04:00
David Henningsson
9c2f4849d7 ALSA: hda - Add quirk for external mic on Lifebook U904
commit 2041d56464 upstream.

According to the bug reporter (Данило Шеган), the external mic
starts to work and has proper jack detection if only pin 0x19
is marked properly as an external headset mic.

AlsaInfo at https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/1328587/+attachment/4128991/+files/AlsaInfo.txt

BugLink: https://bugs.launchpad.net/bugs/1328587
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:42 -04:00
Kailang Yang
f0fc130193 ALSA: hda/realtek - Add support of ALC891 codec
commit b6c5fbad16 upstream.

New codec support for ALC891.

Signed-off-by: Kailang Yang <kailang@realtek.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:42 -04:00
Liam Girdwood
7f8954f534 ASoC: max98090: Fix reset at resume time
commit 25b4ab430f upstream.

Reset needs to wait 20ms before other codec IO is performed. This wait
was not being performed. Fix this by making sure the reset register is not
restored with the cache, but use the manual reset method in resume with
the wait.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:12:40 -04:00
Mark Brown
9921b8dc1f Merge remote-tracking branch 'lsk/v3.10/topic/asoc-compress' into linux-linaro-lsk 2014-06-16 20:14:27 +01:00
Liam Girdwood
a3f2705d8f ASoC: compress: Add suport for DPCM into compressed audio
Currently compressed audio streams are statically routed from the /dev
to the DAI link. Some DSPs can route compressed data to multiple BE DAIs
like they do for PCM data.

Add support to allow dynamically routed compressed streams using the existing
DPCM infrastructure. This patch adds special FE versions of the compressed ops
that work out the runtime routing.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
(cherry picked from commit 2a99ef0fdb)
Signed-off-by: Mark Brown <broonie@linaro.org>
2014-06-16 20:13:16 +01:00
Liam Girdwood
d83ee12388 ASoC: DPCM: make some DPCM API calls non static for compressed usage
The ASoC compressed code needs to call the internal DPCM APIs in order to
dynamically route compressed data to different DAIs.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
(cherry picked from commit 2360702530)
Signed-off-by: Mark Brown <broonie@linaro.org>
2014-06-16 20:13:15 +01:00
Vinod Koul
e978ae4553 ASoC: compress: use soc_xxx handlers for metadata
the compress metadata handlers were wrongly named sst_xxx

Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
(cherry picked from commit 02bd90e86d)
Signed-off-by: Mark Brown <broonie@linaro.org>
2014-06-16 20:13:15 +01:00
qjb
8e40f31c56 rt5616 : add hp change pump config and spk io control remove 2014-06-16 13:45:10 +08:00
zyh
03f5932e5f audio:fix last audio commit 2014-06-16 09:50:49 +08:00
zyh
c2083886bd audio:fix some compile log 2014-06-13 21:15:44 +08:00
zyh
c8c71c5b84 spdif:fix hclk 2014-06-13 20:38:58 +08:00
黄涛
ee25a425b9 Merge tag 'lsk-android-14.05' into develop-3.10
lsk 14.05 android release

Conflicts:
	arch/arm/common/Kconfig
	arch/arm64/include/asm/arch_timer.h
	drivers/staging/android/fiq_debugger/fiq_debugger.c
	drivers/usb/Kconfig
2014-06-12 21:04:26 +08:00
Alex Shi
5f00470fca Merge tag v3.10.43 into linux-linaro-lsk
This is the 3.10.43 stable release
2014-06-12 15:01:53 +08:00
qjb
511f054f86 audio codec : remove compiler warnings 2014-06-12 09:33:24 +08:00
Takashi Iwai
873428ffd7 ALSA: hda/realtek - Fix COEF widget NID for ALC260 replacer fixup
commit 192a98e280 upstream.

The conversion to a fixup table for Replacer model with ALC260 in
commit 20f7d928 took the wrong widget NID for COEF setups.  Namely,
NID 0x1a should have been used instead of NID 0x20, which is the
common node for all Realtek codecs but ALC260.

Fixes: 20f7d928fa ('ALSA: hda/realtek - Replace ALC260 model=replacer with the auto-parser')
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-11 12:03:25 -07:00