diff options
author | Alan Cox <alc@FreeBSD.org> | 2004-08-10 21:47:11 +0000 |
---|---|---|
committer | Alan Cox <alc@FreeBSD.org> | 2004-08-10 21:47:11 +0000 |
commit | fad44deea3b6e4a0ceb8a25ba411a220337d3f15 (patch) | |
tree | 8f072dacabdc3824e071bec6e90f8d9c44758ad4 /sys/kern/kern_physio.c | |
parent | 6306df6b897d7b83b46d7822d633dae9c0bc9dcc (diff) | |
download | src-fad44deea3b6e4a0ceb8a25ba411a220337d3f15.tar.gz src-fad44deea3b6e4a0ceb8a25ba411a220337d3f15.zip |
Eliminate the acquisition and release of Giant within physio(). Remove
the spl calls.
Reviewed by: phk@
Discussed with: scottl@
Notes
Notes:
svn path=/head/; revision=133454
Diffstat (limited to 'sys/kern/kern_physio.c')
-rw-r--r-- | sys/kern/kern_physio.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/sys/kern/kern_physio.c b/sys/kern/kern_physio.c index c2c9b3f198b9..803995c0380b 100644 --- a/sys/kern/kern_physio.c +++ b/sys/kern/kern_physio.c @@ -36,13 +36,10 @@ physio(struct cdev *dev, struct uio *uio, int ioflag) { int i; int error; - int spl; caddr_t sa; u_int iolen; struct buf *bp; - /* We cannot trust the device driver to hold Giant for us */ - mtx_lock(&Giant); /* Keep the process UPAGES from being swapped. XXX: why ? */ PHOLD(curproc); @@ -99,12 +96,10 @@ physio(struct cdev *dev, struct uio *uio, int ioflag) } DEV_STRATEGY(bp); - spl = splbio(); if (uio->uio_rw == UIO_READ) bwait(bp, PRIBIO, "physrd"); else bwait(bp, PRIBIO, "physwr"); - splx(spl); if (uio->uio_segflg == UIO_USERSPACE) vunmapbuf(bp); @@ -125,6 +120,5 @@ physio(struct cdev *dev, struct uio *uio, int ioflag) doerror: relpbuf(bp, NULL); PRELE(curproc); - mtx_unlock(&Giant); return (error); } |