Port-i386 archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: TSC clock going backwards on suspend/resume
roy%marples.name@localhost said:
> > while the problems leading to the monotonic clock being
> > accused of going backwards are fixed afaics
> amd64, built from todays netbsd-5 sources.
fixed in -current... This is a candidate for pullup, could
you please try the appended patch from CVS?
best regards
Matthias
-------------------------------------------------------------------
-------------------------------------------------------------------
Forschungszentrum Juelich GmbH
52425 Juelich
Sitz der Gesellschaft: Juelich
Eingetragen im Handelsregister des Amtsgerichts Dueren Nr. HR B 3498
Vorsitzende des Aufsichtsrats: MinDir'in Baerbel Brumme-Bothe
Geschaeftsfuehrung: Prof. Dr. Achim Bachem (Vorsitzender),
Dr. Ulrich Krafft (stellv. Vorsitzender), Prof. Dr. Harald Bolt,
Dr. Sebastian M. Schmidt
-------------------------------------------------------------------
-------------------------------------------------------------------
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
===================================================================
RCS file: /ftp/cvs/cvsroot/src/sys/kern/kern_time.c,v
retrieving revision 1.158
retrieving revision 1.159
diff -u -p -r1.158 -r1.159
--- src/sys/kern/kern_time.c 2009/01/30 23:11:27 1.158
+++ src/sys/kern/kern_time.c 2009/01/31 15:53:36 1.159
@@ -1,4 +1,4 @@
-/* $NetBSD: kern_time.c,v 1.158 2009/01/30 23:11:27 ad Exp $ */
+/* $NetBSD: kern_time.c,v 1.159 2009/01/31 15:53:36 yamt Exp $ */
/*-
* Copyright (c) 2000, 2004, 2005, 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_time.c,v 1.158 2009/01/30 23:11:27 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_time.c,v 1.159 2009/01/31 15:53:36 yamt Exp
$");
#include <sys/param.h>
#include <sys/resourcevar.h>
@@ -132,8 +132,6 @@ static int
settime1(struct proc *p, const struct timespec *ts, bool check_kauth)
{
struct timespec delta, now;
- struct bintime btdelta;
- lwp_t *l;
int s;
/* WHAT DO WE DO ABOUT PENDING REAL-TIME TIMEOUTS??? */
@@ -159,19 +157,6 @@ settime1(struct proc *p, const struct ti
timespecadd(&boottime, &delta, &boottime);
- /*
- * XXXSMP: There is a short race between setting the time above
- * and adjusting LWP's run times. Fixing this properly means
- * pausing all CPUs while we adjust the clock.
- */
- timespec2bintime(&delta, &btdelta);
- mutex_enter(proc_lock);
- LIST_FOREACH(l, &alllwp, l_list) {
- lwp_lock(l);
- bintime_add(&l->l_stime, &btdelta);
- lwp_unlock(l);
- }
- mutex_exit(proc_lock);
resettodr();
splx(s);
Home |
Main Index |
Thread Index |
Old Index