diff options
| author | isaki <isaki@NetBSD.org> | 2017-10-21 09:02:23 +0000 |
|---|---|---|
| committer | isaki <isaki@NetBSD.org> | 2017-10-21 09:02:23 +0000 |
| commit | 2d3bb86caaf025d0f689e774b3c39e2b30fb639f (patch) | |
| tree | ebb634d8743fccadb0a4db4b177f2fc5f305dd41 /sys/dev | |
| parent | be7dee3ed8e7a998b652d7782254ff45004dd51b (diff) | |
Fix return value. fo_mmap is expected to return errno on error.
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/audio.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/audio.c b/sys/dev/audio.c index 5eb3b5d9bd3..e5002dacad4 100644 --- a/sys/dev/audio.c +++ b/sys/dev/audio.c @@ -1,4 +1,4 @@ -/* $NetBSD: audio.c,v 1.410 2017/10/01 21:49:20 nat Exp $ */ +/* $NetBSD: audio.c,v 1.411 2017/10/21 09:02:23 isaki Exp $ */ /*- * Copyright (c) 2016 Nathanial Sloss <nathanialsloss@yahoo.com.au> @@ -148,7 +148,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.410 2017/10/01 21:49:20 nat Exp $"); +__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.411 2017/10/21 09:02:23 isaki Exp $"); #ifdef _KERNEL_OPT #include "audio.h" @@ -1952,7 +1952,7 @@ audio_fop_mmap(struct file *fp, off_t *offp, size_t len, int prot, int *flagsp, error = 0; if ((error = audio_enter(dev, RW_READER, &sc)) != 0) - return 1; + return error; device_active(sc->dev, DVA_SYSTEM); /* XXXJDM */ switch (AUDIODEV(dev)) { |
