]> git.baikalelectronics.ru Git - kernel.git/commit
ALSA: usb: Work around CM6631 sample rate change bug
authorTorstein Hegge <hegge@resisty.net>
Tue, 26 Mar 2013 21:10:05 +0000 (22:10 +0100)
committerTakashi Iwai <tiwai@suse.de>
Wed, 3 Apr 2013 15:05:44 +0000 (17:05 +0200)
commit0ba575069477e3e6e17dc3c94f97d2323128da0f
treeae4e3032c9b17fbd355776557bfc24e498e37e82
parent95b1e35776a0f1d2125684ab56a49a226460b837
ALSA: usb: Work around CM6631 sample rate change bug

The C-Media CM6631 USB receiver doesn't respond to changes in sample rate
while the interface is active. The same behavior is observed in other UAC2
hardware like the VIA VT1731.

Reset the interface after setting the sampling frequency on sample rate
changes, to ensure that the sample rate set by snd_usb_init_sample_rate() is
used. Otherwise, the device will try to use the sample rate of the previous
stream, causing distorted sound on sample rate changes.

The reset is performed for all UAC2 devices, as it should not affect a
standards compliant device, but it is only necessary for C-Media CM6631,
VIA VT1731 and possibly others.

Failure to read sample rate from the device is not handled as an error in
set_sample_rate_v2(), as (permanent or intermittent) failure to read sample
rate isn't essential for a successful sample rate set.

Signed-off-by: Torstein Hegge <hegge@resisty.net>
Acked-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/usb/clock.c