]> CyberLeo.Net >> Repos - FreeBSD/stable/8.git/commit
MFC: r232050
authorrmacklem <rmacklem@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 9 Apr 2012 03:39:50 +0000 (03:39 +0000)
committerrmacklem <rmacklem@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 9 Apr 2012 03:39:50 +0000 (03:39 +0000)
commit0867453ac63bdfa920aef65e244dc31361d52039
tree32449ac06a92db6397a5cb27605a9c387efd36a4
parent240c9a3b47a8e5de6544046184b81a63e1a491cd
MFC: r232050
hrs@ reported a panic to freebsd-stable@ under the subject line
"panic in 8.3-PRERELEASE" on Feb. 22, 2012. This panic was caused
by use of a mix of tsleep() and msleep() calls on the same event
in the new NFS server DRC code. It did "mtx_unlock(); tsleep();"
in two places, which kib@ noted introduced a slight risk that the
wakeup() would occur before the tsleep(), resulting in a 10sec
delay before waking up. This patch fixes the problem by replacing
"mtx_unlock(); tsleep();" with mtx_sleep(..PDROP..). It also
changes a nfsmsleep() call to mtx_sleep() so that the code uses
mtx_sleep() consistently within the file.

git-svn-id: svn://svn.freebsd.org/base/stable/8@234050 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/fs/nfsserver/nfs_nfsdcache.c