Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/chs-ubc2]: src/sys remove uvm_vnp_uncache(), it's no longer needed.
details: https://anonhg.NetBSD.org/src/rev/354fe13ea705
branches: chs-ubc2
changeset: 471389:354fe13ea705
user: chs <chs%NetBSD.org@localhost>
date: Sun Jul 11 05:43:56 1999 +0000
description:
remove uvm_vnp_uncache(), it's no longer needed.
diffstat:
sys/kern/vfs_syscalls.c | 5 +----
sys/kern/vfs_vnops.c | 7 +++----
sys/nfs/nfs_bio.c | 7 +------
sys/nfs/nfs_serv.c | 10 ++++------
sys/nfs/nfs_vnops.c | 5 +----
sys/ufs/ext2fs/ext2fs_inode.c | 4 +---
sys/ufs/ext2fs/ext2fs_readwrite.c | 3 +--
sys/ufs/ext2fs/ext2fs_vnops.c | 4 +---
sys/ufs/ffs/ffs_alloc.c | 3 +--
sys/ufs/ffs/ffs_inode.c | 5 +----
sys/ufs/lfs/lfs_alloc.c | 3 +--
sys/ufs/lfs/lfs_inode.c | 3 +--
sys/ufs/ufs/ufs_readwrite.c | 3 +--
sys/ufs/ufs/ufs_vnops.c | 4 +---
sys/uvm/uvm_extern.h | 4 +---
sys/uvm/uvm_mmap.c | 37 +++----------------------------------
16 files changed, 23 insertions(+), 84 deletions(-)
diffs (truncated from 391 to 300 lines):
diff -r 8d49fca6d13c -r 354fe13ea705 sys/kern/vfs_syscalls.c
--- a/sys/kern/vfs_syscalls.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/kern/vfs_syscalls.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_syscalls.c,v 1.133.4.3 1999/07/02 18:54:10 thorpej Exp $ */
+/* $NetBSD: vfs_syscalls.c,v 1.133.4.4 1999/07/11 05:43:56 chs Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -1533,8 +1533,6 @@
goto out;
}
- (void)uvm_vnp_uncache(vp);
-
VOP_LEASE(nd.ni_dvp, p, p->p_ucred, LEASE_WRITE);
VOP_LEASE(vp, p, p->p_ucred, LEASE_WRITE);
error = VOP_REMOVE(nd.ni_dvp, nd.ni_vp, &nd.ni_cnd);
@@ -2749,7 +2747,6 @@
if (fromnd.ni_dvp != tdvp)
VOP_LEASE(fromnd.ni_dvp, p, p->p_ucred, LEASE_WRITE);
if (tvp) {
- (void)uvm_vnp_uncache(tvp);
VOP_LEASE(tvp, p, p->p_ucred, LEASE_WRITE);
}
error = VOP_RENAME(fromnd.ni_dvp, fromnd.ni_vp, &fromnd.ni_cnd,
diff -r 8d49fca6d13c -r 354fe13ea705 sys/kern/vfs_vnops.c
--- a/sys/kern/vfs_vnops.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/kern/vfs_vnops.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_vnops.c,v 1.36.4.1 1999/06/07 04:25:31 chs Exp $ */
+/* $NetBSD: vfs_vnops.c,v 1.36.4.2 1999/07/11 05:43:56 chs Exp $ */
/*
* Copyright (c) 1982, 1986, 1989, 1993
@@ -178,10 +178,9 @@
/*
* If there's shared text associated with
- * the vnode, try to free it up once. If
- * we fail, we can't allow writing.
+ * the vnode, we can't allow writing.
*/
- if ((vp->v_flag & VTEXT) && !uvm_vnp_uncache(vp))
+ if (vp->v_flag & VTEXT)
return (ETXTBSY);
return (0);
}
diff -r 8d49fca6d13c -r 354fe13ea705 sys/nfs/nfs_bio.c
--- a/sys/nfs/nfs_bio.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/nfs/nfs_bio.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nfs_bio.c,v 1.45.4.2 1999/07/04 01:45:35 chs Exp $ */
+/* $NetBSD: nfs_bio.c,v 1.45.4.3 1999/07/11 05:43:57 chs Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -664,11 +664,6 @@
#endif
/*
- * XXX make sure we aren't cached in the VM page cache
- */
- (void)uvm_vnp_uncache(vp);
-
- /*
* Check for a valid write lease.
*/
if ((nmp->nm_flag & NFSMNT_NQNFS) &&
diff -r 8d49fca6d13c -r 354fe13ea705 sys/nfs/nfs_serv.c
--- a/sys/nfs/nfs_serv.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/nfs/nfs_serv.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nfs_serv.c,v 1.50.2.1.2.1 1999/06/21 01:28:55 thorpej Exp $ */
+/* $NetBSD: nfs_serv.c,v 1.50.2.1.2.2 1999/07/11 05:43:57 chs Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -1735,7 +1735,6 @@
}
out:
if (!error) {
- (void)uvm_vnp_uncache(vp);
nqsrv_getl(nd.ni_dvp, ND_WRITE);
nqsrv_getl(vp, ND_WRITE);
error = VOP_REMOVE(nd.ni_dvp, nd.ni_vp, &nd.ni_cnd);
@@ -1910,7 +1909,6 @@
nqsrv_getl(fromnd.ni_dvp, ND_WRITE);
nqsrv_getl(tdvp, ND_WRITE);
if (tvp) {
- (void)uvm_vnp_uncache(tvp);
nqsrv_getl(tvp, ND_WRITE);
}
error = VOP_RENAME(fromnd.ni_dvp, fromnd.ni_vp, &fromnd.ni_cnd,
@@ -3399,12 +3397,12 @@
break;
}
}
+
/*
* If there's shared text associated with
- * the inode, try to free it up once. If
- * we fail, we can't allow writing.
+ * the inode, we can't allow writing.
*/
- if ((vp->v_flag & VTEXT) && !uvm_vnp_uncache(vp))
+ if (vp->v_flag & VTEXT)
return (ETXTBSY);
}
error = VOP_GETATTR(vp, &vattr, cred, p);
diff -r 8d49fca6d13c -r 354fe13ea705 sys/nfs/nfs_vnops.c
--- a/sys/nfs/nfs_vnops.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/nfs/nfs_vnops.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nfs_vnops.c,v 1.100.4.3 1999/07/04 01:46:53 chs Exp $ */
+/* $NetBSD: nfs_vnops.c,v 1.100.4.4 1999/07/11 05:43:58 chs Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -418,7 +418,6 @@
if ((error = nfs_vinvalbuf(vp, V_SAVE, ap->a_cred,
ap->a_p, 1)) == EINTR)
return (error);
- (void) uvm_vnp_uncache(vp);
np->n_brev = np->n_lrev;
}
}
@@ -427,7 +426,6 @@
if ((error = nfs_vinvalbuf(vp, V_SAVE, ap->a_cred,
ap->a_p, 1)) == EINTR)
return (error);
- (void) uvm_vnp_uncache(vp);
np->n_attrstamp = 0;
if (vp->v_type == VDIR) {
nfs_invaldircache(vp, 0);
@@ -449,7 +447,6 @@
if ((error = nfs_vinvalbuf(vp, V_SAVE,
ap->a_cred, ap->a_p, 1)) == EINTR)
return (error);
- (void) uvm_vnp_uncache(vp);
np->n_mtime = vattr.va_mtime.tv_sec;
}
}
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ext2fs/ext2fs_inode.c
--- a/sys/ufs/ext2fs/ext2fs_inode.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ext2fs/ext2fs_inode.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ext2fs_inode.c,v 1.13 1999/03/24 05:51:30 mrg Exp $ */
+/* $NetBSD: ext2fs_inode.c,v 1.13.4.1 1999/07/11 05:43:59 chs Exp $ */
/*
* Copyright (c) 1997 Manuel Bouyer.
@@ -242,7 +242,6 @@
return (error);
oip->i_e2fs_size = length;
uvm_vnp_setsize(ovp, length);
- (void) uvm_vnp_uncache(ovp);
if (aflags & B_SYNC)
bwrite(bp);
else
@@ -270,7 +269,6 @@
return (error);
oip->i_e2fs_size = length;
size = fs->e2fs_bsize;
- (void) uvm_vnp_uncache(ovp);
memset((char *)bp->b_data + offset, 0, (u_int)(size - offset));
allocbuf(bp, size);
if (aflags & B_SYNC)
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ext2fs/ext2fs_readwrite.c
--- a/sys/ufs/ext2fs/ext2fs_readwrite.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ext2fs/ext2fs_readwrite.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ext2fs_readwrite.c,v 1.10 1999/03/24 05:51:30 mrg Exp $ */
+/* $NetBSD: ext2fs_readwrite.c,v 1.10.4.1 1999/07/11 05:43:59 chs Exp $ */
/*-
* Copyright (c) 1997 Manuel Bouyer.
@@ -259,7 +259,6 @@
ip->i_e2fs_size = uio->uio_offset + xfersize;
uvm_vnp_setsize(vp, ip->i_e2fs_size);
}
- (void)uvm_vnp_uncache(vp);
size = fs->e2fs_bsize - bp->b_resid;
if (size < xfersize)
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ext2fs/ext2fs_vnops.c
--- a/sys/ufs/ext2fs/ext2fs_vnops.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ext2fs/ext2fs_vnops.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ext2fs_vnops.c,v 1.19 1999/03/24 05:51:30 mrg Exp $ */
+/* $NetBSD: ext2fs_vnops.c,v 1.19.4.1 1999/07/11 05:43:59 chs Exp $ */
/*
* Copyright (c) 1997 Manuel Bouyer.
@@ -423,8 +423,6 @@
ip->i_e2fs_mode &= ~ALLPERMS;
ip->i_e2fs_mode |= (mode & ALLPERMS);
ip->i_flag |= IN_CHANGE;
- if ((vp->v_flag & VTEXT) && (ip->i_e2fs_mode & S_ISTXT) == 0)
- (void) uvm_vnp_uncache(vp);
return (0);
}
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ffs/ffs_alloc.c
--- a/sys/ufs/ffs/ffs_alloc.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ffs/ffs_alloc.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ffs_alloc.c,v 1.29.4.1 1999/06/07 04:25:34 chs Exp $ */
+/* $NetBSD: ffs_alloc.c,v 1.29.4.2 1999/07/11 05:43:59 chs Exp $ */
/*
* Copyright (c) 1982, 1986, 1989, 1993
@@ -292,7 +292,6 @@
bno = (ufs_daddr_t)ffs_hashalloc(ip, cg, (long)bpref, request,
ffs_alloccg);
if (bno > 0) {
- (void) uvm_vnp_uncache(ITOV(ip));
ffs_blkfree(ip, bprev, (long)osize);
if (nsize < request)
ffs_blkfree(ip, bno + numfrags(fs, nsize),
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ffs/ffs_inode.c
--- a/sys/ufs/ffs/ffs_inode.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ffs/ffs_inode.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ffs_inode.c,v 1.28.4.1 1999/06/07 04:25:34 chs Exp $ */
+/* $NetBSD: ffs_inode.c,v 1.28.4.2 1999/07/11 05:43:59 chs Exp $ */
/*
* Copyright (c) 1982, 1986, 1989, 1993
@@ -209,8 +209,6 @@
bp = 0;
oip->i_ffs_size = length;
uvm_vnp_setsize(ovp, length);
- (void) uvm_vnp_uncache(ovp);
-
oip->i_flag |= IN_CHANGE | IN_UPDATE;
return (VOP_UPDATE(ovp, NULL, NULL, 1));
}
@@ -239,7 +237,6 @@
#endif
oip->i_ffs_size = length;
size = blksize(fs, oip, lbn);
- (void) uvm_vnp_uncache(ovp);
#if 1
uvm_vnp_zerorange(ovp, oip->i_ffs_size, size - offset);
#else
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/lfs/lfs_alloc.c
--- a/sys/ufs/lfs/lfs_alloc.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/lfs/lfs_alloc.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lfs_alloc.c,v 1.18.2.2.2.1 1999/06/21 01:31:07 thorpej Exp $ */
+/* $NetBSD: lfs_alloc.c,v 1.18.2.2.2.2 1999/07/11 05:43:59 chs Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -161,7 +161,6 @@
lfs_balloc(vp, 0, fs->lfs_bsize, blkno, &bp);
ip->i_ffs_size += fs->lfs_bsize;
uvm_vnp_setsize(vp, ip->i_ffs_size);
- (void)uvm_vnp_uncache(vp);
i = (blkno - fs->lfs_segtabsz - fs->lfs_cleansz) *
fs->lfs_ifpb;
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/lfs/lfs_inode.c
--- a/sys/ufs/lfs/lfs_inode.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/lfs/lfs_inode.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lfs_inode.c,v 1.22.2.1.2.1 1999/06/21 01:31:10 thorpej Exp $ */
+/* $NetBSD: lfs_inode.c,v 1.22.2.1.2.2 1999/07/11 05:44:00 chs Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -308,7 +308,6 @@
return (e1);
}
ip->i_ffs_size = length;
- (void)uvm_vnp_uncache(vp);
newsize = blksize(fs, ip, lbn);
bzero((char *)bp->b_data + offset, (u_int)(newsize - offset));
#ifdef DEBUG
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ufs/ufs_readwrite.c
--- a/sys/ufs/ufs/ufs_readwrite.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ufs/ufs_readwrite.c Sun Jul 11 05:43:56 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_readwrite.c,v 1.22.4.4 1999/07/04 01:55:41 chs Exp $ */
+/* $NetBSD: ufs_readwrite.c,v 1.22.4.5 1999/07/11 05:44:00 chs Exp $ */
/*-
* Copyright (c) 1993
@@ -320,7 +320,6 @@
ip->i_ffs_size = uio->uio_offset + xfersize;
uvm_vnp_setsize(vp, ip->i_ffs_size);
}
- (void)uvm_vnp_uncache(vp);
size = BLKSIZE(fs, ip, lbn) - bp->b_resid;
if (size < xfersize)
diff -r 8d49fca6d13c -r 354fe13ea705 sys/ufs/ufs/ufs_vnops.c
--- a/sys/ufs/ufs/ufs_vnops.c Tue Jul 06 14:52:08 1999 +0000
+++ b/sys/ufs/ufs/ufs_vnops.c Sun Jul 11 05:43:56 1999 +0000
Home |
Main Index |
Thread Index |
Old Index