xref: /freebsd/usr.bin/top/top.h (revision 58a0f0d00c0cc4a90ce584a61470290751bfcac7)
1 /*
2  * $FreeBSD$
3  */
4 /*
5  *  Top - a top users display for Berkeley Unix
6  *
7  *  General (global) definitions
8  */
9 
10 #ifndef TOP_H
11 #define TOP_H
12 
13 /* Current major version number */
14 #define VERSION		3
15 
16 /* Number of lines of header information on the standard screen */
17 extern int Header_lines;	/* 7 */
18 
19 /* Maximum number of columns allowed for display */
20 #define MAX_COLS	512
21 
22 /* Log base 2 of 1024 is 10 (2^10 == 1024) */
23 #define LOG1024		10
24 
25 /* Special atoi routine returns either a non-negative number or one of: */
26 #define Infinity	-1
27 #define Invalid		-2
28 
29 /* maximum number we can have */
30 #define Largest		0x7fffffff
31 
32 /*
33  * The entire display is based on these next numbers being defined as is.
34  */
35 
36 #define NUM_AVERAGES    3
37 
38 enum displaymodes { DISP_CPU = 0, DISP_IO, DISP_MAX };
39 
40 /*
41  * Format modifiers
42  */
43 #define FMT_SHOWARGS 0x00000001
44 
45 extern enum displaymodes displaymode;
46 
47 extern int pcpu_stats;
48 
49 char* kill_procs(char *);
50 char* renice_procs(char *);
51 
52 #endif /* TOP_H */
53