clock.h revision 33690
1/* 2 * Kernel interface to machine-dependent clock driver. 3 * Garrett Wollman, September 1994. 4 * This file is in the public domain. 5 * 6 * $Id: clock.h,v 1.31 1998/02/01 22:45:23 bde Exp $ 7 */ 8 9#ifndef _MACHINE_CLOCK_H_ 10#define _MACHINE_CLOCK_H_ 11 12#define TSC_COMULTIPLIER_SHIFT 20 13#define TSC_MULTIPLIER_SHIFT 32 14 15#ifdef KERNEL 16/* 17 * i386 to clock driver interface. 18 * XXX almost all of it is misplaced. i586 stuff is done in isa/clock.c 19 * and isa stuff is done in i386/microtime.s and i386/support.s. 20 */ 21extern int adjkerntz; 22extern int disable_rtc_set; 23extern int statclock_disable; 24extern u_int timer_freq; 25extern int timer0_max_count; 26extern u_int tsc_freq; 27extern int wall_cmos_clock; 28 29/* 30 * Driver to clock driver interface. 31 */ 32struct clockframe; 33 34void DELAY __P((int usec)); 35int acquire_timer0 __P((int rate, 36 void (*function)(struct clockframe *frame))); 37int acquire_timer2 __P((int mode)); 38int release_timer0 __P((void)); 39int release_timer2 __P((void)); 40#ifndef PC98 41int rtcin __P((int val)); 42#else 43int acquire_timer1 __P((int mode)); 44int release_timer1 __P((void)); 45#endif 46int sysbeep __P((int pitch, int period)); 47 48#endif /* KERNEL */ 49 50#endif /* !_MACHINE_CLOCK_H_ */ 51