This is a note to let you know that I've just added the patch titled

    ALSA: snd-usb-caiaq: fix stream count check

to the 3.18-stable tree which can be found at:
    
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     alsa-snd-usb-caiaq-fix-stream-count-check.patch
and it can be found in the queue-3.18 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.


>From 49cdd5b641933fda6324fc901eaf856924ba6a27 Mon Sep 17 00:00:00 2001
From: Daniel Mack <[email protected]>
Date: Sun, 4 Jan 2015 19:59:29 +0100
Subject: ALSA: snd-usb-caiaq: fix stream count check

From: Daniel Mack <[email protected]>

commit 49cdd5b641933fda6324fc901eaf856924ba6a27 upstream.

Commit 897c329bc ("ALSA: usb: caiaq: check for cdev->n_streams > 1")
introduced a safety check to protect against bogus data provided by
devices. However, the n_streams variable is already divided by
CHANNELS_PER_STREAM, so the correct check is 'n_streams > 0'.

Fix this to un-break support for stereo devices.

Signed-off-by: Daniel Mack <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>

---
 sound/usb/caiaq/audio.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/sound/usb/caiaq/audio.c
+++ b/sound/usb/caiaq/audio.c
@@ -816,7 +816,7 @@ int snd_usb_caiaq_audio_init(struct snd_
                return -EINVAL;
        }
 
-       if (cdev->n_streams < 2) {
+       if (cdev->n_streams < 1) {
                dev_err(dev, "bogus number of streams: %d\n", cdev->n_streams);
                return -EINVAL;
        }


Patches currently in stable-queue which might be from [email protected] are

queue-3.18/alsa-snd-usb-caiaq-fix-stream-count-check.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to