summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>2020-01-13 17:46:28 +0900
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-01-23 08:21:28 +0100
commite68bc5ef7dcb69fbd3009914129e2c1ddda58a6b (patch)
tree8fc094f8a9df920e50ee50985c954c06b24e0152 /sound
parent6a75df0c648dff084d889d99dd186f96dce2f976 (diff)
downloadlinux-stable-e68bc5ef7dcb69fbd3009914129e2c1ddda58a6b.tar.gz
linux-stable-e68bc5ef7dcb69fbd3009914129e2c1ddda58a6b.tar.bz2
linux-stable-e68bc5ef7dcb69fbd3009914129e2c1ddda58a6b.zip
ALSA: dice: fix fallback from protocol extension into limited functionality
commit 3e2dc6bdb56893bc28257e482e1dbe5d39f313df upstream. At failure of attempt to detect protocol extension, ALSA dice driver should be fallback to limited functionality. However it's not. This commit fixes it. Cc: <stable@vger.kernel.org> # v4.18+ Fixes: 58579c056c1c9 ("ALSA: dice: use extended protocol to detect available stream formats") Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Link: https://lore.kernel.org/r/20200113084630.14305-2-o-takashi@sakamocchi.jp Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'sound')
-rw-r--r--sound/firewire/dice/dice-extension.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/firewire/dice/dice-extension.c b/sound/firewire/dice/dice-extension.c
index a63fcbc875ad..02f4a8318e38 100644
--- a/sound/firewire/dice/dice-extension.c
+++ b/sound/firewire/dice/dice-extension.c
@@ -159,8 +159,11 @@ int snd_dice_detect_extension_formats(struct snd_dice *dice)
int j;
for (j = i + 1; j < 9; ++j) {
- if (pointers[i * 2] == pointers[j * 2])
+ if (pointers[i * 2] == pointers[j * 2]) {
+ // Fallback to limited functionality.
+ err = -ENXIO;
goto end;
+ }
}
}