Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ALSA: compress: Pass through return value of open ops callback

The snd_compr_open function would always return 0 even if the compressed
ops open function failed, obviously this is incorrect. Looks like this
was introduced by a small typo in:

commit a0830dbd4e42b38aefdf3fb61ba5019a1a99ea85
ALSA: Add a reference counter to card instance

This patch returns the value from the compressed op as it should.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>

authored by

Charles Keepax and committed by
Takashi Iwai
749d3223 30556441

+1 -1
+1 -1
sound/core/compress_offload.c
··· 133 133 kfree(data); 134 134 } 135 135 snd_card_unref(compr->card); 136 - return 0; 136 + return ret; 137 137 } 138 138 139 139 static int snd_compr_free(struct inode *inode, struct file *f)