diff options
author | rik <rik@FreeBSD.org> | 2004-12-26 20:47:41 +0000 |
---|---|---|
committer | rik <rik@FreeBSD.org> | 2004-12-26 20:47:41 +0000 |
commit | 9df64a1b0d507fcf1b4559c171c586be25f29a43 (patch) | |
tree | a00df81e468c25e08a4b95b90fae9c5c32c93dcd /sys | |
parent | f98498c1943919d8e31500adfd32b54962fe0fc4 (diff) | |
download | FreeBSD-src-9df64a1b0d507fcf1b4559c171c586be25f29a43.zip FreeBSD-src-9df64a1b0d507fcf1b4559c171c586be25f29a43.tar.gz |
tsleep => msleep
read sys/kern/kern_synch.c, msleep ():
KASSERT(timo != 0 || mtx_owned(&Giant) || mtx != NULL,
("sleeping without a mutex"));
MFC after: 3 days
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netgraph/ng_device.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netgraph/ng_device.c b/sys/netgraph/ng_device.c index 63bc755..2853b99 100644 --- a/sys/netgraph/ng_device.c +++ b/sys/netgraph/ng_device.c @@ -433,8 +433,8 @@ ngdread(struct cdev *dev, struct uio *uio, int flag) return (EWOULDBLOCK); mtx_lock(&priv->ngd_mtx); priv->flags |= NGDF_RWAIT; - mtx_unlock(&priv->ngd_mtx); - if ((error = tsleep(priv, PCATCH | (PZERO + 1), + if ((error = msleep(priv, &priv->ngd_mtx, + PDROP | PCATCH | (PZERO + 1), "ngdread", 0)) != 0) return (error); } |