--- src/sys/i386/isa/Attic/clock.c 2004/07/20 04:12:08 1.15 +++ src/sys/i386/isa/Attic/clock.c 2004/08/02 23:20:30 1.16 @@ -596,17 +596,21 @@ rtc_restore(void) } /* - * Restore all the timers non-atomically (XXX: should be atomically). + * Restore all the timers. * - * This function is called from apm_default_resume() to restore all the timers. - * This should not be necessary, but there are broken laptops that do not - * restore all the timers on resume. + * This function is called from apm_default_resume() / pmtimer to restore + * all the timers. We also have to restore our timebases, especially on + * MP systems, because cputimer_count() counter's delta may have grown + * too large for nanouptime() and friends to handle. */ void timer_restore(void) { + crit_enter(); i8254_restore(); /* restore timer_freq and hz */ rtc_restore(); /* reenable RTC interrupts */ + restoreclocks(); + crit_exit(); } /*