/* KLEENIX_ID: @(#)timeout.h 26.1 */ /* this defines the structure used for doing timeouts and delays. The address of this structure is passed to timeout and delay so that it can be linked into the callout structure. Because there is a need to remove timeouts, a simple array cannot be efficiently used. */ struct timeout { long timeval; /* timeout value */ struct timeout *f_link; /* forward link */ struct timeout *b_link; /* backward link */ int (*proc)(); /* procedure to call if timed out */ caddr_t arg; /* argument to pass */ }; /* Software triggers usually are associated with timeouts */ /* This is used to provide 'software triggering' of interrupt service routines. This structure is linked into a list of structures to be serviced on the way out of other ISR's. This permits, for example, deferring the service of a timeout to a lower level, or having the top half of the character service stuff trigger the bottom half at a lower level */ struct sw_intloc { struct sw_intloc *link; int (*proc)(); /* to call on trigger */ caddr_t arg; /* argument */ char priority; /* level of interrupt */ char sub_priority; /* sub-level of interrupt */ };