summaryrefslogtreecommitdiff
path: root/sound/core
diff options
context:
space:
mode:
authorVinod Koul <vinod.koul@intel.com>2013-07-29 15:10:22 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-08-11 15:38:41 -0700
commit353f59cac39bdcf4f5100fae723780d4f24a4a2f (patch)
tree6e88c353a4a7efd6d17513457c2688aa131c7a1e /sound/core
parent7b17c57914788c370756ddc7ed8ca1b43394ef0f (diff)
downloadlwn-353f59cac39bdcf4f5100fae723780d4f24a4a2f.tar.gz
lwn-353f59cac39bdcf4f5100fae723780d4f24a4a2f.zip
ALSA: compress: fix the return value for SNDRV_COMPRESS_VERSION
commit a8d30608eaed6cc759b8e2e8a8bbbb42591f797f upstream. the return value of SNDRV_COMPRESS_VERSION always return default -ENOTTY as the return value was never updated for this call assign return value from put_user() Reported-by: Haynes <hgeorge@codeaurora.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'sound/core')
-rw-r--r--sound/core/compress_offload.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/core/compress_offload.c b/sound/core/compress_offload.c
index a58cf3594130..84717ce23371 100644
--- a/sound/core/compress_offload.c
+++ b/sound/core/compress_offload.c
@@ -582,7 +582,7 @@ static long snd_compr_ioctl(struct file *f, unsigned int cmd, unsigned long arg)
mutex_lock(&stream->device->lock);
switch (_IOC_NR(cmd)) {
case _IOC_NR(SNDRV_COMPRESS_IOCTL_VERSION):
- put_user(SNDRV_COMPRESS_VERSION,
+ retval = put_user(SNDRV_COMPRESS_VERSION,
(int __user *)arg) ? -EFAULT : 0;
break;
case _IOC_NR(SNDRV_COMPRESS_GET_CAPS):