Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/audio Add missing mutex, we were hitting a KASSERT.
details: https://anonhg.NetBSD.org/src/rev/9b476930de32
branches: trunk
changeset: 964947:9b476930de32
user: maxv <maxv%NetBSD.org@localhost>
date: Fri Aug 23 09:41:26 2019 +0000
description:
Add missing mutex, we were hitting a KASSERT.
diffstat:
sys/dev/audio/audio.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diffs (28 lines):
diff -r d7a91c38c1f0 -r 9b476930de32 sys/dev/audio/audio.c
--- a/sys/dev/audio/audio.c Fri Aug 23 08:45:25 2019 +0000
+++ b/sys/dev/audio/audio.c Fri Aug 23 09:41:26 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: audio.c,v 1.28 2019/07/10 13:26:47 isaki Exp $ */
+/* $NetBSD: audio.c,v 1.29 2019/08/23 09:41:26 maxv Exp $ */
/*-
* Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -142,7 +142,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.28 2019/07/10 13:26:47 isaki Exp $");
+__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.29 2019/08/23 09:41:26 maxv Exp $");
#ifdef _KERNEL_OPT
#include "audio.h"
@@ -7726,7 +7726,9 @@
} else {
ma = NULL;
}
+ mutex_enter(sc->sc_lock);
mixer_remove(sc); /* remove old entry */
+ mutex_exit(sc->sc_lock);
if (ma != NULL) {
ma->next = sc->sc_async_mixer;
ma->pid = curproc->p_pid;
Home |
Main Index |
Thread Index |
Old Index