View Incident:
http://co-op.engr.sgi.com/BugWorks/code/bwxquery.cgi?search=Search&wlong=1&view_type=Bug&wi=792097
Submitter : hawkes Submitter Domain : engr
Assigned Engineer : hawkes Assigned Domain : engr
Assigned Group : linux-origin Category : software
Customer Reported : F Priority : 2
Project : linux-origin Status : open
Description :
Various commands that report cputime -- 'top', 'vmstat', 'ps' (e.g., ps -S) --
report zero elapsed time.
/proc/<pid>/cpu is correct.
/proc/<pid>/stat shows bogus values for user/system times.
The problem seems to be a mistyping of __kernel_clock_t in
include/asm-mips64/posix_types.h. The mips64 type is "int", though in all the
other architectures it is "long". Changing it to "long" seems to fix the
problem (because proc_pid_stat() in fs/proc/array.c pushes these clock_t values
through an sprintf() using a format of "%lu").
|