]> git.baikalelectronics.ru Git - kernel.git/commit
sound: pcm_lib: fix unsorted list constraint handling
authorClemens Ladisch <clemens@ladisch.de>
Tue, 25 Aug 2009 06:15:41 +0000 (08:15 +0200)
committerTakashi Iwai <tiwai@suse.de>
Tue, 25 Aug 2009 06:52:34 +0000 (08:52 +0200)
commit589ac818c5881330f930330d06a57590745cae3b
tree60d48ea825579d8df50836fd921668a2320adbe6
parente895cb3780c8ea07ec8813293fc589d16d4483d5
sound: pcm_lib: fix unsorted list constraint handling

snd_interval_list() expected a sorted list but did not document this, so
there are drivers that give it an unsorted list.  To fix this, change
the algorithm to work with any list.

This fixes the "Slave PCM not usable" error with USB devices that have
multiple alternate settings with sample rates in decreasing order, such
as the Philips Askey VC010 WebCam.

http://bugzilla.kernel.org/show_bug.cgi?id=14028

Reported-and-tested-by: Andrzej <adkadk@gmail.com>
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/core/pcm_lib.c