top: eliminated old kernel-2.4 & 2.5 support (man too)

The newlib informal cutoff for kernel support seems to
be around release 2.6. This commit eliminates any such
support for really old 2.4 and 2.5 kernels within top.

Signed-off-by: Jim Warner <james.warner@comcast.net>
This commit is contained in:
Jim Warner 2015-08-19 00:00:00 -05:00 committed by Craig Small
parent 77dc22b910
commit f937ff8238
5 changed files with 10 additions and 27 deletions

View File

@ -435,14 +435,13 @@ Line 2 shows \*(PU state percentages based on the interval since the
last refresh.
As a default, percentages for these individual categories are displayed.
Where two labels are shown below, those for more recent kernel versions
are shown first.
Depending on your kernel version, the \fBst\fR field may not be shown.
.nf
\fBus\fR,\fB user\fR : time running un-niced user processes
\fBsy\fR,\fB system\fR : time running kernel processes
\fBni\fR,\fB nice\fR : time running niced user processes
\fBid\fR,\fB idle\fR : time spent in the kernel idle handler
\fBwa\fR,\fB IO-wait\fR : time waiting for I/O completion
\fBus\fR : time running un-niced user processes
\fBsy\fR : time running kernel processes
\fBni\fR : time running niced user processes
\fBid\fR : time spent in the kernel idle handler
\fBwa\fR : time waiting for I/O completion
\fBhi\fR : time spent servicing hardware interrupts
\fBsi\fR : time spent servicing software interrupts
\fBst\fR : time stolen from this vm by the hypervisor

View File

@ -2197,8 +2197,8 @@ static void cpus_refresh (void) {
#define sumSLOT ( Cpu_cnt )
#define totSLOT ( 1 + Cpu_cnt + Numa_node_tot )
static int sav_slot = -1;
int i;
#ifndef NUMA_DISABLE
int i;
int node;
#endif
@ -2919,10 +2919,6 @@ static void before (char *me) {
Cpu_cnt = 8;
#endif
Cpu_faux_cnt = Cpu_cnt;
Cpu_States_fmts = N_unq(STATE_lin2x4_fmt);
if (linux_version_code > LINUX_VERSION(2, 5, 41))
Cpu_States_fmts = N_unq(STATE_lin2x5_fmt);
if (linux_version_code >= LINUX_VERSION(2, 6, 0))
Cpu_States_fmts = N_unq(STATE_lin2x6_fmt);
if (linux_version_code >= LINUX_VERSION(2, 6, 11))
Cpu_States_fmts = N_unq(STATE_lin2x7_fmt);

View File

@ -46,7 +46,6 @@
//#define OFF_SCROLLBK /* disable tty emulators scrollback buffer */
//#define OFF_STDERROR /* disable our stderr buffering (redirect) */
//#define OFF_STDIOLBF /* disable our own stdout _IOFBF override */
//#define PRETEND2_5_X /* pretend we're linux 2.5.x (for IO-wait) */
//#define PRETEND8CPUS /* pretend we're smp with 8 ticsers (sic) */
//#define PRETENDNOCAP /* use a terminal without essential caps */
//#define PRETEND_NUMA /* pretend 4 (or 3 w/o OFF_NUMASKIP) Nodes */
@ -83,10 +82,6 @@
/* For the impetus and NUMA/Node prototype design, thanks to:
Lance Shelton <LShelton@fusionio.com> - April, 2013 */
#ifdef PRETEND2_5_X
#define linux_version_code LINUX_VERSION(2,5,43)
#endif
// pretend as if #define _GNU_SOURCE
char *strcasestr(const char *haystack, const char *needle);

View File

@ -622,12 +622,6 @@ static void build_uniq_nlstab (void) {
Uniq_nlstab[STATE_line_1_fmt] = _("%s:~3"
" %3u ~2total,~3 %3u ~2running,~3 %3u ~2sleeping,~3 %3u ~2stopped,~3 %3u ~2zombie~3\n");
Uniq_nlstab[STATE_lin2x4_fmt] = _("%%%s~3"
" %#5.1f ~2user,~3 %#5.1f ~2system,~3 %#5.1f ~2nice,~3 %#5.1f ~2idle~3\n");
Uniq_nlstab[STATE_lin2x5_fmt] = _("%%%s~3"
" %#5.1f ~2user,~3 %#5.1f ~2system,~3 %#5.1f ~2nice,~3 %#5.1f ~2idle,~3 %#5.1f ~2IO-wait~3\n");
/* Translation Hint: Only the following abbreviations need be translated
. us = user, sy = system, ni = nice, id = idle, wa = wait,
. hi hardware interrupt, si = software interrupt */

View File

@ -96,9 +96,8 @@ enum norm_nls {
enum uniq_nls {
KEYS_helpbas_fmt, KEYS_helpext_fmt, WINDOWS_help_fmt, COLOR_custom_fmt,
FIELD_header_fmt, MEMORY_lines_fmt, STATE_line_1_fmt, STATE_lin2x4_fmt,
STATE_lin2x5_fmt, STATE_lin2x6_fmt, STATE_lin2x7_fmt, YINSP_hdsels_fmt,
YINSP_hdview_fmt,
FIELD_header_fmt, MEMORY_lines_fmt, STATE_line_1_fmt, STATE_lin2x6_fmt,
STATE_lin2x7_fmt, YINSP_hdsels_fmt, YINSP_hdview_fmt,
uniq_MAX
};