]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
ALSA: usb-audio: Fix packet size calculation regression
authorTakashi Iwai <tiwai@suse.de>
Fri, 1 Oct 2021 10:54:25 +0000 (12:54 +0200)
committerPaolo Pisati <paolo.pisati@canonical.com>
Thu, 9 Dec 2021 10:10:24 +0000 (11:10 +0100)
commita769a05effc9cb655a1eee40539244d67d0ac5f2
tree5fd99a1007aaaa37d64397447f432c87fe47e82b
parenta1b8c1bd256413851f9a5bc95b2c5b1f03527ffb
ALSA: usb-audio: Fix packet size calculation regression

BugLink: https://bugs.launchpad.net/bugs/1953731
commit 23939115be181bc5dbc33aa8471adcdbffa28910 upstream.

The commit d215f63d49da ("ALSA: usb-audio: Check available frames for
the next packet size") introduced the available frame size check, but
the conversion forgot to initialize the temporary variable properly,
and it resulted in a bogus calculation.  This patch fixes it.

Fixes: d215f63d49da ("ALSA: usb-audio: Check available frames for the next packet size")
Reported-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20211001104417.14291-1-colin.king@canonical.com
Link: https://lore.kernel.org/r/20211001105425.16191-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
sound/usb/endpoint.c