--- Gnu-Mach/kern/mach_factor.c 2020/09/02 04:36:57 1.1.1.1 +++ Gnu-Mach/kern/mach_factor.c 2020/09/02 04:45:17 1.1.1.3 @@ -1,25 +1,25 @@ -/* +/* * Mach Operating System * Copyright (c) 1991,1990,1989,1988,1987 Carnegie Mellon University * All Rights Reserved. - * + * * Permission to use, copy, modify and distribute this software and its * documentation is hereby granted, provided that both the copyright * notice and this permission notice appear in all copies of the * software, derivative works or modified versions, and any portions * thereof, and that both notices appear in supporting documentation. - * + * * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE. - * + * * Carnegie Mellon requests users of this software to return to - * + * * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU * School of Computer Science * Carnegie Mellon University * Pittsburgh PA 15213-3890 - * + * * any improvements or extensions that they make and grant Carnegie Mellon * the rights to redistribute these changes. */ @@ -31,18 +31,15 @@ * Compute the Mach Factor. */ -#include - #include #include +#include #include #include -#include -#if MACH_KERNEL #include #include -#endif MACH_KERNEL +#include "mach_factor.h" long avenrun[3] = {0, 0, 0}; long mach_factor[3] = {0, 0, 0}; @@ -56,7 +53,7 @@ static long fract[3] = { 983, /* (59.0/60.) 1 minute average */ }; -void compute_mach_factor() +void compute_mach_factor(void) { register processor_set_t pset; register processor_t processor; @@ -92,7 +89,7 @@ void compute_mach_factor() /* * account for threads on cpus. */ - nthreads += ncpus - pset->idle_count; + nthreads += ncpus - pset->idle_count; /* * The current thread (running this calculation)