Date: Sat, 28 Feb 2004 11:42:49 -0800 (PST) From: Don Lewis <truckman@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/dev/sound/pcm dsp.c Message-ID: <200402281942.i1SJgnjc010750@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
truckman 2004/02/28 11:42:49 PST
FreeBSD src repository
Modified files:
sys/dev/sound/pcm dsp.c
Log:
Lock channels only as necessary in dsp_ioctl(), and only lock one
channel at a time unless it is actually necessary to lock both.
This avoids problems with lock order reversal and malloc() calls
with a mutex held when lower level code unlocks a channel, calls malloc(),
and relocks the channel. This also avoids the cost of some unnecessary
locking and unlocking.
Tested by: matk
Revision Changes Path
1.74 +173 -65 src/sys/dev/sound/pcm/dsp.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200402281942.i1SJgnjc010750>
