Re: [PATCH] New x86_64 time code for 2.5.70

john stultz (johnstul@us.ibm.com)
12 Jun 2003 18:43:25 -0700


On Thu, 2003-06-12 at 14:16, Bryan O'Sullivan wrote:
> On Thu, 2003-06-12 at 12:39, john stultz wrote:
>
> > One little tweak, you're still subtracting tick_usec when calculating
> > offset.
>
> Well spotted, thanks.

Caught another (last instance of tick_usec in time.c). This time in
settimeofday(). This fixes the ltp failure.

thanks
-john

diff -Nru a/arch/x86_64/kernel/time.c b/arch/x86_64/kernel/time.c
--- a/arch/x86_64/kernel/time.c Thu Jun 12 18:42:19 2003
+++ b/arch/x86_64/kernel/time.c Thu Jun 12 18:42:19 2003
@@ -129,7 +129,7 @@
write_seqlock_irq(&xtime_lock);

tv->tv_usec -= do_gettimeoffset() +
- (jiffies - wall_jiffies) * tick_usec;
+ (jiffies - wall_jiffies) * (USEC_PER_SEC/HZ);

while (tv->tv_usec < 0) {
tv->tv_usec += 1000000;

-
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/