From bef7db2e66d06b818412c8f43b49d6eebfce10ad Mon Sep 17 00:00:00 2001 From: Bruce Evans Date: Sat, 11 Jul 1998 13:06:41 +0000 Subject: [PATCH] Moved definition of fscale from param.c to kern_synch.c where it should always have been (it has no user-servicable parts even at compile time) and staticized it. --- sys/conf/param.c | 7 +------ sys/kern/kern_synch.c | 6 +++++- sys/kern/subr_param.c | 7 +------ 3 files changed, 7 insertions(+), 13 deletions(-) diff --git a/sys/conf/param.c b/sys/conf/param.c index 84dbae0f6173..454298416c6f 100644 --- a/sys/conf/param.c +++ b/sys/conf/param.c @@ -36,15 +36,13 @@ * SUCH DAMAGE. * * @(#)param.c 8.3 (Berkeley) 8/20/94 - * $Id: param.c,v 1.28 1998/06/21 12:22:35 bde Exp $ + * $Id: param.c,v 1.29 1998/06/30 21:25:35 phk Exp $ */ #include "opt_sysvipc.h" #include "opt_param.h" #include -#include -#include #ifdef SYSVSHM #include @@ -97,9 +95,6 @@ int maxsockets = MAXSOCKETS; /* allocate 1/4th amount of virtual address space for mbufs XXX */ int nmbufs = NMBCLUSTERS * 4; -int fscale = FSCALE; /* kernel uses `FSCALE', user uses `fscale' */ -SYSCTL_INT(_kern, OID_AUTO, fscale, CTLFLAG_RD, 0, FSCALE, ""); - /* * Values in support of System V compatible shared memory. XXX */ diff --git a/sys/kern/kern_synch.c b/sys/kern/kern_synch.c index 99d192b5bf10..6fa55d498f6b 100644 --- a/sys/kern/kern_synch.c +++ b/sys/kern/kern_synch.c @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * @(#)kern_synch.c 8.9 (Berkeley) 5/19/95 - * $Id: kern_synch.c,v 1.58 1998/06/21 18:02:43 bde Exp $ + * $Id: kern_synch.c,v 1.59 1998/06/30 21:25:54 phk Exp $ */ #include "opt_ktrace.h" @@ -216,6 +216,10 @@ roundrobin(arg) static fixpt_t ccpu = 0.95122942450071400909 * FSCALE; /* exp(-1/20) */ SYSCTL_INT(_kern, OID_AUTO, ccpu, CTLFLAG_RD, &ccpu, 0, ""); +/* kernel uses `FSCALE', user uses `fscale' */ +static int fscale = FSCALE; +SYSCTL_INT(_kern, OID_AUTO, fscale, CTLFLAG_RD, 0, FSCALE, ""); + /* * If `ccpu' is not equal to `exp(-1/20)' and you still want to use the * faster/more-accurate formula, you'll have to estimate CCPU_SHIFT below diff --git a/sys/kern/subr_param.c b/sys/kern/subr_param.c index 84dbae0f6173..454298416c6f 100644 --- a/sys/kern/subr_param.c +++ b/sys/kern/subr_param.c @@ -36,15 +36,13 @@ * SUCH DAMAGE. * * @(#)param.c 8.3 (Berkeley) 8/20/94 - * $Id: param.c,v 1.28 1998/06/21 12:22:35 bde Exp $ + * $Id: param.c,v 1.29 1998/06/30 21:25:35 phk Exp $ */ #include "opt_sysvipc.h" #include "opt_param.h" #include -#include -#include #ifdef SYSVSHM #include @@ -97,9 +95,6 @@ int maxsockets = MAXSOCKETS; /* allocate 1/4th amount of virtual address space for mbufs XXX */ int nmbufs = NMBCLUSTERS * 4; -int fscale = FSCALE; /* kernel uses `FSCALE', user uses `fscale' */ -SYSCTL_INT(_kern, OID_AUTO, fscale, CTLFLAG_RD, 0, FSCALE, ""); - /* * Values in support of System V compatible shared memory. XXX */