home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 15 / 15.iso / s / s053 / 8.ddi / usr / include / sys / hrtsys.h < prev    next >
Encoding:
C/C++ Source or Header  |  1990-12-08  |  2.0 KB  |  74 lines

  1. /*    Copyright (c) 1990 UNIX System Laboratories, Inc.    */
  2. /*    Copyright (c) 1984, 1986, 1987, 1988, 1989, 1990 AT&T    */
  3. /*      All Rights Reserved      */
  4.  
  5. /*    THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF         */
  6. /*    UNIX System Laboratories, Inc.                         */
  7. /*    The copyright notice above does not evidence any       */
  8. /*    actual or intended publication of such source code.    */
  9.  
  10. #ifndef _SYS_HRTSYS_H
  11. #define _SYS_HRTSYS_H
  12.  
  13. #ident    "@(#)/usr/include/sys/hrtsys.h.sl 1.1 4.0 12/08/90 28715 AT&T-USL"
  14. /*
  15.  *    Kernel structure for keeping track of sleep and alarm requests.
  16.  */
  17.  
  18.  
  19. typedef struct timer {
  20.     struct proc    *hrt_proc;    /* Ptr to proc table entry.    */
  21.     int        hrt_clk;    /* Which clock to use        */
  22.     unsigned long    hrt_time;    /* Remaining time to alarm in    */
  23.                     /* HZ.                */
  24.     unsigned long    hrt_int;    /* Base interval for repeating    */
  25.                     /* alarms.            */
  26.     unsigned long    hrt_rem;    /* Value of remainder for    */
  27.                     /* repeat alarm.        */
  28.     unsigned long    hrt_crem;    /* Cummulative remainder for    */
  29.                     /* repeating alarm.        */
  30.     unsigned long    hrt_res;    /* User specified resolution.    */
  31.     ushort        hrt_cmd;    /* The user specified command.    */
  32.     struct vnode    *hrt_vp;    /* Ptr to vnode for event queue    */
  33.                     /* to post to.            */
  34.     ecb_t    hrt_ecb;        /* User specified event control */
  35.                     /* block.            */
  36.     int    (*hrt_fn)();        /* function to call        */    
  37.     struct timer    *hrt_next;    /* Next on list.        */
  38.     struct timer    *hrt_prev;    /* Previous on list.        */
  39. } timer_t;
  40.  
  41. extern timer_t    hrtimes[];
  42. extern int    hrtimes_size;
  43. extern timer_t    hrt_active;
  44. extern timer_t    hrt_avail;
  45.  
  46. extern timer_t    *hrt_alloc();
  47. extern void    hrt_free();
  48.  
  49. extern void    hrtinit();
  50. extern void    itinit();
  51.  
  52. extern long    hrt_convert();
  53.  
  54. extern    void    hrt_timeout();
  55. extern    void    hrt_enqueue();
  56. extern    void    hrt_dequeue();
  57.  
  58. extern    void    itimer_timeout();
  59. extern    void    itimer_enqueue();
  60. extern    void    itimer_dequeue();
  61.  
  62. extern timer_t    itimes[];
  63. extern int    itimes_size;
  64. extern timer_t    it_avail;
  65.  
  66. #ifdef _KERNEL
  67.  
  68. extern int    hrt_cancel_proc();
  69. extern void    hrt_gettofd();
  70.  
  71. #endif /* _KERNEL */
  72.  
  73. #endif    /* _SYS_HRTSYS_H */
  74.