*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> mktimer (3)              
Title
Content
Arch
Section
 

mktimer(3)

Contents


NAME    [Toc]    [Back]

       mktimer - Allocate a per-process timer

SYNOPSIS    [Toc]    [Back]

       #include <sys/timers.h>

       timer_t mktimer(
               int clock_type,
               int notify_type,
               void *reserved );

LIBRARY    [Toc]    [Back]

       Standard C Library (libc)

PARAMETERS    [Toc]    [Back]

       Specifies  the  system-wide clock to be used as a per-process
 time base for the new timer.  Specifies the mechanism
       by  which a process is to be notified when the per-process
       timer times out.  Not used.

DESCRIPTION    [Toc]    [Back]

       The mktimer() function is used to allocate  a  per-process
       timer using a specified system-wide clock as its timebase.
       The mktimer() function returns a unique timer ID  of  type
       timer_t,  which  is used to identify the timer in per-process
 timer requests.

       Each implementation of per-process timers defines a set of
       clocks  that  can  be  used as a time base for per-process
       timers, and one or more mechanisms for notifying the  process
  that a per-process timer has expired. The Tru64 UNIX
       operating system allows each process to allocate one  perprocess
  timer  whose clock_type parameter is specified by
       the TIMEOFDAY symbolic constant, which is defined  in  the
       timers.h  include  file,  using the notification mechanism
       whose notify_type parameter is  specified  by  the  DELIVERY_SIGNALS
 symbolic constant.

       When  the  notify_type  parameter  is  specified as DELIVERY_SIGNALS,
 the system sends a SIGALRM signal to the process
 whenever the timer expires.

NOTES    [Toc]    [Back]

       Per-process  timers  are  not inherited by a child process
       across fork() or exec() functions.

       The reserved parameter is not currently used, but is specified
 for future support of other delivery mechanisms.

       The  mktimer()  function  is part of the POSIX 1003.4 real
       time extensions, which is not  an  approved  standard.  As
       such, it is liable to change.  Trial use

RETURN VALUES    [Toc]    [Back]

       Upon successful completion, the mktimer() function returns
       a timer_t value, which may  be  passed  to  a  per-process
       timer  call.  Otherwise,  mktimer()  returns  a  value  of
       (timer_t)-1 and sets errno to indicate the error.




ERRORS    [Toc]    [Back]

       If the mktimer() function fails, errno may be set  to  one
       of  the  following values: The calling process has already
       allocated  all  available  timers.   The   clock_type   or
       notify_type parameter is invalid.

SEE ALSO    [Toc]    [Back]

      
      
       Functions:  exec(2),  fork(2),  getclock(3),  gettimer(3),
       reltimer(3), rmtimer(3), setclock(3)



                                                       mktimer(3)
[ Back ]
 Similar pages
Name OS Title
gettimer Tru64 Get value of a per-process timer
rmtimer Tru64 Free a per-process timer
timer_create Tru64 Allocates a per-process timer
reltimer Tru64 Establishe timeout intervals of a per-process timer
nanosleep Tru64 Suspends a process from execution for the specified timer interval (P1003.1b)
timer_delete Tru64 Deallocates a previously allocated per-process timer (P1003.1b)
getitimer IRIX get/set value of interval timer
timer_delete HP-UX timer operations
setitimer HP-UX get and set value of interval timer
setitimer OpenBSD get/set value of interval timer
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service