Lines Matching defs:smc

28 #include "h/smc.h"
47 * struct s_smc *smc,
50 * smc - A pointer to the SMT Context structure.
59 void hwt_start(struct s_smc *smc, u_long time)
66 smc->hw.t_start = time ;
67 smc->hw.t_stop = 0L ;
80 smc->hw.timer_activ = TRUE ;
90 * struct s_smc *smc) ;
92 * smc - A pointer to the SMT Context structure.
97 void hwt_stop(struct s_smc *smc)
102 smc->hw.timer_activ = FALSE ;
112 * struct s_smc *smc) ;
114 * smc - A pointer to the SMT Context structure.
119 void hwt_init(struct s_smc *smc)
121 smc->hw.t_start = 0 ;
122 smc->hw.t_stop = 0 ;
123 smc->hw.timer_activ = FALSE ;
125 hwt_restart(smc) ;
135 * struct s_smc *smc) ;
137 * smc - A pointer to the SMT Context structure.
142 void hwt_restart(struct s_smc *smc)
144 hwt_stop(smc) ;
153 * u_long hwt_read(smc) ;
155 * smc - A pointer to the SMT Context structure.
160 u_long hwt_read(struct s_smc *smc)
165 if (smc->hw.timer_activ) {
166 hwt_stop(smc) ;
171 if ((tr > smc->hw.t_start) || (is & IS_TIMINT)) {
172 hwt_restart(smc) ;
173 smc->hw.t_stop = smc->hw.t_start ;
176 smc->hw.t_stop = smc->hw.t_start - tr ;
178 return smc->hw.t_stop;
188 * u_long hwt_read(smc) ;
190 * smc - A pointer to the SMT Context structure.
195 u_long hwt_quick_read(struct s_smc *smc)
212 * hwt_wait_time(smc,start,duration)
223 void hwt_wait_time(struct s_smc *smc, u_long start, long int duration)
232 if (smc->hw.timer_activ == FALSE ||
233 hwt_quick_read(smc) == hwt_quick_read(smc)) {
240 diff = (long)(start - hwt_quick_read(smc)) ;
251 if (hwt_quick_read(smc) >= start) {
257 if (hwt_quick_read(smc) < start) {