lkml.org 
[lkml]   [2001]   [Oct]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Patch] Re: Nasty suprise with uptime
Sorry, I forgot to set INITIAL_JIFFIES to zero before posting the patch.

Testing with high INITIAL_JIFFIES values unfortunately still discloses
instability after the wraparound even for an otherwise unpatched kernel.

I also forgot to mention that the introduced jiffies_high variable is
useless on 64 bit systems, so we might #ifdef it out there.

Tim


On Wed, 31 Oct 2001, Tim Schmielau wrote:

[parts of patch snipped]

> --- kernel/timer.c.orig Wed Oct 31 17:24:36 2001
> +++ kernel/timer.c Wed Oct 31 18:38:47 2001
> @@ -65,7 +65,9 @@
>
> extern int do_setitimer(int, struct itimerval *, struct itimerval *);
>
> -unsigned long volatile jiffies;
> +#define INITIAL_JIFFIES 0xFFFFD000ul
> +unsigned long volatile jiffies = INITIAL_JIFFIES;
> +unsigned long volatile jiffies_high, jiffies_high_shadow;
>

This of course needs to be
#define INITIAL_JIFFIES 0
for correct uptime display

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:12    [W:0.101 / U:0.344 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site