]> git.neil.brown.name Git - history.git/commit
[PATCH] Fix reporting of process start times
authorTim Schmielau <tim@physik3.uni-rostock.de>
Wed, 13 Oct 2004 14:27:49 +0000 (07:27 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Wed, 13 Oct 2004 14:27:49 +0000 (07:27 -0700)
commitb9877c907d56b803b5b0241c2465ce768809fce9
tree86de6ef294704e1a5a31591b157c41402fe7c897
parent1a9c15ac3687ec00574be4ad0f3ee1b299062ca4
[PATCH] Fix reporting of process start times

Derive process start times from the posix_clock_monotonic notion of uptime
instead of "jiffies", consistent with the earlier change to /proc/uptime
itself.
(http://linus.bkbits.net:8080/linux-2.5/cset@3ef4851dGg0fxX58R9Zv8SIq9fzNmQ?na%0Av=index.html|src/.|src/fs|src/fs/proc|related/fs/proc/proc_misc.c)

Process start times are reported to userspace in units of 1/USER_HZ since
boot, thus applications as procps need the value of "uptime" to convert
them into absolute time.

Currently "uptime" is derived from an ntp-corrected time base, but process
start time is derived from the free-running "jiffies" counter.  This
results in inaccurate, drifting process start times as seen by the user,
even if the exported number stays constant, because the users notion of
"jiffies" changes in time.

It's John Stultz's patch anyways, which I only messed up a bit, but since
people started trading signed-off lines on lkml:

Signed-off-by: Tim Schmielau <tim@physik3.uni-rostock.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/proc/array.c
include/linux/acct.h
include/linux/sched.h
include/linux/times.h
kernel/acct.c
kernel/fork.c
mm/oom_kill.c