summaryrefslogtreecommitdiffstats
path: root/sys/nfsclient/nfs_bio.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2003-10-18 09:33:13 +0000
committerphk <phk@FreeBSD.org>2003-10-18 09:33:13 +0000
commita347a9d216d305c2dbe886c491e5f89468cd865b (patch)
treee42e84bb9411ca18b0105aea14e3632f29ac4cc4 /sys/nfsclient/nfs_bio.c
parent6b528c791125260313d635e198e09e508261a4b2 (diff)
downloadFreeBSD-src-a347a9d216d305c2dbe886c491e5f89468cd865b.zip
FreeBSD-src-a347a9d216d305c2dbe886c491e5f89468cd865b.tar.gz
We do not get B_PHYS buffers here anymore. /dev/drum is long gone.
Diffstat (limited to 'sys/nfsclient/nfs_bio.c')
-rw-r--r--sys/nfsclient/nfs_bio.c26
1 files changed, 2 insertions, 24 deletions
diff --git a/sys/nfsclient/nfs_bio.c b/sys/nfsclient/nfs_bio.c
index a0d507e..a8044b4 100644
--- a/sys/nfsclient/nfs_bio.c
+++ b/sys/nfsclient/nfs_bio.c
@@ -1295,31 +1295,9 @@ nfs_doio(struct buf *bp, struct ucred *cr, struct thread *td)
/*
* Historically, paging was done with physio, but no more.
*/
- if (bp->b_flags & B_PHYS) {
- /*
- * ...though reading /dev/drum still gets us here.
- */
- io.iov_len = uiop->uio_resid = bp->b_bcount;
- /* mapping was done by vmapbuf() */
- io.iov_base = bp->b_data;
- uiop->uio_offset = ((off_t)bp->b_blkno) * DEV_BSIZE;
- if (bp->b_iocmd == BIO_READ) {
- uiop->uio_rw = UIO_READ;
- nfsstats.read_physios++;
- error = nfs_readrpc(vp, uiop, cr);
- } else {
- int com;
+ KASSERT(!(bp->b_flags & B_PHYS), ("B_PHYS in nfs_doio"));
- iomode = NFSV3WRITE_DATASYNC;
- uiop->uio_rw = UIO_WRITE;
- nfsstats.write_physios++;
- error = nfs_writerpc(vp, uiop, cr, &iomode, &com);
- }
- if (error) {
- bp->b_ioflags |= BIO_ERROR;
- bp->b_error = error;
- }
- } else if (bp->b_iocmd == BIO_READ) {
+ if (bp->b_iocmd == BIO_READ) {
io.iov_len = uiop->uio_resid = bp->b_bcount;
io.iov_base = bp->b_data;
uiop->uio_rw = UIO_READ;
OpenPOWER on IntegriCloud