From 2ec7f0d19f7d1d4e02ec98b605a460f015c9f6b5 Mon Sep 17 00:00:00 2001 From: cg Date: Thu, 14 Jun 2001 13:31:30 +0000 Subject: various locking fixes, rework open logic and channel registration PR: kern/28084 --- sys/dev/sound/pcm/channel.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'sys/dev/sound/pcm/channel.c') diff --git a/sys/dev/sound/pcm/channel.c b/sys/dev/sound/pcm/channel.c index 72f2852..b3cfbe4 100644 --- a/sys/dev/sound/pcm/channel.c +++ b/sys/dev/sound/pcm/channel.c @@ -490,7 +490,7 @@ chn_poll(struct pcm_channel *c, int ev, struct proc *p) struct snd_dbuf *bs = c->bufsoft; int ret; - CHN_LOCK(c); + CHN_LOCKASSERT(c); if (!(c->flags & CHN_F_MAPPED) && !(c->flags & CHN_F_TRIGGERED)) chn_start(c, 1); ret = 0; @@ -498,7 +498,6 @@ chn_poll(struct pcm_channel *c, int ev, struct proc *p) ret = ev; else selrecord(p, sndbuf_getsel(bs)); - CHN_UNLOCK(c); return ret; } -- cgit v1.1