HardenedBSD src tree
Go to file
Bruce Evans 2dafbfcbab Added calibration the i8254 and the i586 clocks agains the RTC at boot
time.  The results are currently ignored unless certain temporary options
are used.

Added sysctls to support reading and writing the clock frequency variables
(not the frequencies themselves).  Writing is supposed to atomically
adjust all related variables.

machdep.c:
Fixed spelling of a function name in a comment so that I can log this
message which should have been with the previous commit.

Initialize `cpu_class' earlier so that it can be used in startrtclock()
instead of in calibrate_cyclecounter() (which no longer exists).

Removed range checking of `cpu'.  It is always initialized to CPU_XXX
so it is less likely to be out of bounds than most variables.

clock.h:
Removed I586_CYCLECTR().  Use rdtsc() instead.

clock.c:
TIMER_FREQ is now a variable timer_freq that defaults to the old value of
TIMER_FREQ.  #define'ing TIMER_FREQ should still work and may be the best
way of setting the frequency.

Calibration involves counting cycles while watching the RTC for one second.
This gives values correct to within (a few ppm) + (the innaccuracy of the
RTC) on my systems.
1996-05-01 08:39:02 +00:00
bin
eBones
etc
games
gnu
include
lib
libexec
lkm
release Micro tweak for getting the Holographic shell message to stay on the 1996-05-01 03:31:08 +00:00
sbin Default to udp if neither udp nor tcp is specified. The previous revision 1996-05-01 03:13:45 +00:00
secure
share
sys Added calibration the i8254 and the i586 clocks agains the RTC at boot 1996-05-01 08:39:02 +00:00
tools
usr.bin
usr.sbin Micro tweak for getting the Holographic shell message to stay on the 1996-05-01 03:31:08 +00:00
COPYRIGHT
Makefile