From f9cf9203413285659083c1af9e18c96f9443a577 Mon Sep 17 00:00:00 2001 From: Bruce Evans Date: Tue, 1 Apr 1997 11:48:30 +0000 Subject: [PATCH] Use OID_AUTO instead of magic number for the old sysctl debug.rcluster. The magic number conflicted with the rotting disabled one in ext2fs for debug.doasyncfree. Removed messy debugging variable/constant/sysctl debug.doreallocblks. Lite2 removed it, and we don't use the code that it controls. --- sys/kern/vfs_cluster.c | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/sys/kern/vfs_cluster.c b/sys/kern/vfs_cluster.c index b00da1fc4813..9c8b143429b4 100644 --- a/sys/kern/vfs_cluster.c +++ b/sys/kern/vfs_cluster.c @@ -33,7 +33,7 @@ * SUCH DAMAGE. * * @(#)vfs_cluster.c 8.7 (Berkeley) 2/13/94 - * $Id: vfs_cluster.c,v 1.42 1997/02/22 09:39:31 peter Exp $ + * $Id: vfs_cluster.c,v 1.43 1997/03/07 14:40:54 dyson Exp $ */ #include @@ -56,21 +56,9 @@ #include #include static int rcluster= 0; -SYSCTL_INT(_debug, 14, rcluster, CTLFLAG_RW, &rcluster, 0, ""); +SYSCTL_INT(_debug, OID_AUTO, rcluster, CTLFLAG_RW, &rcluster, 0, ""); #endif -#ifdef notyet_block_reallocation_enabled -#ifdef DEBUG -#include -#include - -static int doreallocblks = 0; -SYSCTL_INT(_debug, 13, doreallocblks, CTLFLAG_RW, &doreallocblks, 0, ""); -#else -#define doreallocblks 0 -#endif -#endif /* notyet_block_reallocation_enabled */ - #ifdef notyet_block_reallocation_enabled static struct cluster_save * cluster_collectbufs __P((struct vnode *vp, struct buf *last_bp)); @@ -538,8 +526,7 @@ cluster_write(bp, filesize) vp->v_cstart, cursize); } #else - if (!doreallocblks || - (lbn + 1) * lblocksize != filesize || + if ((lbn + 1) * lblocksize != filesize || lbn != vp->v_lastw + 1 || vp->v_clen <= cursize) { if (!async) cluster_wbuild(vp, lblocksize,