Changeset View
Changeset View
Standalone View
Standalone View
head/contrib/top/loadavg.h
Show All 13 Lines | |||||
/* | /* | ||||
* We assume that if FSCALE is defined, then avenrun and ccpu are type long. | * We assume that if FSCALE is defined, then avenrun and ccpu are type long. | ||||
* If your machine is an exception (mips, perhaps?) then make adjustments | * If your machine is an exception (mips, perhaps?) then make adjustments | ||||
* here. | * here. | ||||
* | * | ||||
* Defined types: load_avg for load averages, pctcpu for cpu percentages. | * Defined types: load_avg for load averages, pctcpu for cpu percentages. | ||||
*/ | */ | ||||
#if defined(mips) && !defined(NetBSD) | #if defined(mips) && !(defined(NetBSD) || defined(FreeBSD)) | ||||
# include <sys/fixpoint.h> | # include <sys/fixpoint.h> | ||||
# if defined(FBITS) && !defined(FSCALE) | # if defined(FBITS) && !defined(FSCALE) | ||||
# define FSCALE (1 << FBITS) /* mips */ | # define FSCALE (1 << FBITS) /* RISC/os on mips */ | ||||
# endif | # endif | ||||
#endif | #endif | ||||
#ifdef FSCALE | #ifdef FSCALE | ||||
# define FIXED_LOADAVG FSCALE | # define FIXED_LOADAVG FSCALE | ||||
# define FIXED_PCTCPU FSCALE | # define FIXED_PCTCPU FSCALE | ||||
#endif | #endif | ||||
Show All 24 Lines |