[BACK]Return to kern_time.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / kern

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/kern/kern_time.c between version 1.125.6.1 and 1.125.6.2

version 1.125.6.1, 2007/08/09 02:37:20 version 1.125.6.2, 2007/08/16 11:03:35
Line 1299  timers_free(struct proc *p, int which)
Line 1299  timers_free(struct proc *p, int which)
 }  }
   
 /*  /*
  * Check that a proposed value to load into the .it_value or  
  * .it_interval part of an interval timer is acceptable, and  
  * fix it to have at least minimal value (i.e. if it is less  
  * than the resolution of the clock, round it up.)  
  */  
 int  
 itimerfix(struct timeval *tv)  
 {  
   
         if (tv->tv_sec < 0 || tv->tv_usec < 0 || tv->tv_usec >= 1000000)  
                 return (EINVAL);  
         if (tv->tv_sec == 0 && tv->tv_usec != 0 && tv->tv_usec < tick)  
                 tv->tv_usec = tick;  
         return (0);  
 }  
   
 int  
 itimespecfix(struct timespec *ts)  
 {  
   
         if (ts->tv_sec < 0 || ts->tv_nsec < 0 || ts->tv_nsec >= 1000000000)  
                 return (EINVAL);  
         if (ts->tv_sec == 0 && ts->tv_nsec != 0 && ts->tv_nsec < tick * 1000)  
                 ts->tv_nsec = tick * 1000;  
         return (0);  
 }  
   
 /*  
  * Decrement an interval timer by a specified number   * Decrement an interval timer by a specified number
  * of microseconds, which must be less than a second,   * of microseconds, which must be less than a second,
  * i.e. < 1000000.  If the timer expires, then reload   * i.e. < 1000000.  If the timer expires, then reload

Legend:
Removed from v.1.125.6.1  
changed lines
  Added in v.1.125.6.2

CVSweb <webmaster@jp.NetBSD.org>