summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/fs/nfsclient/nfs_clbio.c2
-rw-r--r--sys/kern/vfs_bio.c41
-rw-r--r--sys/nfsclient/nfs_bio.c2
-rw-r--r--sys/sys/buf.h1
4 files changed, 2 insertions, 44 deletions
diff --git a/sys/fs/nfsclient/nfs_clbio.c b/sys/fs/nfsclient/nfs_clbio.c
index 7b58297..78ae96c 100644
--- a/sys/fs/nfsclient/nfs_clbio.c
+++ b/sys/fs/nfsclient/nfs_clbio.c
@@ -1302,7 +1302,7 @@ again:
bp->b_dirtyoff = on;
bp->b_dirtyend = on + n;
}
- vfs_bio_set_validclean(bp, on, n);
+ vfs_bio_set_valid(bp, on, n);
}
/*
diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c
index e6e7fe2..d17ce57 100644
--- a/sys/kern/vfs_bio.c
+++ b/sys/kern/vfs_bio.c
@@ -3673,47 +3673,6 @@ vfs_bio_set_valid(struct buf *bp, int base, int size)
}
/*
- * vfs_bio_set_validclean:
- *
- * Set the range within the buffer to valid and clean. The range is
- * relative to the beginning of the buffer, b_offset. Note that b_offset
- * itself may be offset from the beginning of the first page.
- *
- */
-
-void
-vfs_bio_set_validclean(struct buf *bp, int base, int size)
-{
- int i, n;
- vm_page_t m;
-
- if (!(bp->b_flags & B_VMIO))
- return;
- /*
- * Fixup base to be relative to beginning of first page.
- * Set initial n to be the maximum number of bytes in the
- * first page that can be validated.
- */
-
- base += (bp->b_offset & PAGE_MASK);
- n = PAGE_SIZE - (base & PAGE_MASK);
-
- VM_OBJECT_LOCK(bp->b_bufobj->bo_object);
- vm_page_lock_queues();
- for (i = base / PAGE_SIZE; size > 0 && i < bp->b_npages; ++i) {
- m = bp->b_pages[i];
- if (n > size)
- n = size;
- vm_page_set_validclean(m, base & PAGE_MASK, n);
- base += n;
- size -= n;
- n = PAGE_SIZE;
- }
- vm_page_unlock_queues();
- VM_OBJECT_UNLOCK(bp->b_bufobj->bo_object);
-}
-
-/*
* vfs_bio_clrbuf:
*
* If the specified buffer is a non-VMIO buffer, clear the entire
diff --git a/sys/nfsclient/nfs_bio.c b/sys/nfsclient/nfs_bio.c
index 3c12ea0..ae8a05d 100644
--- a/sys/nfsclient/nfs_bio.c
+++ b/sys/nfsclient/nfs_bio.c
@@ -1200,7 +1200,7 @@ again:
bp->b_dirtyoff = on;
bp->b_dirtyend = on + n;
}
- vfs_bio_set_validclean(bp, on, n);
+ vfs_bio_set_valid(bp, on, n);
}
/*
diff --git a/sys/sys/buf.h b/sys/sys/buf.h
index fb0d804..8f3b1b2 100644
--- a/sys/sys/buf.h
+++ b/sys/sys/buf.h
@@ -499,7 +499,6 @@ int cluster_read(struct vnode *, u_quad_t, daddr_t, long,
int cluster_wbuild(struct vnode *, long, daddr_t, int);
void cluster_write(struct vnode *, struct buf *, u_quad_t, int);
void vfs_bio_set_valid(struct buf *, int base, int size);
-void vfs_bio_set_validclean(struct buf *, int base, int size);
void vfs_bio_clrbuf(struct buf *);
void vfs_busy_pages(struct buf *, int clear_modify);
void vfs_unbusy_pages(struct buf *);
OpenPOWER on IntegriCloud