--- usr/src/sys/i386/isa/clock.c.orig Tue Jun 4 17:49:33 2002 +++ usr/src/sys/i386/isa/clock.c Tue Jun 4 17:49:05 2002 @@ -770,6 +770,23 @@ } set_timer_freq(timer_freq, hz); + + /* + * manual adjustment of the system clock with a fix correction-factor + * eg. in /boot/loader.conf: + * clock.i8254.adjust="993959" + * necessary for some notebooks + */ + { + int clock_adjust; + clock_adjust = 1e6; + TUNABLE_INT_FETCH("clock.i8254.adjust", &clock_adjust); + timer_freq *= clock_adjust / 1000000.0; + if (bootverbose) + printf("clock.adjust %d, i8254 clock: %u Hz\n", + clock_adjust, timer_freq); + } + i8254_timecounter.tc_frequency = timer_freq; init_timecounter(&i8254_timecounter);