aboutsummaryrefslogtreecommitdiffstats
path: root/sound/core/pcm_compat.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2018-04-25 10:41:08 +0200
committerTakashi Iwai <tiwai@suse.de>2018-04-25 16:44:36 +0200
commit4d31c6e41ed2f95f97a19766812797dabd82a5ee (patch)
treee1f81f4f0108ff86f85b8e17b025b21609aec7b2 /sound/core/pcm_compat.c
parentALSA: hda - Sanity check of access to SPDIF controls array (diff)
parentALSA: hda - Skip jack and others for non-existing PCM streams (diff)
downloadlinux-dev-4d31c6e41ed2f95f97a19766812797dabd82a5ee.tar.xz
linux-dev-4d31c6e41ed2f95f97a19766812797dabd82a5ee.zip
Merge branch 'for-linus' into for-next
Back-merge 4.17-rc3 fixes for further development. This will bump the base to 4.17-rc2, too. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/core/pcm_compat.c')
-rw-r--r--sound/core/pcm_compat.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sound/core/pcm_compat.c b/sound/core/pcm_compat.c
index 0be248543f1e..077008a8e1d5 100644
--- a/sound/core/pcm_compat.c
+++ b/sound/core/pcm_compat.c
@@ -27,10 +27,11 @@ static int snd_pcm_ioctl_delay_compat(struct snd_pcm_substream *substream,
s32 __user *src)
{
snd_pcm_sframes_t delay;
+ int err;
- delay = snd_pcm_delay(substream);
- if (delay < 0)
- return delay;
+ err = snd_pcm_delay(substream, &delay);
+ if (err)
+ return err;
if (put_user(delay, src))
return -EFAULT;
return 0;